What's the best way to work with jquery plugins ? - 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: What's the best way to work with jquery plugins ? (/showthread.php?tid=25241) |
What's the best way to work with jquery plugins ? - El Forum - 12-05-2009 [eluser]chefnelone[/eluser] Hello I use to work with jquery plugins. Usually I load them in my view page (let say index.php). I'm just wondering if is there a better way to load a jquery plugin. Let's say I use to work with just 1 of 2 menu plugins: menu1 and menu2. For them I have the folders: Menu1 and Menu2 and inside of each one the js and css files to make the plugin works. At the moment I choose one of them I insert the path in view/index.php: <link rel="stylesheet" href="<?php echo base_url();?>plugins/Menu1/menu1.css" /> [removed] [removed] or: <link rel="stylesheet" href="<?php echo base_url();?>plugins/Menu2/menu2.css" /> [removed] [removed] My question is: is there a better way to work with this kind of plugins. Maybe saving them in a folder and then loading then from a controller ? hope someone understand what I mean... Thanks What's the best way to work with jquery plugins ? - El Forum - 12-05-2009 [eluser]CroNiX[/eluser] Yes, there are asset managers which can do that for loading css/js/metadata into the head of the document at runtime based on the config file or what you tell it to directly from the controller. Very handy. Here is one: http://ellislab.com/forums/viewthread/101236/ There are more but I haven't personally used them. What's the best way to work with jquery plugins ? - El Forum - 12-05-2009 [eluser]garymardell[/eluser] Personal favourite is: http://codeigniter.com/wiki/Carabiner/ What's the best way to work with jquery plugins ? - El Forum - 12-06-2009 [eluser]chefnelone[/eluser] both of them looks really good, I think I will try Carabiner . thanks What's the best way to work with jquery plugins ? - El Forum - 12-06-2009 [eluser]Unknown[/eluser] It was my problem too. Thank u What's the best way to work with jquery plugins ? - El Forum - 12-06-2009 [eluser]umefarooq[/eluser] Carabiner is the best solution for these stuff, you can use css or js if it is required for some section. |