Win a copy of Beginning Java 17 Fundamentals: Object-Oriented Programming in Java 17 this week in the Java in General forum!

Hari Maha

Greenhorn
+ Follow
since Oct 13, 2004
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Hari Maha

Can any one explain
1. Why does jboss downloads say to install JBOSS via JEMs Installer to make EJB 3.0 to work on JBOSS4.0.4 ?

Extract from downloads page
---------
Important Note: If you want EJB3 or Seam support with JBoss AS 4.0.3 SP1, 4.0.4 or 4.0.5, you MUST download and use the relevant version of JEMS Installer together with JDK5.0. JBoss AS 4.2.x versions include support for EJB3, by default.
---------

2. Is there any difference if EJB installed manually and JEMs installer?

Thanks
Hari
13 years ago
Sorry , rectified it. I had mistakenly put JSTL 1.0.2 standard and jstl jars which didn't have functions, when replaced with JSTL 1.1, it worked

Thank you
14 years ago
JSP
To get the size of a collection, i used function tld.



But I am getting the following error:


javax.servlet.ServletException: The class org.apache.taglibs.standard.functions.Functions specified in TLD for the function fn:length cannot be found:

14 years ago
JSP
How would I iterate throught the keys (not values) of a property file in JSTL?
14 years ago
JSP
This one works, check if its useful

14 years ago
I have the following script



which i changed as follows in JSTL




When changed to JSTL, it says "layoutList" cannot be resolved, but i am sure it is in request object and works fine for JSP scriplets.
[ May 07, 2007: Message edited by: Hari Maha ]
14 years ago
JSP
Try this

<html:select>

<c:if test=${!empty list1Alt}>
<jsp:attribute name="alt" > ${list1Alt} </jsp:attribute>
</c:if>

<c:if test=${!empty list1Property}>
<jsp:attribute name="property"> ${list1Property} </jsp:attribute>
</c:if>

</html:select>
14 years ago
Yes, It worked. Thanks
So the changed code is as follows.

<%
String contextPath = request.getContextPath();
%>

<fmt:setBundle basename="resources.Themes" var="theme" scope="session"/>
<c:set var="themeId" value="1"/>

<c:choose>
<c:when test="${empty param.themeId}">
<c:set var="themeId" value="1"/>
</c:when>

<c:otherwise>
<c:set var="themeId" value="${param.themeId}"/>
</c:otherwise>
</c:choose>

<c:out value="${param.themeId}"/>
<html>
<head>
<title>Theme</title>
<link rel="stylesheet" type="text/css" href="<%=contextPath%>/css/<fmt:message key="${themeId}" bundle="${theme}"/>">

And I think, I have changed my display name correctly?

And I also want to know, if i can also change
<% String contextPath = request.getContextPath(); %>
to JSTL

Thank You in advance
14 years ago
JSP
Can anyone tell on how to convert this into JSTL

I am using JSP 2.0, JSTL 1.1 and tomcat. The "PropertyFileReader" used here reads a property file and returns a HashMap on calling getProperty().
The logic is just to change the CSS, where by user selects the theme in the previous page.

<%
String contextPath = request.getContextPath();
PropertyFileReader propertyFile = new PropertyFileReader("resources.Themes");

String themeId = "1";
themeId = request.getParameter("themeId");

if (themeId == null || "".equals(themeId))
themeId = "1";

String cssName = (String)(propertyFile.getProperty().get(themeId));

pageContext.setAttribute("cssName",cssName);
%>

<html>
<head>
<title>Theme</title>
<link rel="stylesheet" type="text/css" href="<%=contextPath%>/css/Homepage.css">
<link rel="stylesheet" type="text/css" href="<%=contextPath%>/css/${cssName}">
14 years ago
JSP
Is there any ways to read a Sql server 2000 trace file(.trc) (not sql trace table) from java application? Please help!
I run my appl. in tomcat4.0.3.Strangly, whenever i start my tomcat .tmp files get created in Temp folder of tomcat4.0.3, which occupy whooping 47MB of space.And they don't even get destroyed after shutdown.
17 years ago