/ Published in: JavaScript
This is a script that can parse a URL string, and return all components in a systematic way via an object.
This script is very useful in places where you want to link to a page "dynamically" generated by javascript. This is usually done by adding GET-like params after a # in the URL.
This parser can parse URLs like:
* http://jrharshath.com/
* http://jrharshath.com/page?param=value
* http://jrharshath.com/page?param=value¶m2=value2
* http://jrharshath.com/some?serverparam=somevalue#JSFeature?param=val¶m2=val2
* http://jrharshath.com/some?serverparam=somevalue#AjaxPage?param=val¶m2=val2#AnotherAjaxFeature?featureparam=featureval
This script is very useful in places where you want to link to a page "dynamically" generated by javascript. This is usually done by adding GET-like params after a # in the URL.
This parser can parse URLs like:
* http://jrharshath.com/
* http://jrharshath.com/page?param=value
* http://jrharshath.com/page?param=value¶m2=value2
* http://jrharshath.com/some?serverparam=somevalue#JSFeature?param=val¶m2=val2
* http://jrharshath.com/some?serverparam=somevalue#AjaxPage?param=val¶m2=val2#AnotherAjaxFeature?featureparam=featureval
URL: http://jrharshath.wordpress.com/