This widget encapsulates the Taconite jQuery plugin (Version 3.59).
The plugin is a port of Taconite to jQuery. Make multiple DOM manipulations in response to a single remote call using an XML command document.
Yii 1.1.6 or above...
<h1>Example 1: Structure</h1> <p> This example shows how you can easily manipulate the structure of the DOM. </p> <input id="ex1" type="button" value="Run Example 1" /> <hr /> <div id="example1" style="background-color: #ffa; padding:10px; border:1px solid #ccc"> This is the <span style="color:#800">structure example</span> div. </div> <?php $widget=$this->widget('ext.taconite.JTaconite'); $widget->addEventHandler('#ex1','click',array( JTaconite::get("files/example1.php?ts='+new Date().getTime()); });") )); $widget->registerScript(); <br />
header('Content-type: text/xml'); <taconite> <after select="#example1"> This text will go AFTER the example div. </after> <before select="#example1"> <div>This div will go BEFORE the example div.</div> </before> <wrap select="#example1 span"> <span style="border: 1px dashed #00F"></span> </wrap> <append select="#example1"> <div>This div is APPENDED</div> </append> </taconite>
Total 6 comments
build an array -> json econde and that's it
i love xml and xslt, but i think there's not a solution that's is always the best.
there's nothing wrong about diversity :P
Why indeed! JSON is a great data exchange format. But it's not the best solution for every problem. I've found that JSON is not ideal for working with complex data structures. It can work, but it requires careful coding on both the client and server tiers. In comparison, the Taconite model only requires that the server return valid XHTML. There is no coding required on the client at all!
Thanks,
once i have enough time to clean it up sure
@ nickcv, can you also share the json version this?
i did something like this but using jsons
i'm going to try this with my xslt based application
Leave a comment
Please login to leave your comment.