Computing.Net > Forums > Programming > JAVASCRIPT - Please help!!!!

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

JAVASCRIPT - Please help!!!!

Reply to Message Icon

Name: RobMO
Date: October 12, 2001 at 22:02:11 Pacific
Comment:

I work at www.pcmall.com as a junior developer....learning ASP but haven't learned JS yet.

Specifically, I'm looking for a script that is Netscape compatible.

My co-worker can handle JS, but can't get something to work in Netscape (his code is ok in IE 5.5).

What he is doing is for one of our CAP sites (B2B).

Basically, you have a table with x amount of rows and columns (doesn't matter) and you'd like to arrange data within a column only.

Analogy: In MS Excel, say you want to sort a separate column from a to z. You would highlight that column by clicking on the very top of the column and clicking the sort button within one of the drop down menus. You can sort from high to low (a to z) or low to high (z to a) so to speak.

For example, in a column:

1
2
3

Click the button and voila....

3
2
1

That's basically what he wants to do with data in columns in a table.

(you have your table)
(you have 2 buttons below each column)

You click either of those 2 buttons and it arranges data in columns. Mind you, there are 2 buttons under each column of the table (one for sorting up and one for sorting down).

That's it!

Again, he's already done it in IE but it breaks in Netscape. He just took the code from some site and apparently it doesn't support NS.

Just need it to work in NS!

Thanks very much in advance whether you do or do not have time for this.


Robert Morrison
Internet Developer, Marketing Dept.
PC Mall, Inc.
2555 West 190th Street
Torrance, CA 90504
Voice: (310) 354-5600 ext. 4175
www.pcmall.com



Sponsored Link
Ads by Google

Response Number 1
Name: Michael
Date: October 21, 2001 at 01:55:57 Pacific
Reply:

This can be done fairly easily. In JS you can use if statements to check if a object exists on the specified browser. for example:

if (window.history)
{
do the code if you have that object
}

because of the browser wars the DOM (Document object modle is difernt for netscape then IE. if you go to www.webmonkey.com and look in the programing section for a tutorial by Thau for Advanced JavaScript tutorial. there is a section that deals with makeing browser freindly code. I believe it is titled object checking or something like that. Good luck. You should fairly easily be able to make changes to the code.


0
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: JAVASCRIPT - Please help!!!!

PHP - Please help me cause I'm stucked www.computing.net/answers/programming/php-please-help-me-cause-im-stucked/319.html

Please help me with Javasctipt www.computing.net/answers/programming/please-help-me-with-javasctipt/15344.html

Confused - Please help Clerify www.computing.net/answers/programming/confused-please-help-clerify/1199.html