Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

attribute in Page directives(jsp):confused:

 
mahadevan raja
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When i try to use page directive in my jsp program i get an error called "Attribute page has no value",i have referred the concerned books,used the proper attributes that suit the page directive,still not able to rectify the error.
 
prabhatis
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can u post the exact code and error what u get??
Prabhat kumar
 
prabhatis
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can u post the exact code and error what u get??
Prabhat kumar
 
mahadevan raja
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by prabhatis:
can u post the exact code and error what u get??
Prabhat kumar

the code is as follows
:
<html>
<head>
<title>
Demo of a jsp page
</title>
</head>
<%@ page language="java"%>
<body bgcolor=gray>
<%! char c;%>
<%for(int i=0;i<26;i++)
{
for(int j=0;j<26;j++)
{
c=(char)(0x41 + (26-i+j)%26);
%>
<%=c%>
<%}%>
<br>
<%}%>
</body>
</html>

the error is attribute page has no value
Thanx for the reply
 
prabhat kumar
Ranch Hand
Posts: 114
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
there is no error in ur code ...if u use tomcat3.2
but there is a possible error ..
u just have to mofe the @page directive to the very first line of ur jsp page
like this
<%@ page language="java"%>
<html>
<head>
<title>
Demo of a jsp page
</title>
</head>
<body bgcolor=gray>
<%! char c;%>
<% for(int i=0;i<26;i++)
{
for(int j=0;j<26;j++)
{
c=(char)(0x41 + (26-i+j)%26);
%>
<%=c%>
<%}%>
<br>
<%}%>
</body>
</html>

Prabhat kumar
[This message has been edited by prabhat kumat (edited April 11, 2001).]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic