diff options
author | admin <devnull@localhost> | 2006-10-21 21:44:22 +0200 |
---|---|---|
committer | admin <devnull@localhost> | 2006-10-21 21:44:22 +0200 |
commit | e334c472fb4be44feec3a73402fc4a2b062cbfc0 (patch) | |
tree | 553f17d67e7ef652016ec85b2a576bb2210f0ff8 /user_guide/libraries/sessions.html | |
parent | bd6bee75dd26ade1c8d9cfd104bb913065797c59 (diff) |
Diffstat (limited to 'user_guide/libraries/sessions.html')
-rw-r--r-- | user_guide/libraries/sessions.html | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/user_guide/libraries/sessions.html b/user_guide/libraries/sessions.html index e9302d2c6..5b9d20fb9 100644 --- a/user_guide/libraries/sessions.html +++ b/user_guide/libraries/sessions.html @@ -12,7 +12,7 @@ <script type="text/javascript" src="../nav/moo.fx.js"></script>
<script type="text/javascript">
window.onload = function() {
- myHeight = new fx.Height('nav', {duration: 400});
+ myHeight = new fx.Height('nav', {duration: 400});
myHeight.hide();
}
</script>
@@ -63,9 +63,9 @@ Session Class <h1>Session Class</h1>
-<p>The Session class permits you maintain a user's "state" and track their activity while they browse your site.
-The Session class stores session information for each user as serialized (and optionally encrypted) data in a cookie.
-It can also store the session data in a database table for added security, as this permits the session ID in the
+<p>The Session class permits you maintain a user's "state" and track their activity while they browse your site.
+The Session class stores session information for each user as serialized (and optionally encrypted) data in a cookie.
+It can also store the session data in a database table for added security, as this permits the session ID in the
user's cookie to be matched against the stored session ID. By default only the cookie is saved. If you choose to
use the database option you'll need to create the session table as indicated below.
</p>
@@ -75,7 +75,7 @@ generates its own session data, offering more flexibility for developers.</p> <h2>Initializing a Session</h2>
-<p>Sessions will typically run globally with each page load, so the session class must either be
+<p>Sessions will typically run globally with each page load, so the session class must either be
<a href="../general/libraries.html">initialized</a> in your
<a href="../general/controllers.html">controller</a> constructors, or it can be
<a href="../general/autoloader.html">auto-loaded</a> by the system.
@@ -91,8 +91,8 @@ will cause it to read, create, and update sessions.</p> <h2>How do Sessions work?</h2>
-<p>When a page is loaded, the session class will check to see if valid session data exists in the user's session cookie.
-If sessions data does <strong>not</strong> exist (or if it has expired) a new session will be created and saved in the cookie.
+<p>When a page is loaded, the session class will check to see if valid session data exists in the user's session cookie.
+If sessions data does <strong>not</strong> exist (or if it has expired) a new session will be created and saved in the cookie.
If a session does exist, its information will be updated and the cookie will be updated.</p>
<p>It's important for you to understand that once initialized, the Session class runs automatically. There is nothing
@@ -137,7 +137,7 @@ the cookie was written.</p> <code>$this->session->userdata('<samp>item</samp>');</code>
-<p>Where <samp>item</samp> is the array index corresponding to the item you wish to fetch. For example, to fetch the session ID you
+<p>Where <samp>item</samp> is the array index corresponding to the item you wish to fetch. For example, to fetch the session ID you
will do this:</p>
<code>$session_id = $this->session->userdata('<samp>session_id</samp>');</code>
@@ -176,13 +176,13 @@ encryption process in particular produces a longer data string than the original <p>While the session data array stored in the user's cookie contains a Session ID,
unless you store session data in a database there is no way to validate it. For some applications that require little or no
-security, session ID validation may not be needed, but if your application requires security, validation is mandatory.</p>
+security, session ID validation may not be needed, but if your application requires security, validation is mandatory.</p>
<p>When session data is available in a database, every time a valid session is found in the user's cookie, a database
query is performed to match it. If the session ID does not match, the session is destroyed. Session IDs can never
be updated, they can only be generated when a new session is created.</p>
-<p>In order to store sessions, you must first create a database table for this purpose. Here is the basic
+<p>In order to store sessions, you must first create a database table for this purpose. Here is the basic
prototype (for MySQL) required by the session class:</p>
<textarea class="textarea" style="width:100%" cols="50" rows="8">
@@ -232,7 +232,7 @@ do not need to write your own routine to do it.</p> <td class="td"><strong>sess_expiration</strong></td>
<td class="td">7200</td>
<td class="td">None</td>
-<td class="td">The number of seconds you would like the session to last. The default value is 2 hours (7200 seconds).
+<td class="td">The number of seconds you would like the session to last. The default value is 2 hours (7200 seconds).
If you would like a non-expiring session set the value to zero: 0</td>
|