News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Sameer Borate's Blog:
Easy manipulation of URLs
November 10, 2009 @ 12:48:49

On his codediesel.com blog today Sameer Borate has a quick post looking at URL manipulation with the help of the Net_URL2 PEAR package.

Whether you are dynamically creating urls or changing existing ones, manipulation of urls is a frequent coding requirement during development; doing the same on short urls is easy, but quickly becomes complex for urls which have larger query parameters.

He shows how to use the package to parse the current URL into its respective parts (host, port, path, etc) and how to automatically change certain parameters in the current URL and push the updated version back out the other side. There's also a bit there at the end on normalizing URLs.

0 comments voice your opinion now!
url manipulation pear neturl2 package


blog comments powered by Disqus

Similar Posts

Pierre-Alain Joye's Blog: Finally some new features are coming, zip-1.9.0 serie began

Stubbles Blog: Stubbles 0.2.0 released

Zend Developer Zone: Using the Stack Exchange API with PHP (part 1)

Juozas Kaziukenas' Blog: Creating Excel documents on the fly

Travis Swicegood's Blog: With friends like these... (or a PEAR Contribution Story)


Community Events





Don't see your event here?
Let us know!


community tips series threedevsandamaybe developer opinion zendserver release language podcast laravel api symfony library interview framework list deployment introduction bugfix

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework