When I am loading a javascript file ,it is giving error :
"Done! But with errors on page""
"Error: XYArray is undefined "... goes on for multiple arrays like this ...
how to solve this??
|
Go4Expert Founder
|
![]() |
| 27Jul2007,09:02 | #2 |
|
It seems you have not defined the Array.
|
|
Team Leader
|
![]() |
| 27Jul2007,09:55 | #3 |
|
Yeah shabbir is right! Please post the code snippet!
|
|
Go4Expert Member
|
|
| 27Jul2007,15:04 | #4 |
|
okay....
Here is the code: inside Lvalues.jsp I am having some n no of Arrays declared like this : <% response.setContentType("application/x-javascript"); response.setHeader("Cache-Control", "no-cache"); response.setHeader("Pramga", "no-cache"); %> var XArray=new Array( "ALL||ALL", "06||06" ,"1N||1N" ,"1X||1X" ,"1Y||1Y" ,"21||21" ,"30||30" } In other jsps I am referring this jsp file... Though named as jsp,since this is a javascript code, i tried sth like this: I replaced <script type="text/javascript" language="Javascript" src="js/LValues.jsp"> with <script type="text/javascript" language="Javascript" src="js/LValues.js"> When I did that, it is producing the error XArray is undefined .... //for all the arrays.. and in the log file, I am getting like this.. 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - 896 copying 4 bytes 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - 897 read class attr -- 'reuse' 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - 898 copying 4 bytes 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - 899 copying 4 bytes 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - 900 read class attr -- '_jspx_th_mbs_005fsecure_005f0' 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - 901 read class attr -- 'Lcom/mbs/security/util/SecurityTag;' 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - 902 read class attr -- 'SourceFile' 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - 903 read class attr -- 'starCycle_jsp.java' 119971 DEBUG [http-8090-Processor25] org.apache.jasper.compiler.SmapUtil$SDEInstaller - SourceDebugExtension not found, installed at: 904 |
|
Team Leader
|
![]() |
| 27Jul2007,15:46 | #5 |
|
Code:
var XArray=new Array( "ALL||ALL", "06||06" ,"1N||1N" ,"1X||1X" ,"1Y||1Y" ,"21||21" ,"30||30" } |
|
Go4Expert Member
|
|
| 27Jul2007,16:07 | #6 |
|
That's typo...The array declaration is fine..
Please tell will these options work??? Just call the files .js instead of .jsp or: remove line feeds. |


