!!! Replacing tabs HTML with smarty block functions 2005-05-09
i have just replaced the existing html tabs code with smarty block functions. now, all you need to do to get tabs on your page is use the following code:
-{code()}
+{code source=PHP}
{jstabs}
{jstab title="foo"}
some useless text
@@ -29,7 +29,7 @@
some more useless text
{/jstab}
{/jstabs}
-{code}
+{/code}
The reason why we do this, is to allow for a simpler template code, an easier, centralised control of the tabs code and an easier way of changing to a different tabs script if needed.
!!! $areaName to $textarea_id 2005-05-15
@@ -97,13 +97,13 @@
i propose we pass a comma separated list of values to a smarty function, which does the rest
to view a full list of options please see the file
kernel/smarty_tiki/function.smartlink.php
@@ -111,37 +111,37 @@
!! reducing number of divs
the number of divs used in bitweaver is still a bit excessive. perhaps we can find a couple more places where these can removed / changed to something else:
-{code(color=css)}
+{code source=Html4Strict}
<div class="box">
<div class="boxtitle">foo</div>
<div class="boxcontent">bar</div>
</div>
-{code}
+{/code}
could become:
-{code(color=css)}
+{code source=Html4Strict}
<div class="box">
<h3>foo</h3>
<p>bar</p>
</div>
-{code}
+{/code}
would allow for same amount of styling freedom. the only downside is that <p> doesn't allow block elements in xhtml, which means that we have to close off </p> before adding divs and lists