File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Cross window scripting.

 
Anand Loganathan
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a scenario like this.
I have a JSP Page. In this page I am displaying some symbol. When I click on this symbol, It will go to another site fetch the values in an array format.

It looks like this.
http://www.abc.com/xyz?SYM1,SYM2

The return type is array of objects.

I need to implement this only in Javascript and no server side manipulation is required.

Some body please help me how I would read the array of objects.
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Goto a seperate site. Does that mean another domain that s different than the orginator?

Eric
 
Anand Loganathan
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Eric,

Your assumption is correct.

Say for an example, my domain is http://test.com
and I am getting the value from http://abc.com , doing some manipulation and displaying the value in http://test.com
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Then with my assumption, you are not going to really be able to talk with or manipulate something from another domain since JavaScript has a same domain policy. It is to protect us from sites snooping on other things they do not have rights to.


Now if the site were to return JSON, then you could link to an external js and have it return an object.

Eric
 
Anand Loganathan
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Eric,

Could you example for this one or could you give me link where I can get this detail for implementing external JS.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic