From e334c472fb4be44feec3a73402fc4a2b062cbfc0 Mon Sep 17 00:00:00 2001 From: admin Date: Sat, 21 Oct 2006 19:44:22 +0000 Subject: --- user_guide/libraries/benchmark.html | 12 ++++----- user_guide/libraries/calendar.html | 8 +++--- user_guide/libraries/config.html | 6 ++--- user_guide/libraries/email.html | 4 +-- user_guide/libraries/encryption.html | 16 ++++++------ user_guide/libraries/file_uploading.html | 16 ++++++------ user_guide/libraries/image_lib.html | 18 +++++++------- user_guide/libraries/input.html | 6 ++--- user_guide/libraries/language.html | 6 ++--- user_guide/libraries/loader.html | 22 ++++++++--------- user_guide/libraries/output.html | 6 ++--- user_guide/libraries/pagination.html | 6 ++--- user_guide/libraries/parser.html | 8 +++--- user_guide/libraries/sessions.html | 22 ++++++++--------- user_guide/libraries/table.html | 10 ++++---- user_guide/libraries/trackback.html | 6 ++--- user_guide/libraries/unit_testing.html | 12 ++++----- user_guide/libraries/uri.html | 6 ++--- user_guide/libraries/user_agent.html | 4 +-- user_guide/libraries/validation.html | 26 ++++++++++---------- user_guide/libraries/xmlrpc.html | 42 ++++++++++++++++---------------- user_guide/libraries/zip.html | 6 ++--- 22 files changed, 134 insertions(+), 134 deletions(-) (limited to 'user_guide/libraries') diff --git a/user_guide/libraries/benchmark.html b/user_guide/libraries/benchmark.html index 37252b61c..17e67fc84 100644 --- a/user_guide/libraries/benchmark.html +++ b/user_guide/libraries/benchmark.html @@ -12,7 +12,7 @@ @@ -127,9 +127,9 @@ echo $this->benchmark->elapsed_time('dog', 'bird');

Profiling Your Benchmark Points

-

If you want your benchmark data to be available to the -Profiler all of your marked points must be set up in pairs, and -each mark point name must end with _start and _end. +

If you want your benchmark data to be available to the +Profiler all of your marked points must be set up in pairs, and +each mark point name must end with _start and _end. Each pair of points must otherwise be named identically. Example:

@@ -158,14 +158,14 @@ is sent to the browser, simply place this in one of your view templates:

<?=$this->benchmark->elapsed_time();?> -

You'll notice that it's the same function used in the examples above to calculate the time between two point, except you are +

You'll notice that it's the same function used in the examples above to calculate the time between two point, except you are not using any parameters. When the parameters are absent, Code Igniter does not stop the benchmark until right before the final output is sent to the browser. It doesn't matter where you use the function call, the timer will continue to run until the very end.

An alternate way to show your elapsed time in your view files is to use this pseudo-variable, if you prefer not to use the pure PHP:

{elapsed_time} -

Note: If you want to benchmark anything within your controller +

Note: If you want to benchmark anything within your controller functions you must set your own start/end points.

diff --git a/user_guide/libraries/calendar.html b/user_guide/libraries/calendar.html index a13cadf05..c8a8e80ee 100644 --- a/user_guide/libraries/calendar.html +++ b/user_guide/libraries/calendar.html @@ -12,7 +12,7 @@ @@ -65,7 +65,7 @@ Calendaring Class

Calendaring Class

-

The Calendar class enables you to dynamically create calendars. Your calendars can be formatted through the use of a calendar +

The Calendar class enables you to dynamically create calendars. Your calendars can be formatted through the use of a calendar template, allowing 100% control over every aspect of its design. In addition, you can pass data to your calendar cells.

Initializing the Class

@@ -112,14 +112,14 @@ echo $this->calendar->generate(2006, 6, $data);

Using the above example, day numbers 3, 7, 13, and 26 will become links pointing to the URLs you've provided.

-

Note: By default it is assumed that your array will contain links. +

Note: By default it is assumed that your array will contain links. In the section that explains the calendar template below you'll see how you can customize how data passed to your cells is handled so you can pass different types of information.

Setting Display Preferences

-

There are seven preferences you can set to control various aspects of the calendar. Preferences are set using an initialization +

There are seven preferences you can set to control various aspects of the calendar. Preferences are set using an initialization function similar to other classes. Here is an example: diff --git a/user_guide/libraries/config.html b/user_guide/libraries/config.html index f8a9f5207..cd20298aa 100644 --- a/user_guide/libraries/config.html +++ b/user_guide/libraries/config.html @@ -12,7 +12,7 @@ @@ -75,7 +75,7 @@ come from the default config file (application/config/config.php) o your text editor you'll see that config items are stored in an array called $config.

You can add your own config items to -this file, or if you prefer to keep your configuration items separate (assuming you even need config items), +this file, or if you prefer to keep your configuration items separate (assuming you even need config items), simply create your own file and save it in config folder.

Note: If you do create your own config files use the same format as the primary one, storing your items in @@ -84,7 +84,7 @@ the array has the same name (assuming an array index is not named the same as an

Loading a Config File

-

Note: Code Igniter automatically loads the primary config file (application/config/config.php), +

Note: Code Igniter automatically loads the primary config file (application/config/config.php), so you will only need to load a config file if you have created your own.

There are two ways to load a config file:

diff --git a/user_guide/libraries/email.html b/user_guide/libraries/email.html index ea1b8680a..b8a68e9d1 100644 --- a/user_guide/libraries/email.html +++ b/user_guide/libraries/email.html @@ -12,7 +12,7 @@ @@ -218,7 +218,7 @@ $this->email->to('$list');
$this->email->set_alt_message('This is the alternative message');

This is an optional message string which can be used if you send HTML formatted email. It lets you specify an alternative -message with no HTML formatting which is added to the header string for people who do not accept HTML email. +message with no HTML formatting which is added to the header string for people who do not accept HTML email. If you do not set your own message Code Igniter will extract the message from your HTML email and strip the tags.

diff --git a/user_guide/libraries/encryption.html b/user_guide/libraries/encryption.html index d541174fb..c80d07dcd 100644 --- a/user_guide/libraries/encryption.html +++ b/user_guide/libraries/encryption.html @@ -12,7 +12,7 @@ @@ -66,14 +66,14 @@ Encryption Class

The Encryption Class provides two-way data encryption. It uses a scheme that pre-compiles the message using a randomly hashed bitwise XOR encoding scheme, which is then encrypted using the Mcrypt library. If Mcrypt is not available on your server the encoded message will -still provide a reasonable degree of security for encrypted sessions or other such "light" purposes. +still provide a reasonable degree of security for encrypted sessions or other such "light" purposes. If Mcrypt is available, you'll effectively end up with a double-encrypted message string, which should provide a very high degree of security.

Setting your Key

-

A key is a piece of information that controls the cryptographic process and permits an encrypted string to be decoded. +

A key is a piece of information that controls the cryptographic process and permits an encrypted string to be decoded. In fact, the key you chose will provide the only means to decode data that was encrypted with that key, so not only must you chose the key carefully, you must never change it if you intend use it for persistent data.

@@ -82,12 +82,12 @@ Should someone gain access to your key, the data will be easily decoded. If you it's impossible to ensure key security so you may want to think carefully before using it for anything that requires high security, like storing credit card numbers.

-

To take maximum advantage of the encryption algorithm, your key should be 32 characters in length (128 bits). -The key should be as random a string as you can concoct, with numbers and uppercase and lowercase letters. -Your key should not be a simple text string. In order to be cryptographically secure it +

To take maximum advantage of the encryption algorithm, your key should be 32 characters in length (128 bits). +The key should be as random a string as you can concoct, with numbers and uppercase and lowercase letters. +Your key should not be a simple text string. In order to be cryptographically secure it needs to be as random as possible.

-

Your key can be either stored in your application/config/config.php, or you can design your own +

Your key can be either stored in your application/config/config.php, or you can design your own storage mechanism and pass the key dynamically when encoding/decoding.

To save your key to your application/config/config.php, open the file and set:

@@ -96,7 +96,7 @@ storage mechanism and pass the key dynamically when encoding/decoding.

Message Length

-

It's important for you to know that the encoded messages the encryption function generates will be approximately 2.6 times longer than the original +

It's important for you to know that the encoded messages the encryption function generates will be approximately 2.6 times longer than the original message. For example, if you encrypt the string "my super secret data", which is 21 characters in length, you'll end up with an encoded string that is roughly 55 characters (we say "roughly" because the encoded string length increments in 64 bit clusters, so it's not exactly linear). Keep this information in mind when selecting your data storage mechanism. Cookies, diff --git a/user_guide/libraries/file_uploading.html b/user_guide/libraries/file_uploading.html index 390b45375..730dd0545 100644 --- a/user_guide/libraries/file_uploading.html +++ b/user_guide/libraries/file_uploading.html @@ -12,7 +12,7 @@ @@ -63,7 +63,7 @@ File Uploading Class

File Uploading Class

-

Code Igniter's File Uploading Class permits files to be uploaded. You can set various +

Code Igniter's File Uploading Class permits files to be uploaded. You can set various preferences, restricting the type and size of the files.

@@ -110,7 +110,7 @@ folder:

-

You'll notice we are using a form helper to create the opening form tag. File uploads require a multipart form, so the helper +

You'll notice we are using a form helper to create the opening form tag. File uploads require a multipart form, so the helper creates the proper syntax for you. You'll also notice we have an $error variable. This is so we can show error messages in the event the user does something wrong.

@@ -165,7 +165,7 @@ class Upload extends Controller { { $this->load->library('upload'); - $config['upload_path'] = './uploads/'; + $config['upload_path'] = './uploads/'; $config['allowed_types'] = 'gif|jpg|png'; $config['max_size'] = '100'; $config['max_width'] = '1024'; @@ -202,7 +202,7 @@ class Upload extends Controller { www.your-site.com/index.php/upload/ -

You should see an upload form. Try uploading an image file (either a jpg, gif, or png). If the path in your +

You should see an upload form. Try uploading an image file (either a jpg, gif, or png). If the path in your controller is correct it should work.

@@ -221,7 +221,7 @@ controller is correct it should work.

Setting Preferences

-

Similar to other libraries, you'll control what is allowed to be upload based on your preferences. In the controller you +

Similar to other libraries, you'll control what is allowed to be upload based on your preferences. In the controller you built above you set the following preferences:

$config['upload_path'] = './uploads/';
@@ -323,7 +323,7 @@ will NOT need to use the $this->upload->initialize function if you sa

$this->upload->do_upload()

-

Performs the upload based on the preferences you've set. Note: By default the upload routine expects the file to come from a form field +

Performs the upload based on the preferences you've set. Note: By default the upload routine expects the file to come from a form field called userfile, and the form must be a "multipart type:

<form method="post" action="some_action" enctype="multipart/form-data" /> @@ -347,7 +347,7 @@ returns the data so you can assign it however you need.

$this->upload->data()

-

This is a helper function that returns an array containing all of the data related to the file you uploaded. +

This is a helper function that returns an array containing all of the data related to the file you uploaded. Here is the array prototype:

Array
diff --git a/user_guide/libraries/image_lib.html b/user_guide/libraries/image_lib.html index f2a7a5554..c49cad318 100644 --- a/user_guide/libraries/image_lib.html +++ b/user_guide/libraries/image_lib.html @@ -12,7 +12,7 @@ @@ -75,9 +75,9 @@ Image Manipulation Class

All three major image libraries are supported: GD/GD2, NetPBM, and ImageMagick

-

Note: Watermarking is only available using the GD/GD2 library. +

Note: Watermarking is only available using the GD/GD2 library. In addition, even though other libraries are supported, GD is required in -order for the script to calculate the image properties. The image processing, however, will be performed with the +order for the script to calculate the image properties. The image processing, however, will be performed with the library you specify.

@@ -110,7 +110,7 @@ $this->image_lib->resize();

The above code tells the image_resize function to look for an image called mypic.jpg located in the source_image folder, then create a thumbnail that is 75 X 50 pixels using the GD2 image_library. -Since the maintain_ratio option is enabled, the thumb will be as close to the target width and +Since the maintain_ratio option is enabled, the thumb will be as close to the target width and height as possible while preserving the original aspect ratio. The thumbnail will be called mypic_thumb.jpg

@@ -316,7 +316,7 @@ will NOT need to use the $this->image_lib->initialize function if you

$this->image_lib->resize()

-

The image resizing function lets you resize the original image, create a copy (with or without resizing), +

The image resizing function lets you resize the original image, create a copy (with or without resizing), or create a thumbnail image.

For practical purposes there is no difference between creating a copy and creating @@ -355,7 +355,7 @@ target the original image for processing.

$this->image_lib->crop()

-

The cropping function works nearly identically to the resizing function except it requires that you set +

The cropping function works nearly identically to the resizing function except it requires that you set preferences for the X and Y axis (in pixels) specifying where to crop, like this:

$config['x_axis'] = '100';
@@ -380,8 +380,8 @@ if ( ! $this->image_lib->crop())
}
-

Note: Without a visual interface it is difficult to crop images, so this function is not very useful -unless you intend to build such an interface. That's exactly what we did using for the photo +

Note: Without a visual interface it is difficult to crop images, so this function is not very useful +unless you intend to build such an interface. That's exactly what we did using for the photo gallery module in ExpressionEngine, the CMS we develop. We added a JavaScript UI that lets the cropping area be selected.

@@ -430,7 +430,7 @@ if ( ! $this->image_lib->rotate())