Update jQuery version

Using Servoy to administrate the content of your website? Discuss all webrelated Servoy topics on this forum!

Update jQuery version

Postby Janssenjos » Tue Sep 24, 2013 12:31 pm

Hi,

Is it possible to update the jquery.js file that servoy is using?
Now I have the follwing include:
Code: Select all
<script type="text/javascript" src="resources/mask/jquery.min.js?w:lm=1360918136"></script>


But this version is too old, I need a newer version of jQuery. Is there any way to update the .js file that Servoy takes and includes?
Or maybe a way to remove this include?

Thanks!
Jos Janssen
Software Developer
Axerrio
http://www.axerrio.com
Janssenjos
 
Posts: 148
Joined: Thu Aug 13, 2009 3:55 pm
Location: Bergen op Zoom

Re: Update jQuery version

Postby david » Wed Sep 25, 2013 12:35 am

The jquery resource is located in:

Code: Select all
//you-host/servoy-webclient/resources/servoyjs/jquery/jquery-1.8.2.min.js


I would try replacing this file out with a new version (rename the new version the same as the old as it's most likely referenced by exact name upstream somewhere). You'll have to connect to this directory via webdav. (On a mac > Finder > Go menu > Connect to server... > http://localhost:8080/servoy-webclient/ ... yjs/jquery.)

The deal with Servoy's various webdav directories is that they are generated by Servoy as web client solutions are spun up. If you modify one of those files yourself, Servoy will not overwrite your modification. So your "new" jquery file should be loaded in via the normal Servoy process of producing web pages.
David Workman, Kabootit

Image
Everything you need to build great apps with Servoy
User avatar
david
 
Posts: 1727
Joined: Thu Apr 24, 2003 4:18 pm
Location: Washington, D.C.

Re: Update jQuery version

Postby Janssenjos » Wed Sep 25, 2013 8:48 am

Thanks for the answer. But i don't really get it :)

So everytime I import a new solution, i should replace the jquery file at that location.
In development (i'm not on a mac) I go to http://localhost:8084/servoy-webclient/ ... js/jquery/ (or ..../jquery-1.8.2.min.js) and i get a 404 page.

Where does servoy gets the jquery.js file from, which it uses to put it there?
Jos Janssen
Software Developer
Axerrio
http://www.axerrio.com
Janssenjos
 
Posts: 148
Joined: Thu Aug 13, 2009 3:55 pm
Location: Bergen op Zoom

Re: Update jQuery version

Postby Janssenjos » Wed Sep 25, 2013 9:19 am

I'm going to use the following work-around:

I will use a javascript function to find the jquery.min.js and remove this include:http://www.javascriptkit.com/javatutors/loadjavascriptcss2.shtml#.UkKGnYbIZMY.

And then i will include the latest jquery myself.
Jos Janssen
Software Developer
Axerrio
http://www.axerrio.com
Janssenjos
 
Posts: 148
Joined: Thu Aug 13, 2009 3:55 pm
Location: Bergen op Zoom

Re: Update jQuery version

Postby ngervasi » Wed Sep 25, 2013 10:24 am

I'm not sure it's a good idea, I would check with servoy support first.
Nicola Gervasi
sintpro.com
SAN Partner
ngervasi
 
Posts: 1485
Joined: Tue Dec 21, 2004 12:47 pm
Location: Arezzo, Italy

Re: Update jQuery version

Postby david » Thu Sep 26, 2013 12:10 am

Just tested the webdav and turns out Servoy only exposes the ../templates directory via webdav. Checked with Troy and he has tested newer versions of jquery with Servoy using URLRewrite and the following rule:

Code: Select all
<rule enabled="true">
<name>Servoy jQuery debug</name>
<note>Find issues in included jQuery plugins</note>
<from>^/servoy-webclient/resources/servoyjs/jquery/jquery-1.8.2.min.js(.*)$</from>
<to last="true">/ds/jquery.debug.js$1</to>
</rule>


Apparently newer versions of jquery do break all kinds of things in Servoy web client though as Nicola warns.
David Workman, Kabootit

Image
Everything you need to build great apps with Servoy
User avatar
david
 
Posts: 1727
Joined: Thu Apr 24, 2003 4:18 pm
Location: Washington, D.C.

Re: Update jQuery version

Postby jcompagner » Thu Sep 26, 2013 9:55 am

from jquery 1.9 they removed a lot of depricated api (i still think this is really a bad move from them, on the wicket list there where also quite a lot of discussions about this)
So many older stuff that did depend on that where completely broken.
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8833
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet


Return to Web Development

Who is online

Users browsing this forum: No registered users and 5 guests

cron