views:

24

answers:

1

Hi I'm new to Catalyst, I found server.pl built-in in catalyst module can not parse jqGrid correctly.

Below is error messages: Error: syntax error Source File: http: //xxx:3000/site/static/js/i18n/grid.locale-en.js Line: 2 Source Code: Error: syntax error Source File: http ://localhost:3000/site/static/js/jquery.jqGrid.min.js Line: 2 Source Code:

But it could parse jquery and jquery-UI perfectly. and There is no any problem if I save it as html page(don't parse by Catalyst server.pl)

Any help are appreciated! Thanks.

A: 

This error message isn't from Catalyst, it's from your browser. Catalyst isn't doing any parsing; it's just serving files directly from the static directory. Most likely, there isn't any problem with Catalyst at all and you should check to make sure that the JavaScript file is valid and was placed on the server correctly. If you're 100% sure that's not the problem, you should try downloading http://xxx:3000/site/static/js/i18n/grid.locale-en.js using a tool like wget or curl and compare it to the original, then come back here and update your question with a description of any differences.

hobbs
Thanks! wget is a amazing way to find my fault.
xiaoayfeng