[solved] What is the preferred method to include JQuery?

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
User avatar
stefhoesli
Forum Members
Forum Members
Posts: 56
Joined: Mon Sep 19, 2011 1:06 pm
Location: Zurich, Switzerland

[solved] What is the preferred method to include JQuery?

Post by stefhoesli »

I am currently using

Code: Select all

<__script__ type="text/JavaScript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></__script> 
inside my CMSMS templates in order to use JQuery. But I am not sure if this is the preferred method?

I have seen that there is a cms_jquery tag, but I have not yet understood how this is supposed to work. I also read that the Gallery module has JQuery "built in". So can I have an "empty" Gallery command on my page and then use JQuery for something else?

What I actually want to achieve are dynamic filters and/or search fields in conjunction with the "Calguys User Directory" module, so that it is possible to search for and sort by different properties of the FEUsers. (Maybe JQuery would be an overkill for this, since there is a propvals action in the CGUserDirectory module that may be able to give me what I need. Does anybody know of an example implementation with the propvals action that I could check out?)

I will also have a look at this UDT: http://forum.cmsmadesimple.org/viewtopi ... =7&t=57118
Last edited by stefhoesli on Thu Jan 29, 2015 12:19 pm, edited 1 time in total.
User avatar
stefhoesli
Forum Members
Forum Members
Posts: 56
Joined: Mon Sep 19, 2011 1:06 pm
Location: Zurich, Switzerland

Re: What is the preferred method to include JQuery?

Post by stefhoesli »

The solution was right in front of my eyes:

There is a JQueryTools module:
http://dev.cmsmadesimple.org/projects/jquerytools
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1922
Joined: Mon Jan 29, 2007 4:47 pm

Re: [solved] What is the preferred method to include JQuery?

Post by Jo Morg »

There is no preferred method of including JQuery, as it is much to each one's own preferred way of developing. However CMSMS does provide with it's own tag out of the box: {cms_jquery}...
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
Post Reply

Return to “Modules/Add-Ons”