Troubleshooting Ajax Errors For Invalid Characters

As the intranet is a software with its own code, copying content from external sources, such as MS Word, can sometimes cause issues with our code as it tries to insert invalid characters. This can be due to the font used, or special characters that looked fine in Word, but presents a problem when copied over.

To locate problematic or invalid characters, try the following steps:

1) Using Google Chrome (if Chrome is not available, Internet Explorer or Firefox with Firebug should work), open up the dev tools using F12 on your keyboard

2) Select the Network tab

3) Refresh the page encountering the AJAX error that says '200 OK' for the status.

4) Select the 'response' option for the entry showing 200 and review the full code provided here. Usually it will be for a .cfc file (app.cfc or widget.cfc) Provide this data to the support team. See the following image for what this may look like:

Note: in this image, you can see there is a bunch of text displayed which will help locate the invalid character.

Note:  The steps below are advanced.  If you require help, please reach out to the support team.

5) In your browser, open a new tab using

6) Copy and paste the entire response code provided from your dev tools into the jsonlint validator box provided 

7) Click 'Validate' to see where in the data the error is coming from and copy the text, or note down the line number provided:

Note: in using the validator tool, we can see what line the error occurred on, as well as some text to make searching for this invalid character much easier.

8) In a notepad editor, preferably Notepad++ (click here to download Notepad++ from their site, or search in Google for Notepad++), paste the same code into a new notepad and search for the part of the text shown previously in the validation results:

Note: in Notepad++, you can see the line numbers which can help you quickly locate the area where the line is failing by using keys CTRL + G on your keyboard to pull up the search and type in the line number (14337 in the example above) or by doing a normal search (CTRL + F) to search for the text we found in Step 7.

9) Look above the error text for "AssetID": xxxx. In the above example, it is "AssetID":6000

Now that we have the invalid character, as well as its location, we can find it in the database and make this correction.

10) Using SQL Server Management Studio, expand the IntranetConnections database > Tables > look for the 'Asset' table

11) Right-click on the Asset table > click 'select top 1000 rows' > a new query window will open with each column presented in this table. 

As shown in the following example, you can narrow down the results to the item we know is causing the error:


Note: Similar to the previous example, we used AssetID=6000 to demonstrate.

12) Modifying the query, you can add a where statement to target the specific area (eg. where assetid=6000)

13) Click 'execute' or tap the F5 key on your keyboard

14) Locate the invalid character to confirm the problem > click into this field and copy all text into a blank notepad or text editor

15) Remove or replace the invalid character with the correct text

16) Write an update script to correct this issue, for example:

update asset

set title = 'Insert text from your notepad/text editor'

where assetid=xxxx

17) Navigate back to the intranet admin > setup screen > click 'restart' under Intranet Application

18) Browse back to the area of the site where you were seeing this error and check to see if the error has been resolved.

Have more questions? Submit a request


Article is closed for comments.