Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Invalid property in <set>  RSS feed

 
Raihan Jamal
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I added this line to change the response header in JSP .. I am getting error like this..





And this is the below jsp code where I added that line.



Any suggestions will be appreciated..
 
Paul Clapham
Sheriff
Posts: 22185
38
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That would imply that the "response" object had a method named "setAccess-Control-Allow-Origin()". Obviously this isn't a valid Java method name so it can't be the right thing to do.
 
Raihan Jamal
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Paul Clapham, so what should I do.. what will be the actual line instead of that.. I think m writing some property name wrong.. so that's why I am getting that error..
 
Paul Clapham
Sheriff
Posts: 22185
38
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What should you do? I have no idea. Why don't you start by explaining what that code was supposed to do?
 
Raihan Jamal
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Paul Clapham, I am just trying to change the response header using JSP. As I am accessing URL on different domain and I am working locally.. as I have to get the response back from that server. So that's why I was trying to change the response header. Any idea how can I do this thing..
 
Paul Clapham
Sheriff
Posts: 22185
38
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When you say you want to "change the response header" does that mean you want to set the value of a response header?

I also don't understand this:
As I am accessing URL on different domain and I am working locally.. as I have to get the response back from that server"
It sort of sounds like you expect to send a request to one server and find the response coming back from a different server, but even so you're using your JSP to send the response, so that doesn't seem to apply to anything here.
 
Raihan Jamal
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Paul Clapham, yes that's what I want to do..
 
Paul Clapham
Sheriff
Posts: 22185
38
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry, I was editing my post when you replied. Basically the reason you gave for wanting to set the response header didn't make any sense to me.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!