![]() |
Javascript and Jquery Library usage and documentation - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Javascript and Jquery Library usage and documentation (/showthread.php?tid=38047) |
Javascript and Jquery Library usage and documentation - El Forum - 01-28-2011 [eluser]matula[/eluser] I'm trying to figure out how to use the javascript library, and either the documentation isn't clear... or I'm just not understanding. I can load the javascript library, and access it's methods fine: Code: $this->load->library('javascript'); After some playing around, I get things like this work: Code: $js = $this->javascript->click('#button', $this->javascript->animate('#box', array('width'=>'200%'), 'normal')); Any ideas on how this library is supposed to work? -Terry Javascript and Jquery Library usage and documentation - El Forum - 01-29-2011 [eluser]Vanitas[/eluser] I'm trying to understand it to. I think that by using Code: $this->load->library('javascript'); Code: $this->jquery->event('element_path', code_to_run()); More unclear matter is event handling: Code: $this->jquery->click('selector_one', $this->jquery->toggleClass('selector_again?', 'some_class')); I hope some tutorials will appear in the Internet soon. Javascript and Jquery Library usage and documentation - El Forum - 01-29-2011 [eluser]nedimtx[/eluser] This video tutorial might be useful for you.. http://net.tutsplus.com/videos/screencasts/codeigniter-from-scratch-day-8-ajax/ Javascript and Jquery Library usage and documentation - El Forum - 01-29-2011 [eluser]Vanitas[/eluser] I already saw it ;p This is an example of using JQuery 'beside' CodeIgniter. I don't like it - it makes mess in views code. I'm waiting for day when JQuery library for CI will be as powerfull as 'normal' JQuery (because I don't see any way to write as flexible code as it is in 'normal' JQuery). Javascript and Jquery Library usage and documentation - El Forum - 01-29-2011 [eluser]Sayian[/eluser] I am also lost about how to use this. I have tried for hours to get it to work and cannot. |