• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

TLD file in HFSJ book(chapter 8)

 
liqiang yang
Ranch Hand
Posts: 92
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I created a TLD file according the book, like this:
-------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>

<taglib xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee/web-jsptaglibrary_2_0.xsd" version="2.0">

<tlib-version>1.2</tlib-version>
<uri>DiceFunctions</uri>
<function>
<name>rollIt</name>
<function-class>foo.DiceRoller</function-class>
<function-signature>
int rollDice()
</function-signature>
</function>
</taglib>
--------------------------------------------------------------------
This file is called myFunctions.tld and under WebContent/WEB-INF

I download and copy the file jstl-1.2.jar to WEB-INF/lib of the WebContent folder.

But I got an error reminder in first line says "Content is not allowed prolog." in IDE. My IDE is eclipse. I have not idea about it?

Can anyone can help? Thanks.
 
Christophe Verré
Sheriff
Pie
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As I said here, do not use JSTL1.2. Use JSTL1.1 instead.
 
Christophe Verré
Sheriff
Pie
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moreover, you should discuss IDE issues in the IDE forum.
 
liqiang yang
Ranch Hand
Posts: 92
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Christophe!
 
liqiang yang
Ranch Hand
Posts: 92
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

Can I make JSTL 1.2 work with Tomcat 6.0 together properly in Eclipse 3.3.1.1 (first two are latest versions now)?
OR I have to use JSTL 1.1 instead of JSTL 1.2.

Is there any samples available to test custom tag using JSTL 1.2 (including setup TLD files) on Eclipse+Tomcat environment?

Thanks in advance!
 
liqiang yang
Ranch Hand
Posts: 92
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Come on guys, pls help me out!!!
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic