<?php

	include 'http_build_url.php';

	$sParent	= 'http://fuelforthefire.ca/free/php/http_build_url/';

	// 1 Join
	$sRelative	= '../../../main/about';
	echo '1: ',http_build_url($sRelative, $sParent, HTTP_URL_JOIN_PATH),'<br />';

	// 2 Join
	$sRelative	= '/main/about';
	echo '2: ',http_build_url($sRelative, $sParent, HTTP_URL_JOIN_PATH),'<br />';

	// 3 Join
	$sRelative	= './example.php';
	echo '3: ',http_build_url($sRelative, $sParent, HTTP_URL_JOIN_PATH),'<br />';

	// 4 Replace
	$aReplace['query']	= 'this=is&a=test';
	echo '4: ',http_build_url($aReplace, $sParent),'<br />';

	// 5 Strip
	echo '5: ',http_build_url($sParent, array(), HTTP_URL_STRIP_PATH),'<br />';