Click here to Skip to main content
11,706,142 members (46,757 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: Javascript
Question 1:
> Dear Sir.
> I have integrated your sorttable.js module in my web application as a
> poor web JavaScript developer beginner :
> Please see the result on the Creative part of my new website :
> or
> or soon (as stupid nationalism requires)
> This site is build from Dreamweaver CS6. On my Internet Explorer 8
> (yet with Windows XP) , when I click on a header column, the content
> is perfectly sorted in ascending or descending order. But with Google
> Chrome or Safari, the sorting does not work ; it is sorted only once
> in descending order. Can you suggest me a way to change your code to
> match the specificities of these damned browsers?
> I thank you in advance,
> Daniel Pisters

Answer to Question I
Your problem, according to the web console in Firefox, is being throws by thiscode:
$(function() {
 items: ".content",
 forcePlaceholderSize: true
I don't know what that code is, I'm afraid; it doesn't seem to have anything to do with my sorttable.js :-)

Question II

Dear Sir,

First, I have to thank you very much for your rapid reactivity.

I put in comment the code you have pointed out as probably guilty and it did not change anything so that I uncommented it.
I have tested your code on IE, Firefox, Google Chrome and Safari. Google Chrome is perceived as a combined, hybrid Opera/Safari probably from legacy upon which this new monster was build;)

Compared to the first (IE), those browsers have different behaviors in catching the click event; that is to say: dean_AddEvent is called twice for the same event so that when the column was sorted, it is sorted again in the reverse order, resulting in a column being always sorted in the same order (descending). Please, see the sequence bellow:

After loading the page:



The sort occurs twice for the same event.

Note however that I have experienced such event redundancy in non web system, event programming such as Oracle Forms 4.5 and so on for Windows.

I repeat that I am only a poor JavaScript beginner. I don't like very much this programming style, though it may be very tricky and elegant at the same time, such as yours. An objet language without class can be understood by the fact it has to deal with the dynamic of web pages, which does not allow referring upstream to static definitions, I suppose, but you are foreseeing as well as me that it will not last very long and that the near future is to be able programming for the web as for a windows application, without seeing much difference. Beside those philosophical considerations, please help me, because your programming level in JavaScript is too high in comparison with mine to allow pretending to debug it and correct it in the right way.

Thank in advance,

Daniel Pisters

This sequence can be traced on my test website:

I thanks you all in advance,

Daniel Pisters
Posted 21-Jan-13 19:54pm
Edited 23-Jan-13 19:28pm

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 196
1 Sergey Alexandrovich Kryukov 151
2 ppolymorphe 61
3 Inimicos 60
4 ProgramFOX 50
0 OriginalGriff 9,050
1 Sergey Alexandrovich Kryukov 8,417
2 CPallini 5,189
3 Maciej Los 4,726
4 Mika Wendelius 3,636

Advertise | Privacy | Mobile
Web01 | 2.8.150819.1 | Last Updated 24 Jan 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100