views:

63

answers:

1

Hello I am not able to understand how to use jQuery plug-ins in cakePHP. I have one plug-in by the name "countdown". It has 2 js files, one html, one css file and a few images. If I were using regular javascript file, I'd have to give a name to my file and call it in the view or in default.ctp using the "$html->script('path/to/file')" function. But now I have other files too, and if I put them in separate folders complying with the cake structure. But then, I would also have to edit the files with changed paths.

Is there an easy way than putting them in separate folders?

+2  A: 

I would simply put them all in your (assumed) app/webroot/js/jquery/plugins/<plugin-name>/.

I see the whole package as something that belongs to js folder, not the individual files.

dr Hannibal Lecter
I believe you are right! I still haven't solved my problem though! I can just get some alerts to test if he plugins are doing what they have to do.
macha