• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to mark the location list on map  RSS feed

 
Sapumal Bandara
Ranch Hand
Posts: 31
Android Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm trying to mark a list of locations on a map. probem is how to get this list object inside javascript?
this is the JSP



any help is much appreciated.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65833
134
IntelliJ IDE Java jQuery Mac Mac OS X
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Firstly, you should not be using Java code in your JSP. That is a poor practice that has been discredited and obsolete for over 12 years. 12 years! You should deb using the JSTL and EL. See this JspFaq entry.

Secondly, you can use JSTL and EL to create the JavaScript data structures that hold the data. You cannot obtain the data directly between Java in the page, and the JavaScript on the page.

There is also an Ajax alternative, but I don't see any reason to go there there at this point.
 
Sapumal Bandara
Ranch Hand
Posts: 31
Android Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Bear, Thanks for the advice.

But I still couldn't get the locations plotted on the map. JSTL tag library is not identified by JSP. <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> is not identified.

Thanks
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65833
134
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Where did you place the JSTL jar files?
 
Sapumal Bandara
Ranch Hand
Posts: 31
Android Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Bear, Hey resolved it using JSTL. Thanks man. Here goes what I did,

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!