From b8c283a695c8074a57d8c3dfa00934312638931d Mon Sep 17 00:00:00 2001 From: Derek Jones Date: Fri, 19 Jul 2013 16:02:53 -0700 Subject: Dropping unecessary php: directive to function definitions in user guide --- user_guide_src/source/helpers/cookie_helper.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'user_guide_src/source/helpers/cookie_helper.rst') diff --git a/user_guide_src/source/helpers/cookie_helper.rst b/user_guide_src/source/helpers/cookie_helper.rst index c41193c3c..c09f5eb4c 100644 --- a/user_guide_src/source/helpers/cookie_helper.rst +++ b/user_guide_src/source/helpers/cookie_helper.rst @@ -19,7 +19,7 @@ The following functions are available: set_cookie() ============ -.. php:function:: set_cookie($name = '', $value = '', $expire = '', $domain = '', $path = '/', $prefix = '', $secure = FALSE, $httponly = FALSE) +.. function:: set_cookie($name = '', $value = '', $expire = '', $domain = '', $path = '/', $prefix = '', $secure = FALSE, $httponly = FALSE) :param string $name: Cookie name :param string $value: Cookie value @@ -39,7 +39,7 @@ description of its use, as this function is an alias for get_cookie() ============ -.. php:function:: get_cookie($index = '', $xss_clean = FALSE) +.. function:: get_cookie($index = '', $xss_clean = FALSE) :param string $index: Cookie name :param bool $xss_clean: Whether to apply XSS filtering to the returned value @@ -52,7 +52,7 @@ description of itsuse, as this function is an alias for ``CI_Input::cookie()``. delete_cookie() =============== -.. php:function:: delete_cookie($name = '', $domain = '', $path = '/', $prefix = '') +.. function:: delete_cookie($name = '', $domain = '', $path = '/', $prefix = '') :param string $name: Cookie name :param string $domain: Cookie domain (usually: .yourdomain.com) -- cgit v1.2.3-24-g4f1b From b55d981d3febf3f2eca72cde5f11742a529e7f19 Mon Sep 17 00:00:00 2001 From: Derek Jones Date: Sat, 20 Jul 2013 08:49:25 -0700 Subject: Update Cookie helper docs --- user_guide_src/source/helpers/cookie_helper.rst | 55 +++++++++++++------------ 1 file changed, 29 insertions(+), 26 deletions(-) (limited to 'user_guide_src/source/helpers/cookie_helper.rst') diff --git a/user_guide_src/source/helpers/cookie_helper.rst b/user_guide_src/source/helpers/cookie_helper.rst index c09f5eb4c..41a6d1c56 100644 --- a/user_guide_src/source/helpers/cookie_helper.rst +++ b/user_guide_src/source/helpers/cookie_helper.rst @@ -5,7 +5,12 @@ Cookie Helper The Cookie Helper file contains functions that assist in working with cookies. -.. contents:: Page Contents +.. contents:: + :local: + +.. raw:: html + +
Loading this Helper =================== @@ -14,14 +19,16 @@ This helper is loaded using the following code:: $this->load->helper('cookie'); +Available Functions +=================== + The following functions are available: -set_cookie() -============ -.. function:: set_cookie($name = '', $value = '', $expire = '', $domain = '', $path = '/', $prefix = '', $secure = FALSE, $httponly = FALSE) +.. function:: set_cookie($name = ''[, $value = ''[, $expire = ''[, $domain = ''[, $path = '/'[, $prefix = ''[, $secure = FALSE[, $httponly = FALSE]]]]]]]) - :param string $name: Cookie name + :param mixed $name: Cookie name *or* associative array of all of + the parameters available to this function :param string $value: Cookie value :param int $expire: Number of seconds until expiration :param string $domain: Cookie domain (usually: .yourdomain.com) @@ -31,13 +38,11 @@ set_cookie() :param bool $httponly: Whether to hide the cookie from JavaScript :returns: void -This helper function gives you view file friendly syntax to set browser -cookies. Refer to the :doc:`Input Library <../libraries/input>` for a -description of its use, as this function is an alias for -``CI_Input::set_cookie()``. + This helper function gives you view file friendly syntax to set browser + cookies. Refer to the :doc:`Input Library <../libraries/input>` for a + description of its use, as this function is an alias for + ``CI_Input::set_cookie()``. -get_cookie() -============ .. function:: get_cookie($index = '', $xss_clean = FALSE) @@ -45,12 +50,10 @@ get_cookie() :param bool $xss_clean: Whether to apply XSS filtering to the returned value :returns: mixed -This helper function gives you view file friendly syntax to get browser -cookies. Refer to the :doc:`Input Library <../libraries/input>` for a -description of itsuse, as this function is an alias for ``CI_Input::cookie()``. + This helper function gives you view file friendly syntax to get browser + cookies. Refer to the :doc:`Input Library <../libraries/input>` for a + description of its use, as this function is an alias for ``CI_Input::cookie()``. -delete_cookie() -=============== .. function:: delete_cookie($name = '', $domain = '', $path = '/', $prefix = '') @@ -60,18 +63,18 @@ delete_cookie() :param string $prefix: Cookie name prefix :returns: void -Lets you delete a cookie. Unless you've set a custom path or other -values, only the name of the cookie is needed. + Lets you delete a cookie. Unless you've set a custom path or other + values, only the name of the cookie is needed. -:: + :: - delete_cookie('name'); + delete_cookie('name'); -This function is otherwise identical to ``set_cookie()``, except that it -does not have the value and expiration parameters. You can submit an -array of values in the first parameter or you can set discrete -parameters. + This function is otherwise identical to ``set_cookie()``, except that it + does not have the value and expiration parameters. You can submit an + array of values in the first parameter or you can set discrete + parameters. -:: + :: - delete_cookie($name, $domain, $path, $prefix) \ No newline at end of file + delete_cookie($name, $domain, $path, $prefix) \ No newline at end of file -- cgit v1.2.3-24-g4f1b From 26f7a9fb4aa08c66c2842b90b4f5ab1a08076df6 Mon Sep 17 00:00:00 2001 From: Derek Jones Date: Sat, 20 Jul 2013 09:00:02 -0700 Subject: fixed param options on cookie helper function definitions --- user_guide_src/source/helpers/cookie_helper.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'user_guide_src/source/helpers/cookie_helper.rst') diff --git a/user_guide_src/source/helpers/cookie_helper.rst b/user_guide_src/source/helpers/cookie_helper.rst index 41a6d1c56..e70893f2f 100644 --- a/user_guide_src/source/helpers/cookie_helper.rst +++ b/user_guide_src/source/helpers/cookie_helper.rst @@ -25,7 +25,7 @@ Available Functions The following functions are available: -.. function:: set_cookie($name = ''[, $value = ''[, $expire = ''[, $domain = ''[, $path = '/'[, $prefix = ''[, $secure = FALSE[, $httponly = FALSE]]]]]]]) +.. function:: set_cookie([$name = ''[, $value = ''[, $expire = ''[, $domain = ''[, $path = '/'[, $prefix = ''[, $secure = FALSE[, $httponly = FALSE]]]]]]]]) :param mixed $name: Cookie name *or* associative array of all of the parameters available to this function @@ -44,7 +44,7 @@ The following functions are available: ``CI_Input::set_cookie()``. -.. function:: get_cookie($index = '', $xss_clean = FALSE) +.. function:: get_cookie([$index = ''[, $xss_clean = FALSE]]) :param string $index: Cookie name :param bool $xss_clean: Whether to apply XSS filtering to the returned value @@ -55,7 +55,7 @@ The following functions are available: description of its use, as this function is an alias for ``CI_Input::cookie()``. -.. function:: delete_cookie($name = '', $domain = '', $path = '/', $prefix = '') +.. function:: delete_cookie([$name = ''[, $domain = ''[, $path = '/'[, $prefix = '']]]]) :param string $name: Cookie name :param string $domain: Cookie domain (usually: .yourdomain.com) -- cgit v1.2.3-24-g4f1b From 04535c7169aa9401a3cf09c256df8319a67b778e Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Mon, 6 Jan 2014 10:57:05 +0200 Subject: [ci skip] Update the Input library and Cookie helper docs --- user_guide_src/source/helpers/cookie_helper.rst | 43 ++++++++++++------------- 1 file changed, 20 insertions(+), 23 deletions(-) (limited to 'user_guide_src/source/helpers/cookie_helper.rst') diff --git a/user_guide_src/source/helpers/cookie_helper.rst b/user_guide_src/source/helpers/cookie_helper.rst index e70893f2f..2e8db5f31 100644 --- a/user_guide_src/source/helpers/cookie_helper.rst +++ b/user_guide_src/source/helpers/cookie_helper.rst @@ -25,18 +25,17 @@ Available Functions The following functions are available: -.. function:: set_cookie([$name = ''[, $value = ''[, $expire = ''[, $domain = ''[, $path = '/'[, $prefix = ''[, $secure = FALSE[, $httponly = FALSE]]]]]]]]) - - :param mixed $name: Cookie name *or* associative array of all of - the parameters available to this function - :param string $value: Cookie value - :param int $expire: Number of seconds until expiration - :param string $domain: Cookie domain (usually: .yourdomain.com) - :param string $path: Cookie path - :param string $prefix: Cookie name prefix - :param bool $secure: Whether to only send the cookie through HTTPS - :param bool $httponly: Whether to hide the cookie from JavaScript - :returns: void +.. function:: set_cookie($name[, $value = ''[, $expire = ''[, $domain = ''[, $path = '/'[, $prefix = ''[, $secure = FALSE[, $httponly = FALSE]]]]]]]]) + + :param mixed $name: Cookie name *or* associative array of all of the parameters available to this function + :param string $value: Cookie value + :param int $expire: Number of seconds until expiration + :param string $domain: Cookie domain (usually: .yourdomain.com) + :param string $path: Cookie path + :param string $prefix: Cookie name prefix + :param bool $secure: Whether to only send the cookie through HTTPS + :param bool $httponly: Whether to hide the cookie from JavaScript + :returns: void This helper function gives you view file friendly syntax to set browser cookies. Refer to the :doc:`Input Library <../libraries/input>` for a @@ -44,28 +43,27 @@ The following functions are available: ``CI_Input::set_cookie()``. -.. function:: get_cookie([$index = ''[, $xss_clean = FALSE]]) +.. function:: get_cookie($index[, $xss_clean = FALSE]]) - :param string $index: Cookie name - :param bool $xss_clean: Whether to apply XSS filtering to the returned value - :returns: mixed + :param string $index: Cookie name + :param bool $xss_clean: Whether to apply XSS filtering to the returned value + :returns: mixed This helper function gives you view file friendly syntax to get browser cookies. Refer to the :doc:`Input Library <../libraries/input>` for a description of its use, as this function is an alias for ``CI_Input::cookie()``. -.. function:: delete_cookie([$name = ''[, $domain = ''[, $path = '/'[, $prefix = '']]]]) +.. function:: delete_cookie($name[, $domain = ''[, $path = '/'[, $prefix = '']]]]) - :param string $name: Cookie name - :param string $domain: Cookie domain (usually: .yourdomain.com) - :param string $path: Cookie path - :param string $prefix: Cookie name prefix + :param string $name: Cookie name + :param string $domain: Cookie domain (usually: .yourdomain.com) + :param string $path: Cookie path + :param string $prefix: Cookie name prefix :returns: void Lets you delete a cookie. Unless you've set a custom path or other values, only the name of the cookie is needed. - :: delete_cookie('name'); @@ -74,7 +72,6 @@ The following functions are available: does not have the value and expiration parameters. You can submit an array of values in the first parameter or you can set discrete parameters. - :: delete_cookie($name, $domain, $path, $prefix) \ No newline at end of file -- cgit v1.2.3-24-g4f1b From 88ebdf7ad98c2d24f9ba6b9839ab50c98cf0eb65 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Wed, 8 Jan 2014 17:28:02 +0200 Subject: [ci skip] Update the Input library and Cookie helper docs default value is now NULL --- user_guide_src/source/helpers/cookie_helper.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'user_guide_src/source/helpers/cookie_helper.rst') diff --git a/user_guide_src/source/helpers/cookie_helper.rst b/user_guide_src/source/helpers/cookie_helper.rst index 2e8db5f31..3b594170d 100644 --- a/user_guide_src/source/helpers/cookie_helper.rst +++ b/user_guide_src/source/helpers/cookie_helper.rst @@ -43,7 +43,7 @@ The following functions are available: ``CI_Input::set_cookie()``. -.. function:: get_cookie($index[, $xss_clean = FALSE]]) +.. function:: get_cookie($index[, $xss_clean = NULL]]) :param string $index: Cookie name :param bool $xss_clean: Whether to apply XSS filtering to the returned value -- cgit v1.2.3-24-g4f1b From 3de130c2da3b93a3404f264e92d7b65354de3548 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Fri, 7 Feb 2014 23:31:49 +0200 Subject: [ci skip] Add return types to helper docs (+ some other formatting) --- user_guide_src/source/helpers/cookie_helper.rst | 35 +++++++++++++------------ 1 file changed, 18 insertions(+), 17 deletions(-) (limited to 'user_guide_src/source/helpers/cookie_helper.rst') diff --git a/user_guide_src/source/helpers/cookie_helper.rst b/user_guide_src/source/helpers/cookie_helper.rst index 3b594170d..22fd0f77f 100644 --- a/user_guide_src/source/helpers/cookie_helper.rst +++ b/user_guide_src/source/helpers/cookie_helper.rst @@ -27,15 +27,15 @@ The following functions are available: .. function:: set_cookie($name[, $value = ''[, $expire = ''[, $domain = ''[, $path = '/'[, $prefix = ''[, $secure = FALSE[, $httponly = FALSE]]]]]]]]) - :param mixed $name: Cookie name *or* associative array of all of the parameters available to this function - :param string $value: Cookie value - :param int $expire: Number of seconds until expiration - :param string $domain: Cookie domain (usually: .yourdomain.com) - :param string $path: Cookie path - :param string $prefix: Cookie name prefix - :param bool $secure: Whether to only send the cookie through HTTPS - :param bool $httponly: Whether to hide the cookie from JavaScript - :returns: void + :param mixed $name: Cookie name *or* associative array of all of the parameters available to this function + :param string $value: Cookie value + :param int $expire: Number of seconds until expiration + :param string $domain: Cookie domain (usually: .yourdomain.com) + :param string $path: Cookie path + :param string $prefix: Cookie name prefix + :param bool $secure: Whether to only send the cookie through HTTPS + :param bool $httponly: Whether to hide the cookie from JavaScript + :rtype: void This helper function gives you view file friendly syntax to set browser cookies. Refer to the :doc:`Input Library <../libraries/input>` for a @@ -45,9 +45,10 @@ The following functions are available: .. function:: get_cookie($index[, $xss_clean = NULL]]) - :param string $index: Cookie name - :param bool $xss_clean: Whether to apply XSS filtering to the returned value - :returns: mixed + :param string $index: Cookie name + :param bool $xss_clean: Whether to apply XSS filtering to the returned value + :returns: The cookie value or NULL if not found + :rtype: mixed This helper function gives you view file friendly syntax to get browser cookies. Refer to the :doc:`Input Library <../libraries/input>` for a @@ -56,11 +57,11 @@ The following functions are available: .. function:: delete_cookie($name[, $domain = ''[, $path = '/'[, $prefix = '']]]]) - :param string $name: Cookie name - :param string $domain: Cookie domain (usually: .yourdomain.com) - :param string $path: Cookie path - :param string $prefix: Cookie name prefix - :returns: void + :param string $name: Cookie name + :param string $domain: Cookie domain (usually: .yourdomain.com) + :param string $path: Cookie path + :param string $prefix: Cookie name prefix + :rtype: void Lets you delete a cookie. Unless you've set a custom path or other values, only the name of the cookie is needed. -- cgit v1.2.3-24-g4f1b