Avatar of Bob Schneider
Bob Schneider
Flag for United States of America asked on

JQuery Data Table Question

I use data tables to display results of races that we time on a classic asp website (https://www.gopherstateevents.com/results/fitness_events/results.asp?event_type=5&event_id=883&race_id=1516).  This weekend the results of one of our bigger races showed a Data Table error until I figured out that one person's name was incorrectly entered, with a "/" inserted (ie: Johns/on).  There were no issues in the way the results were calculated and displayed everywhere except in our data tables.

Here is my question:  Are there other characters that will prevent JQuery data tables rendering?  Also, should I build some error trapping in to prevent these characters (ie: Replace(FirstName, "/", "").  Seems like a lot of processing for something that is so unlikely to happen?

Thanks in advance.
ASPjQuery

Avatar of undefined
Last Comment
lenamtl

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Chris Stanyon

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
leakim971

I figured out that one person's name was incorrectly entered, with a "/" inserted (ie: Johns/on).  There were no issues in the way the results were calculated and displayed everywhere except in our data tables.

I tried to reproduce without success.
Data is data, until producing invalid JSON, you should not have any issue. For some reason your JSON was not valid and it throw a JavaScript error, it's not about DataTables but about producing valid JSON data.
Bob Schneider

ASKER
Thank you both!
lenamtl

Hi,

I just want to say that if you use Datatables filter or Yadcf filter you may need to select the appropriate settings
for example you can set the value to have HTML or not
You may also need specific ordering  pluging when dealing with date and special characters

So you need to check with all Datatables plugins you are using and often check the broswer console for errors ...
right click / inspect check console tab
You have 3 errors on your page  uncaught SyntaxError: Unexpected token '<'
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck