PHP Classes

File: parseurl_test.php

Recommend this page to a friend!
  Classes of Konstantinos Dafalias   cParseurl   parseurl_test.php   Download  
File: parseurl_test.php
Role: Example script
Content type: text/plain
Description: Example script
Class: cParseurl
Wrapper around the PHP parse_url function
Author: By
Last change:
Date: 18 years ago
Size: 683 bytes
 

Contents

Class file image Download
<?php
/**
* This file tests the Class cParseurl and displays the
* Output:
* cparseurl Object
* (
* [scheme] => http
* [host] => www.domain.com
* [port] =>
* [user] =>
* [pass] =>
* [path] => /mypath/myfile.php
* [query] => a=1&b=2&c=3
* [fragment] =>
* [domain] => domain.com
* [tld] => com
* [bdomain] => domain
* [aHost] => Array
* (
* [0] => www
* [1] => domain
* [2] => com
* )
* )
*/

include("cParseurl.php");
$oParseurl = new cParseurl("www.domain.com/mypath/myfile.php?a=1&b=2&c=3");
echo(
"<pre>");
print_r($oParseurl);
echo(
"</pre>");
?>