Relative to Absolute links

This function converts all relative links to absolute ones.

function VISION_TO_REL2ABS($content, $base = 'http://vision.to')
{

//based on http://cr.unchy.com/article/b1c37da1-70c3-dfbd-11ef-a8fbb46a65de
//modified and created as function by Femi Hasani [www.vision.to]
if (empty($base)) return $content;
//base url needs trailing /
if (substr($base, -1, 1) != "/")
$base = $base."/";
// Replace links
$content = preg_replace("/(href|src)="(?!http|ftp|https)([^"]*)"/", "="$base"",
$content);
// Done
return $content;

}

Misc Links, Resources

Upperhost best web hosting

Hobby Projects

Under development:
feedpixel.com - Feeding Your Pixels :-)
Sexy URL!
TAXI CMS Booking System
WebShop, Project Manager, Support System.

Recommended

Link Partners

Web Design Forum