summaryrefslogtreecommitdiffstats
path: root/system/helpers/url_helper.php
AgeCommit message (Collapse)AuthorFilesLines
2013-02-22Merge branch 'develop' of github.com:EllisLab/CodeIgniter into ↵Daniel Hunsaker1-9/+10
feature/exit-status
2013-01-28Fix auto_link() for the Nth timeAndrey Andreev1-9/+10
- anchor() is for local links and breaks ones that don't have a protocol prefix - Allow :// links (no actual protocol specified) - Further simplified the URL regular expression
2013-01-25Updated all cases of exit() to return a valid codeDaniel Hunsaker1-1/+1
Specific codes are as follows, but can easily be changed if a different order/breakdown makes more sense: - 0: Success; everything executed as planned - 1: Configuration Error; something is wrong with/in the configuration file(s) - 2: Class Not Found; what it says - 3: Driver Method Unsupported; the method you're trying to use on a Driver doesn't exist - 4: File Not Found; 404 error - 5: Database Error; something is broken in the database somewhere - 6: Invalid Input; the user attempted to submit a request with invlaid characters in 1+ key names 7 through 26 are reserved for future use - 27: Generic Error; generated by show_error() when the status code is >= 100 28 through 127 are errors generated by user applications, normally by using show_error() with a status code below 100 128 through 254 should not be used by applications, as they are reserved by system-level functions - 255: PHP Fatal Error; automatically generated by PHP for fatal errors, and therefore not allowed for our use Status codes below 100 are shifted up by 28 to place them in the user error range. It may make more sense to have these codes left alone and instead shift the CI errors into the 101 through 127 space, but that's not what I opted for here. It would probably also be a good idea to replace the hard-coded numbers with constants or some such, but I was in a bit of a hurry when I made these changes, so I didn't look around for the best place to do this. With proper guidance, I could easily amend this commit with another that uses such constant values. Signed-off-by: Daniel Hunsaker <danhunsaker@gmail.com>
2013-01-21Adjust regex.Eric Roberts1-1/+1
2013-01-19Remove whitespace from empty lines.Eric Roberts1-5/+5
Signed-off-by: Eric Roberts <eric@cryode.com>
2013-01-18Fix and optimize auto_link() URL helper function.Eric Roberts1-31/+22
Signed-off-by: Eric Roberts <eric@cryode.com>
2013-01-17Fix issues #2160, #2161Andrey Andreev1-11/+6
2013-01-01[ci skip] Happy new yearAndrey Andreev1-1/+1
2012-12-08While most of CodeIgniter supports protocol-relative URLs, a few URL helpers ↵Aaron Adams1-3/+3
do not. Most notably, redirect('//www.facebook.com/aaronadams') led my browser to https://aaronadams.ca/index.php/www.facebook.com/aaronadams. In this commit, I have fixed the header() helper, along with the anchor() and anchor_popup() helpers, to be compatible with protocol-relative URLs. Signed-off-by: Aaron Adams <aaron@aaronadams.ca>
2012-12-03[ci skip] Cleaned some spacesAndrey Andreev1-1/+1
2012-11-09Polish docs for URL and XML helpers and deprecate obsolete options for ↵Andrey Andreev1-7/+10
String helper random_string() and URL helper url_title()
2012-11-01Manually apply PR #1594 (fixing phpdoc page-level generation/warnings)Andrey Andreev1-1/+2
Also partially fixes issue #1295, fixes inconsistencies in some page-level docblocks and adds include checks in language files.
2012-10-25Add missing delimiter in preg_quote() occurences (fix #1929)Andrey Andreev1-1/+1
2012-10-19Manually apply an improved version of PR #1797 (auto_link() URL helper)Andrey Andreev1-9/+12
2012-09-12Better server test in redirect() of URL helpervlakoff1-1/+1
"Location" header bugs are specific to IIS; previous test was matching all HTTP servers under Windows. This test isn't perfect yet ($_SERVER['SERVER_SOFTWARE'], which corresponds to the "Server" header of HTTP response, might be missing), but there is no perfect test. "Refresh" method makes the window blank for quite a noticeable time, so let's not affect other servers because of IIS.
2012-07-29Adding a common stringify_attributes function for dealing with attributes ↵Eric Barnes1-46/+4
through out various helpers. Signed-off-by: Eric Barnes <eric@ericlbarnes.com>
2012-06-27URL Helper redirect() to utilize HTTP/1.1 response code 303 See OtherAndrey Andreev1-3/+11
2012-06-16anchor_popup() improvementsAndrey Andreev1-3/+13
2012-06-16Fix two anchor_popup() issuesAndrey Andreev1-5/+2
2012-06-02Replaced `==` with `===` and `!=` with `!==` in /system/helpersAlex Bilbie1-12/+12
2012-05-17Merge upstreamTimothy Warren1-2/+2
2012-05-17Clean up the helpersAndrey Andreev1-2/+2
2012-04-27Fix rest of the helpersTimothy Warren1-133/+135
2012-03-26Remove access description lines and cleanup the url helperAndrey Andreev1-37/+22
2012-03-09Bumped CodeIgniter's PHP requirement to 5.2.4.Phil Sturgeon1-1/+1
Yes I know PHP 5.4 just came out, and yes I know PHP 5.3 has lovely features, but there are plenty of corporate systems running on CodeIgniter and PHP 5.3 still is not widely supported enough. CodeIgniter is great for distributed applications, and this is the highest we can reasonably go without breaking support. PHP 5.3 will most likely happen in another year or so. Fingers crossed on that one anyway...
2012-03-04Updated with 2.1-stable.Phil Sturgeon1-19/+15
2012-03-04Allow developers to use any string as a separator, not just dashes or ↵tubalmartin1-10/+19
underscores. Backwards compatible when using 'dash' or 'underscore' as string separator. Tests: http://codepad.org/DWcxVH5r
2012-03-03An even better url_title helper. Tests: http://codepad.org/tuJgvkyNtubalmartin1-20/+7
Changelog entry added for 2.1.1
2012-01-07Improve typography, url & xml helpersAndrey Andreev1-69/+61
2012-01-02Updating copyright date to 2012Greg Aker1-1/+1
2011-11-17auto_link() learned to recognize more URLs has2k11-1/+1
Problem: auto_link() only works on URLs that are preceded by a new line, space, or open parentheses. As a result the URL in the string below would be missed. 'Google<br />http://www.google.com/' Solution: Add a word boundary to the list of features that can precede a URL. Credit to: @scaryuncledevin, issue #419
2011-11-07Adding auto-detection of best redirect method in url_helper.Brandon Jones1-1/+7
2011-10-20adding new license file (OSL 3.0) and updating readme to ReSTDerek Jones1-4/+16
added notice of license to all source files. OSL to all except the few files we ship inside of the application folder, those are AFL. Updated license in user guide. incrementing next dev version to 3.0 due to licensing change
2011-08-26Merge branch 'develop' of github.com:EllisLab/CodeIgniter into developPhil Sturgeon1-1/+1
2011-08-24Changed doc block options. Fixes #100Eric Barnes1-1/+1
2011-08-21Merge branch 'develop' of https://github.com/waldmeister/codeigniter-reactor ↵Phil Sturgeon1-1/+1
into develop
2011-08-21Fixed problem with needless seperator at begin/end of stringDavid Behler1-1/+1
2011-07-02backed out 648b42a75739, which was a NON-trivial whitespace commit. It ↵Derek Jones1-3/+3
broke the Typography class's string replacements, for instance
2011-07-02hand merged remaining unresolved files following the backout of ↵Derek Jones1-3/+3
648b42a75739, which was a NON-trivial whitespace commit
2011-07-02backed out 648b42a75739, which was a NON-trivial whitespace commit. It ↵Derek Jones1-3/+3
broke the Typography class's string replacements, for instance
2011-06-15Merged base_url changes.philsturgeon1-4/+7
2011-04-25Fixed double-space typo.Razican1-3/+3
2011-02-03Made config->base_url() accept parameters. config->base_url($uri). Updated ↵anaxamaxan@blackdog.local1-4/+7
base_url() in url_helper accordingly.
2011-01-05Hey look, it's 2011Greg Aker1-1/+1
2010-11-10Updating PHP requirements in files 5.1.6Greg Aker1-1/+1
2010-10-04Cleanup of stray spaces and tabsBarry Mieny1-12/+12
2010-09-14Fixed a bug in the URL Helper where prep_url() could cause a PHP error on ↵Robin Sowell1-1/+3
PHP versions < 5.1.2.
2010-03-22expanded philsturgeon's bugfix to parse_url() and updated docs and changelogDerek Jones1-2/+2
2010-03-12prep_url() will now not append http:// to string if a protocol is already ↵Phil Sturgeon1-1/+1
used. That would really mess up itunes://, spotify://, telnet://, etc.
2010-01-05updated copyrightsDerek Jones1-1/+1