Forum
13:28
04/10/2008
in Safari 3. 1.2 on MacOS X 10.5.5, go to the jqGrid sample file :
http://trirand.com/jqgrid/example.html
then hit reload (press Cmd+R) and hte file goes blank. Hit Cmd-Opt-C for console, and you get this bizarre erorr on line 80:
Value undefined (result of expression jQuery("#list2").jqGrid) is not object.
13:51
Moderators
30/10/2007
Hello,
Just now I write this from Safari 3 Win. I do not see any error when testing
the demos
I'm sorry, but I do not have Mac to test.
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
13:57
Moderators
30/10/2007
Hello,
Sorry do not test the link that you write.
Yes there is problem. I will see what is this.
Thank you
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
13:57
04/10/2008
allllllllllllright. After a solid hour of scratching my head, I narrowed down the issue to one single problem : in jquery.jqGrid.js there is a mechanism for automatically adding javascript files to the HTML file that includes jquery.jqGrid.js
well, this one breaks under IExplorer 6 and safari. If I add the needed js files myself, and disable the loop
for(var i=0;i<modules.length; i++)
everything is swell !
For now, I can continue manually, but I guess it might be usefull for someone to fix this
14:03
Moderators
30/10/2007
Hello,
Maybe this is the problem, but if you open the demos and reloads all
is OK - right?
I will investigate this.
Thank you
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
14:11
04/10/2008
Yo Tony !
seemingly this is an old issue with safari :
http://lists.apple.com/archive.....00107.html (this is from 2004 !!!)
this guy did more testing :
http://www.webdeveloper.com/fo.....17817.html
I've done some inspecting, and the js files are properly attached to the head element, so this is NOT the problem. My guess is that the files are indeed added to the DOM, but they are parsed AFTER $(document).ready !!!
14:22
04/10/2008
the problem happens in ALL the demos, if you remove them from the tree structure ! This supports my theory : inside the tree, there is no problem with script loading followed immediately by a grid creation !
I did a small test in the exact same example.html : at $(document).ready(), start a 3 sec timer which then invokes the code as it is now inside doc.ready()
guess what ? It works !
So the issue is now narrowed down to : modifying the DOM to insert <script> elements will parse those scripts AFTER document.ready(), which obviously noodles any code inside doc.ready that depends on those scripts
hurray ! We're getting there !
14:25
Moderators
30/10/2007
Hello,
I will try another trick - to append the scripts in div
Regards
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
14:35
04/10/2008
tony said:
Hello,
I will try another trick - to append the scripts in div
Regards
hm... i wonder if that will work : the issue is with safari (and IE) modifying the DOM properly, but only parsing the newly inserted scripts after doc.ready(). Must likely this will stay problematic even if those script elements are inserted elsewhere. My guess is that this is actually a document.ready() "bug", not a jqGrid bug ! Well, it's not a bug either i guess, just a problem on how browsers handle this.
I think the solution will be somewhere in this direction :
http://docs.jquery.com/Ajax/jQ......getScript
dynamically load jqGrid in document.ready(). Of course, this is ugly since with jquery we're used NOT to have to init plugins
14:44
Moderators
30/10/2007
Maybe a good solution is to add own ready with delay
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
15:10
04/10/2008
tony said:
Maybe a good solution is to add own ready with delay
tony said:
Maybe a good solution is to add own ready with delay
I don't know : i'm not such a good jQuery programmer, although i like ot play around with it a lot : - )
by the way : i forgot to compliment you on jqGrid : I like it A LOT and i'm embedding it in our intranet application. I did 3 days of research on JQuery grid plugins, and jqGrid was the best !
02:46
Moderators
30/10/2007
Hello,
Finally after lot of testing I found a cross browser solutioin.
Here is the piece of code in jqGrid loader:
....
if (minver !== true) filename = pathtojsfiles+modules[i].incfile;
else filename = pathtojsfiles+modules[i].minfile;
if (combineIntoOne !== true) {
if(jQuery.browser.safari || jQuery.browser.msie ) {
jQuery.ajax({url:filename,dataType:'script', async:false, cache: true});
} else {
IncludeJavaScript(filename);
}
} else {
combinedInclude[combinedInclude.length] = filename;
}
................
Note the ajax call and not getScript
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
02:54
Moderators
30/10/2007
Hello,
At end of week I will publish the bug fix release.
There are also a lot of bugs fixed.
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
Most Users Ever Online: 715
Currently Online:
67 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66