• Post Reply Bookmark Topic Watch Topic
  • New Topic

tag value confusion  RSS feed

 
Zeonbong Wong
Greenhorn
Posts: 22
Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am confused about value using in tag attribute,
i know it is okay in HTML weather tag attributes are enclosed in double quotes,
but in jsp if i have a tag like this:

given that i have a servlet setting attribute:

i cant tell weather the value in that tag is an int or String
Any help will be good~
 
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
The instance will be whatever you created. So if you created it as a string, it will be a string. If that's not what the tag expects, then make sure you create what it does expect.
 
Zeonbong Wong
Greenhorn
Posts: 22
Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bear Bibeault wrote:The instance will be whatever you created. So if you created it as a string, it will be a string. If that's not what the tag expects, then make sure you create what it does expect.

so the set method in tag handler for this tag should be like this?

is that correct?
 
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
Did it work when you tried it?
 
Zeonbong Wong
Greenhorn
Posts: 22
Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bear Bibeault wrote:Did it work when you tried it?

it works! thanks buddy
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!