Re: Pass a relative path [with slashes] into a 'clean' url

From: Date: Tue, 05 Dec 2006 18:37:16 +0000
Subject: Re: Pass a relative path [with slashes] into a 'clean' url
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-245528@lists.php.net to get a copy of this message
Assuming you mean URLs as GET variable values, urlencode() and urldecode() might be the ticket:
    http://ca.php.net/urlencode
Aaron On 12/4/06, Graham Anderson <grahama@siren.cc> wrote:
What is a good/accepted way to pass a relative or absolute path into a clean url ? I could replace the relative url's slashes with another character, but would love to know a cleaner less confusing way...if it exists example url: http://localhost/testscript/../image.png/jpeg/420000/0/ example php: list($dummy,$relative_path,$type, $color, $cache) = explode('/', $_SERVER['PATH_INFO']); where: $relative_path=../image.png $type=jpeg $color=420000 $cache=0 many thanks in advance -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
-- +------------------------------------------------- | Aaron Koning | Information Technologist | Prince George, BC, Canada. +------------------------------------------------- | Flexible Internet Spatial Template: | http://fist-mapping.org +-------------------------------------------------

« previous php.general (#245528) next »