How can I generate a formatted HTML file with PHP? Answered
I'm doing a major reconstruction of my website. I want it to be more dynamic and interactive (CMS), something like Instructables. I already started the login-logout cookie system, establish a MySQL database and found a user friendly text editor. I'm planning to buy a ".com" domain if I get the system to work.
I'm not trying to compete with ibles or anything, but rather just want to make a site where I can post guides then display it on my homepage. Similar to the GUI of ibles.
Can you guys help me find a decent PHP code that would generate formatted html files, so that I would be able to post step-by-step guides similar to instructables... Don't worry about the database, and the text editor, I'll just figure it out.
As a sign of gratitude, I would like to gave away a patch or a 3 month Pro-membership to the person who gets the best answer :D
//I found a code, but sadly I can't get it to work :(
// These are the default options, so might
// as well have initialized KvzHTML with an
// empty first argument
$H = new KvzHTML(array(
'xhtml' => true,
'track_toc' => false,
'link_toc' => true,
'indentation' => 4,
'newlines' => true,
'echo' => false,
'buffer' => false,
'xml' => false,
'tidy' => false,
$H->h1('Important website') .
$H->p('Welcome to our website.') .
$H->p('Here\'s a list of current users:') .
$H->tr($H->th('id') . $H->th('name') . $H->th('age')) .
$H->tr($H->td('#1') . $H->td('Kevin van Zonneveld') . $H->td('26')) .
$H->tr($H->td('#2') . $H->td('Foo Bar') . $H->td('28'))