| API | Package | Subpackage | Class | Method | Reference | Last reviewed | Doc status |
|---|---|---|---|---|---|---|---|
Home |
Joomla.Framework |
Document |
JDocumentHTML |
setBase |
setBase() |
Never | Work in Progress |
Sets the document base URL tag.
void setBase ( $url )
| $url | string | is a string containing the url to be used in the base tag. |
Set the document base URL tag.
Example
global $mainframe; $document =& JFactory::getDocument(); $document->setBase( $mainframe->getBaseURL() );
might result in the following base tag in the head block:
Result
<base href="http://127.0.0.1/joomla11/" />