Sitebase does not currently provide support for this item.

13 comments found.

cool, but too expensive, maybe for 5$ i’ll buy it.

I’ve lowered the price :)

Thanks Chris!

Still, IMO , it’s too expensive, simply because you’re just putting the html out there – it’s not exactly hard to make your own.

Lowered the price again :)

Much better thanks


MGK Purchased

I was wondering if this was necessary or no since a good code shouldn’t have html within the php area.

But then, I just realized that the html area might (and usually does) contain php code (unless its static).

Conclusion, just bought it, will test and give a review, but knowing you (from here) I’m sure that’s quality.

Best regards, MGK

Thanks man :)

Just been having a look at the screen shot/preview and I notice that it can be used for

<?php echo HtmlHelper::script('script.js') ?>

Which would load a file called script.js but could it be used for something like this?

<script type="text/javascript"> function command(command,form,text) { window.opener.document.forms[form].elements[text].value = window.opener.document.forms[form].elements[text].value+command+' '; window.opener.document.forms[form].elements[text].focus(); window.close(); } </script>

Sorry for how the code looks I could not get it to post on separate lines.

You can use [pre] tags around your code to format it here. The open and close tags are possible to write with my script but the javasript self not. It will look like this if you write is with my script:

<?php HtmlHelper::openTag('script', array('type' ?> 'text/javascript')); ?>
your javascript here
<?php HtmlHelper::closeTag('script'); ?>

As you can see it’s not really usefull to use the class in this case.

Thank you for the info, my last question is can you join elements together?

I see you have these two

echo HtmlHelper::img('thumb.jpg', 80, 80, 'Example image', array('border' => '0'));
echo HtmlHelper::a('', 'Visit Sitebase', array('target' => '_blank'));

Can they be joined so that the image is linked into the url, as normally I’d use something along the lines of-

<a href=""><img src="thumb.jpg" border="0" height="80" alt="Visit Sitebase" width="80" /></a>

That is indeed possible. You will do that as follow:

$image = HtmlHelper::img('thumb.jpg', 80, 80, 'Example image', array('border' => '0'));
echo HtmlHelper::a('', $image, array('target' => '_blank'));

New version is available now!

Sitebase, how is this any better than just doing the HTML normally, like this:

<a href="<?php echo $link; ?>"><?php echo $linkName; ?></a>

Anybody who could figure this out could figure HTML out. So I’d just like to know what makes it better?

For just a simple link it’s indeed better to just echo the html. But once you start using optional parameter based on php variables and stuff, this class will make your code much more readable.

I really want to see a sample. Current sample is broken

Why did you make a static class as a What’s the benefit?

What can we do as a public loss yap?labilirmi

This Author is no longer around.

Will you be making a Twitter Bootstrap version of this any time soon? That would be amazing!