Closed Bug 358349 Opened 18 years ago Closed 14 years ago

www.nseindia.com - Sorting functionality provided by the Website does not work in the browser

Categories

(Tech Evangelism Graveyard :: English US, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: vkjain, Unassigned)

References

()

Details

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20061026 SeaMonkey/1.5a Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20061026 SeaMonkey/1.5a The URL http://www.nseindia.com/content/equities/niftywatch.htm gives a list of 50 shares in a table. The header on some of the columns are click-able to enable sorting in an ascending or descending manner. On clicking on any of these headers nothing happens at all. Reproducible: Always Steps to Reproduce: 1.Visit the site www.nseindia.com 2.Click on the link "Nifty Stock-watch" 3.Click on the link "Symbol" or "% Change" or "Total trd qty" or "Turnover (Rs.Lakhs)" Actual Results: I was expecting the columns to get sorted but non of the columns get sorted. Expected Results: Sorting of the entire table based on the column header I clicked on. You can test the site www.nseindia.com with IE. This works pretty well with IE. I have used the plain vanilla browser downloaded from the website with out any additional plugins, themes etc. Machine is a standard Intel 3.0 Ghz procerssor with windows XP SP2 as the OS.
The page is full of IE-only stuff. JS Console picks up Warning: Element referenced by ID/NAME in the global scope. Use W3C standard document.getElementById() instead. Source File: javascript:sortTable(6, ResultSetTable); Line: 1 ResultSetTable is the |name| and |id| of big table, but the page can't just reference it like that. It has to use document.getElementById("ResultSetTable") In http://www.nseindia.com/js/tablesort.js it does: var iCurCell = col + tableToSort.cols; The html sets a |cols| attribute on the table, but it has to use tableToSort.getAttribute("cols") and wrap it in Number() to convert it to an actual number. The same function later does tableToSort.cells(iCurCell).innerText Oof. OK, |cells| is not a propery of a table, |rows| is. So it needs to do tableToSort.cells[i].cells[iCurCell] (note the use of [] instead of ()). And innerText is an IE-ism. It needs to use .childNodes[0].nodeValue. And iCurCell (by design) is greater than the number of columns, so it's referencing a non-existent cell. Anyway, any one of these things would be sufficient to break the functionality. Some good reading for the webmaster http://developer.mozilla.org/en/docs/Using_Web_Standards_in_your_Web_Pages
Assignee: general → english-us
Status: UNCONFIRMED → NEW
Component: General → English US
Ever confirmed: true
OS: Windows XP → All
Product: Mozilla Application Suite → Tech Evangelism
QA Contact: general → english-us
Hardware: PC → All
Summary: Sorting functionality provided by the Website does not work in the browser → www.nseindia.com - Sorting functionality provided by the Website does not work in the browser
INCOMPLETE due to lack of activity since the end of 2009. If someone is willing to investigate the issues raised in this bug to determine whether they still exist, *and* work with the site in question to fix any existing issues, please feel free to re-open and assign to yourself. Sorry for the bugspam; filter on "NO MORE PRE-2010 TE BUGS" to remove.
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → INCOMPLETE
Product: Tech Evangelism → Tech Evangelism Graveyard
You need to log in before you can comment on or make changes to this bug.