Helix Installation   Getting Started   Reference Documentation   Global Functions   Quick Start
Getting StartedHelpful ResourcesAsk questions on the Help ForumRead the User GuideBrowse the Reference DocumentationSubscribe to the Helix Mailing ListLearning HelixAdvanced Topics

Creating Markup

You can create markup in your page files by simply adding plain HTML or by using classes in the Helix User Interface module.  The User Interface module has a class the corresponds to every HTML element, as well as classes or more complex user interface components built from other HTML elements.

Using Helix User Interface Classes

In order to create markup on your pages with the Helix User Interface classes, you simply open and close HTML elements using the static open() and close() methods available on every class that inherits from element.  Just call the open() method, echo some content, and then call the close() method for the element

See the code below for an example of how to create markup on a page:

// Open a div element and give it an id of "my-div"
// Echo some content
echo "This is the content inside my div";
// Close the div element

You can also create markup by constructing new markup objects and setting properties that correspond to the element attributes.

// Construct a new div element
$div = new div();
// Give the div an "id" and a "class" attribute;
$div->id "my-div";
$div->class "title-text";
// Render the div
echo $div
Get Helix PHP Framework at SourceForge.net. Fast, secure and Free Open Source software downloads