Ranjit Gopinathan

Ranch Hand
+ Follow
since Jul 03, 2007
Merit badge: grant badges
For More
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 Ranjit Gopinathan

Option D is wrong because , when the second constraint tag is removed , the constrained resource can be accessed only by "student" roles , not by both sensei and student roles.


<auth-constraint/> or <auth-constraint></auth-constraint> is an empty tag.

This is not same as "no <auth-constraint> element" which means the absence of the tag.

-HTH
javax/el/ELResolver is inside el-api.jar .

Check if the lib folder of tomcat directory is having this jar.


-HTH

SORRRY!!! Did not check the date before posting!

F is the answer , I think.

When <auth-constraint/> removed , the access is specified only for student roles.
When I executed the example the answer was BBUBUB.

The attribute replacement sequence may be like , new value is Bound and due to that the old value gets Unbound.

This is not an accurate answer to your question. Somebody with more knowledge can throw some light on this.

Edit : Abdul Rahman answered it better. I didnt see his reply when I was replying.
HttpSessionListener would be ideal I think.

HttpSessionAttributeListener may also be helpful in logging .

I doubt how ServletContextListener can be used to log user login. The callback methods for this interface are for initialization and destruction of the context.

Hi Sachin,

Do you have a collection "optionsList" in applicationScope?.

# public void setOptionsList(List optionsList)
# {
# this.optionsList=optionsList;
# }

will set a null to optionsList variable and when you are trying to iterate a null object...You know what you get ...

HTH
I dont think struts will populate a null value.

null don't do anything



Not an answer to your question . Still why cant you change the logic to

if 0 - don't do anything??

or else , check if value is 0 set null to it .
[ March 27, 2008: Message edited by: Ranjit Gopinathan ]
15 years ago
If i understand the logic correctly , the second array list ( inner one ) need to be iterated only once, whatever be its size.Because equal or not equal the flow must exit that inner list.

In that case, instead of the array list, a simple bean can be used right?

Or else write a method in action form which will return the first object of the array List. get that bean and process it.
16 years ago
Please post the code. That way it will be easy for us to find the solution.

And call me Ranjit

Cheers
16 years ago
<logic:iterate name="users" id="usr" scope="session">

<html:link action="/updateuser.do" paramId="user" paramName="usr" paramProperty="userId"><bean:write name="usr" property="userId"/></html:link>
</logic:iterate>

paramName should be "usr" isnt it??.
16 years ago
Assuming that the "continue" is used in conjunction with a comparison

<logic:iterate>
<logic:equal>
This part will only be executed if the condition is true
</logic:equal>
else it will continue.
</logic:iterate>

You may use a logic tag ( equal, notequal, present ..) for the comparison.
Will this serve the purpose??
[ October 25, 2007: Message edited by: Ranjit Gopinathan ]
16 years ago
Please check your Private Messages My Profile
16 years ago
html:text property="" name="" styleId="name"/
html:text property="" phno="" styleId="phno"/
html:text property="" email="" styleId="email"/

For html:text there is no attribute named phno or email.Thatz the reason for the exception.
Refer http://struts.apache.org/1.x/struts-taglib/tlddoc/html/text.html for more info.

The example should be customized according to your requirement than copy pasting it.
16 years ago
For you to do window.opener.document.getElementById("name").value="name"
welcome.jsp needs an html element with id="name"
eg: a <html:text property="" name="" styleId="name"/>

What window.opener.document.getElementById("name").value="name" does is
It pass the value(name) to the window.opener(welcome.jsp here) and assign it to an element with id "name" in welcome.jsp.

I assume that there is no element in welcome.jsp with id="name"

To pass value from addcontact.jsp , try something like this.
In welcome.jsp have a html element ( text or hidden field) with an id "name".
In addcontact.jsp
<html:text property="name" styleId="nameId"/>
In add() function
window.opener.document.getElementById("name").value=
document.getElementById("nameId").value;
16 years ago
Inside the js function add() ,
use window.opener to pass the value back to the welcome page.
16 years ago