• Howdy! Welcome to our community of more than 130.000 members devoted to web hosting. This is a great place to get special offers from web hosts and post your own requests or ads. To start posting sign up here. Cheers! /Peo, FreeWebSpace.net
managed wordpress hosting

WordPress development question.

I want to add a valid CSS and valid XHTML button to a widget/plugin which has to work on every WordPress site that it gets installed on. I need some kind of code that gets the root url or something.
 
If you just need the root url, you can echo the $_SERVER['SERVER_NAME'] variable. There's also the $_SERVER['REQUEST_URI'] variable for getting the part of the path after the base URL.

You can do it with javascript, too with document.URL or window.location.href.

Not entirely sure if this is what you were looking for.
 
whatever you do, when using wordpress... ALWAYS do the updates, and install the WordFence plugin for more security
 
Back
Top