Re: Wicket 1.5 error : cannot find component id

2012-03-18 Thread kshitiz
Hi,

Thank you for ur reply. I have added the form by writing
*add(registerForm);* in the* constructor*. But I have just resolved by
problem by replacing *wicket:id* in html page with *wickeT:id*

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-1-5-error-cannot-find-component-id-tp4481835p4482073.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Error in dynamic form with any number of drop down ,enu

2012-03-21 Thread kshitiz
Sorry..I missed to add *registerForm.add(organizationList);* in java class.
After adding that with proper getters and setters..I am getting the error:

WicketMessage: No get method defined for class: class domain.UserDomain
expression: organizationList

Root cause:

org.apache.wicket.WicketRuntimeException: No get method defined for class:
class domain.UserDomain expression: organizationList
 at
org.apache.wicket.util.lang.PropertyResolver.getGetAndSetter(PropertyResolver.java:499)
...

What is the reason ... I have added getters and setters...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Error-in-dynamic-form-with-any-number-of-drop-down-enu-tp4492543p4492627.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Error in dynamic form with any number of drop down ,enu

2012-03-21 Thread kshitiz
Hi, what is the relation between userdomain and organizationList as shown in
the error...i have searched my things in internet but I am not able to
understand...the problem is related to dropdownchoice declaration so where
userdomain comes into picture??

Please help me...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Error-in-dynamic-form-with-any-number-of-drop-down-enu-tp4492543p4494681.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Error in dynamic form with any number of drop down ,enu

2012-03-22 Thread kshitiz
Thank you for the linkthe error is gone but now, drop down is not gtting
displayed...what could be the reason...surely organizationList is not
getting populated with dropdownchoice component but why?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Error-in-dynamic-form-with-any-number-of-drop-down-enu-tp4492543p4496153.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: StackOverflowError in session creation

2012-03-30 Thread kshitiz
OhI made a stupid mistakesorry for that and thanks for solving my
problem...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/StackOverflowError-in-session-creation-tp4516170p4521161.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Wicket cookie timeout example?

2012-03-30 Thread kshitiz
Hi,

Is there any way to set cookie expiration time in Wicket? I am not able to
find any example related to that...like we can set session expiration time
in web.xml...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cookie-timeout-example-tp4521200p4521200.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket cookie timeout example?

2012-04-01 Thread kshitiz
Ok...thank you for replying...I wanted to ask one more thing? I am thinking
to add wicket authentication in my app. But as there would be only one type
of user onlyshould I use wicket authentication? I mean this can be
achieved by simple checking session existence also. Will there be any effect
in application performance in terms of speed if I use wicket authentication?
Please suggest me what will be best for me...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cookie-timeout-example-tp4521200p4522929.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket cookie timeout example?

2012-04-01 Thread kshitiz
Okkk.I am learning wicket authorization from 
http://wicket.wordpress.com/2010/01/08/template-for-building-authenticated-webapplication/
http://wicket.wordpress.com/2010/01/08/template-for-building-authenticated-webapplication/
. Here, it is using wicket own signinpanel. If I want to use mine own login
panel, how can I call authenticate method of Session class?? 

I am not able to find good tutorial on wicket authorization? Can u recommend
me one...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cookie-timeout-example-tp4521200p4523121.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket cookie timeout example?

2012-04-01 Thread kshitiz
How to check session's validity? If after logging out we invalidate session,
how to check its validity to avoid any unknown user to access restricted
pages...??

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cookie-timeout-example-tp4521200p4523218.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket cookie timeout example?

2012-04-01 Thread kshitiz
Okk...but as given in my code...why object in not getting stored in 
session??

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cookie-timeout-example-tp4521200p4523322.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket cookie timeout example?

2012-04-01 Thread kshitiz
It turned out that object is getting stored in session but is not getting
retrieved in other page. I have tried to use wicketsessionfilter but it is
not helping...how to access session object in another page..?? The session
object is being retrieved in same page.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cookie-timeout-example-tp4521200p4523463.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket cookie timeout example?

2012-04-01 Thread kshitiz
It worked...thanks :)

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cookie-timeout-example-tp4521200p4523670.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Session existence not working

2012-04-06 Thread kshitiz
Hi,

In my login page, i am trying to check whether user's session is already set
or not by using...

*if(Session.exists())*
{
System.out.println("session exists");
new RestartResponseException(Home.class);
}
else
{
System.out.println("session dont exists");
new RestartResponseException(Login.class);
}

But it is throwing the error:

*Request processing executed 100 steps, which means it is probably in an
infinite loop.*

Now, I have not logged in the application so how come if(Session.exists())
condition is satisfied?? Also, why it is going in infinite loop?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Session-existence-not-working-tp4536914p4536914.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Session existence not working

2012-04-06 Thread kshitiz
I am able to solve my problem by checking whether session object is pointing
to null or not but i am not able to understand why session.exists() is not
able to verify session existence if I am using session.invalidate() during
logout??.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Session-existence-not-working-tp4536914p4536994.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Wicket cannot find id in inner enclosure...but has no problem in outer one!!!

2012-04-15 Thread kshitiz
Hi,

I have two enclosure with one closing another one like this:

*



*


*

*









Here is the java code:

*ListView userTypeDomainListView = new
ListView("userType", userTypeDomainList) 
{ 
*
@Override
protected void populateItem(ListItem item) 
{ 

item.add(new Label("organization", new
PropertyModel(item.getModel(), "organization")));// (4)


int organizationId =
((UserTypeDomain)item.getModelObject()).getOrganizationId();

List postDomainList = null;
postDomainList = 
postService.getPosts(organizationId, unitId, batchId,
locationId, iModel.getObject().getKey());
}

// user posts in each user type
*ListView postDomainListView = new
ListView("post", postDomainList) 
{
*
@Override 
protected void populateItem(ListItem item) 
{
String post =
((PostDomain)item.getModelObject()).getPost();

item.add(new Label("text", post));
}
};
   
postDomainListView.setVisible(!postDomainListView.getList().isEmpty());
add(postDomainListView);

Label noPostLabel = new Label("noPostLabel", "No posts
shared till now...!!!");
noPostLabel.setVisible(!postDomainListView.isVisible());
add(noPostLabel);
}   
};
   
userTypeDomainListView.setVisible(!userTypeDomainListView.getList().isEmpty());
add(userTypeDomainListView);
this.createModelForUserType();

}

Now, when there is no user type, then the code works fine but when there is
a type but no posts are there..i.e. inner enclosure tab is called, then the
error comes:

Root cause:

*org.apache.wicket.WicketRuntimeException: Could not find child with id:
post in the wicket:enclosure*
 at
org.apache.wicket.markup.html.internal.Enclosure.checkChildComponent(Enclosure.java:249)
 at
org.apache.wicket.markup.html.internal.Enclosure.getChildComponent(Enclosure.java:228)
 at
org.apache.wicket.markup.html.internal.Enclosure.onInitialize(Enclosure.java:133)
 at org.apache.wicket.Component.fireInitialize(Component.java:932)


I am not able to understand...is there any syntax mystake. I have read that
it was a bug in earlier versions of wicket but I am using 1.5. Please help
me what is causing this error...?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cannot-find-id-in-inner-enclosure-but-has-no-problem-in-outer-one-tp4559666p4559666.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket cannot find id in inner enclosure...but has no problem in outer one!!!

2012-04-16 Thread kshitiz
Hi, can anyone tell me any other alternative of enclosure if the above
problem cant be bugged out??

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cannot-find-id-in-inner-enclosure-but-has-no-problem-in-outer-one-tp4559666p4562050.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket cannot find id in inner enclosure...but has no problem in outer one!!!

2012-04-17 Thread kshitiz
I have removed inner enclosure and its working fine. I am facing another
problem. This is my code:

ChoiceRenderer choiceRenderer = new
ChoiceRenderer("value", "key");
SelectOption selectedOption = new
SelectOption(selectOption[0].getKey(), "Selected Value");
final IModel iModel = new
PropertyModel(selectedOption.getValue(), "value");
final DropDownChoice postCategoriesDropDown = new
DropDownChoice("postCategories", iModel, Arrays.asList(selectOption),
choiceRenderer);

Select Option is :

public class SelectOption {

private int key;
  private String value;

  public SelectOption(int key, String value) {
this.key = key;
this.value = value;
  }
/ getters and setters
}

Now here, drop down is being rendered in markup..

*

*

But the as given in the code, I want a particular value to come as default
value. But the default one is coming out 'Choose One'. What is the issue??
But


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cannot-find-id-in-inner-enclosure-but-has-no-problem-in-outer-one-tp4559666p4565376.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



RE: Wicket cannot find id in inner enclosure...but has no problem in outer one!!!

2012-04-18 Thread kshitiz
Your guess is rightthank you for the help

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-cannot-find-id-in-inner-enclosure-but-has-no-problem-in-outer-one-tp4559666p4568555.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket dropdownchoice onselectionchanged must override or implement a supertype method

2012-04-26 Thread kshitiz
Thanks all for the reply, You were right...I did the change and it worked.
And also, SelectOption is not wicket one but a class created by me only:


package WalknShine;

import java.io.Serializable;

public class SelectOption implements Serializable{

/**
 * 
 */
private static final long serialVersionUID = 1L;
private int key;
  private String value;

  public SelectOption(int key, String value) {
this.key = key;
this.value = value;
  }
getters and setters...

}


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-dropdownchoice-onselectionchanged-must-override-or-implement-a-supertype-method-tp4584391p4590526.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Passing parameter to a portion of a page

2012-04-30 Thread kshitiz
Thanks for the reply Dan...now consider a situation: 

You have 5 drop downs, each with onselectionchange enabled. When you change
the choice of any one drop down, the chosen value should be passed as
parameter to that drop down only, so that it will display new value. Rest
drop downs should not get changed. How will you do that? 

On way would be to allocate each drop down a unique id and then, associate
each parameter being passed to the same page with that id. This will help to
judge the coming parameter belongs to which drop down. But is there any more
efficient way?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Passing-parameter-to-a-portion-of-a-page-tp4597887p4598758.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Unusual problem is coming in rendering component

2012-05-02 Thread kshitiz
Thank you very much for the repliesI got the problem and solved it using
the code:

*final RequiredTextField postTextField = new
RequiredTextField(
"postTextField", 
Model.of(postDomain.getPost()));
*

But please tell me one thing...the first parameter in new
RequiredTextField() function is used to map textfield tag present in
html page with its java definition. Why wicket is using that parameter to
map it to the property of compound model (PostDomain in this case)???

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Unusual-problem-is-coming-in-rendering-component-tp4604163p4605012.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Unusual problem is coming in rendering component

2012-05-03 Thread kshitiz
I read that out...sorry I missed that while coding. Thanks for the help..:)

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Unusual-problem-is-coming-in-rendering-component-tp4604163p4607651.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket for large user base website

2012-05-06 Thread kshitiz
Okkwicket being statefull stores state of each page in a session. So, if
I make some pages stateless and some statefull,will that improve its memory
efficiency?  

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-for-large-user-base-website-tp4613283p4614133.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket for large user base website

2012-05-07 Thread kshitiz
Thanks all for the reply...actually I haven't looked into the hardware as I
am in middle of application development. Just going through various forums,
people were recommending Wicket for dekstop apps as it is statefull
framework. But as I can see various Wicket websites with high traffic, I
think there is nothing to worry about. Also, memory efficiency can be
achieved by making some pages stateless.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-for-large-user-base-website-tp4613283p4616576.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Need help in implementing Ajax form

2012-05-14 Thread kshitiz
Hi,

I am trying to learn Ajax in Wicket and implement it in my project. I am
trying to use AjaxFallbackButton but there is something I am missing. Here
is my code:

StatelessForm loginForm = new StatelessForm(
"loginForm", new 
CompoundPropertyModel(userDomain));


AjaxFallbackButton ajaxSubmitButton = new AjaxFallbackButton(
"ajaxSubmitButton", loginForm) {

/**
 * 
 */
private static final long serialVersionUID = 1L;

@Override
protected void onSubmit(AjaxRequestTarget target, 
Form form) {

if(target!=null){
UserService userService = new UserService();
try {
userDomain = 
userService.login(emailIdTextField.getValue(),

passwordTextField.getValue());
} catch (Exception exception) {
error(exception.getMessage());
error = true;
}

if (!error) {
setResponsePage(Home.class, 
pageParameters);
}
}
}

@Override
protected void onError(AjaxRequestTarget target, 
Form form) {
// TODO Auto-generated method stub

}
};
loginForm.add(ajaxSubmitButton);
}

Html is 


But when I press Login button, nothing happens...Please help me out here as
I am new to this. Is there any good doc available for this? Also, why WICKET
AJAX DEBUG mark is coming in bottom right corner of my web page?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Need-help-in-implementing-Ajax-form-tp4632760.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Need help in implementing Ajax form

2012-05-16 Thread kshitiz
Thank you very much for the reply...you have solved it...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Need-help-in-implementing-Ajax-form-tp4632760p4642518.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: wicket not able to find component after adding container componenent

2012-05-20 Thread kshitiz
I did...actually this is the code:


public SubmitCommentPanel(String id, final ListItem listItem,
final UserDomain userDomain) {
super(id);

// defining container for refreshing list of posts
*   final WebMarkupContainer postDomainContainer = new 
WebMarkupContainer(
"submitCommentPostDomainContainer");
postDomainContainer.setOutputMarkupId(true);*

List postDomainList = new ArrayList();
postDomainList.add((PostDomain) listItem.getModelObject());

ListView postDomainListView = new 
ListView(
"post", postDomainList) {

private static final long serialVersionUID = 1L;

@Override
protected void populateItem(final ListItem 
listItem1) {

// Defining form for submitting comments for a 
post
Form commentForm = new 
Form(
"commentForm",
new 
CompoundPropertyModel(commentDomain));

commentForm.setModelObject(commentDomain);

// defining text field for user to submit 
comment
final RequiredTextField 
commentTextField = new
RequiredTextField(
"comment", 
Model.of(commentDomain.getComment()));
AjaxFallbackButton ajaxCommentSubmitButton = 
new AjaxFallbackButton(
"commentSubmitButton", 
commentForm) {
/**
 * 
 */
private static final long 
serialVersionUID = 1L;

@Override
public void onSubmit(AjaxRequestTarget 
target,
final Form form) {

/*
 * Populating commentDomain 
instance for submitting
 * comment. This instance is 
then passed to
 * CommentService class
 */

if (target != null) {

try {
CommentService commentService = new 
CommentService();

commentService.addComment(commentDomain);
} catch (Exception 
exception) {

error(exception.getMessage());
}

setResponsePage(getPage().getPageClass());

target.add(postDomainContainer);
}
}

@Override
protected void 
onError(AjaxRequestTarget target,
Form form) {
// TODO Auto-generated method 
stub

}


};

commentForm.add(commentTextField);
commentForm.add(ajaxCommentSubmitButton);

*listItem.add(commentForm);*
}
};


*postDomainContainer.add(postDomainListView);
add(postDomainContainer);*

}


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-not-able-to-find-component-after-adding-container-componenent-tp4646756p4647052.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: wicket not able to find component after adding container componenent

2012-05-20 Thread kshitiz
I solved my problem...found other way around to get my purpose...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-not-able-to-find-component-after-adding-container-componenent-tp4646756p4647093.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Problem in adding user confirmation feature by wicket way...

2012-05-27 Thread kshitiz
I removed the error by modifying the code:


protected void onConfirm() {

PostService postService = new PostService();

int postId = ((PostDomain) listItem

.getModelObject())

.getPostId();

try {

postService

.deletePost(postId);

*setResponsePage(getPage().getPageClass());* // added 
here

} catch (Exception exception) {

error(exception.getMessage());

}

this.replaceWith(ShowPostPanel.this);

}

Now the error is:

*org.apache.wicket.request.handler.ComponentNotFoundException: Could not
find component
'userTypePanel:userType:0:showPostPanel:postDomainListContainer:post:0:postForm:postDeleteButton'
on page 'class WalknShine.Home.Home
* at
org.apache.wicket.request.handler.PageAndComponentProvider.getComponent(PageAndComponentProvider.java:181)
 at
org.apache.wicket.request.handler.ListenerInterfaceRequestHandler.getComponent(ListenerInterfaceRequestHandler.java:92)
 at
org.apache.wicket.request.handler.ListenerInterfaceRequestHandler.respond(ListenerInterfaceRequestHandler.java:239)
 at
org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:781)
 at
org.apache.wicket.request.RequestHandlerStack.execute(RequestHandlerStack.java:64)

ShowPostPanel is present inside UserTypePanel. Why it is searching  that as
I have given ShowPostPanel to be replaced??

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Problem-in-adding-user-confirmation-feature-by-wicket-way-tp4649510p4649512.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Problem in adding user confirmation feature by wicket way...

2012-05-28 Thread kshitiz
Please help me out here...I dont want to use javascript to get user
confirmation...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Problem-in-adding-user-confirmation-feature-by-wicket-way-tp4649510p4649523.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Refresh listItem only of listView

2012-06-02 Thread kshitiz
Hi,

I have a scenario like this:

ListView userTypeDomainListView = new
ListView(
"userType", userTypeDomainList) {

protected void populateItem(final 
ListItem listItem) {

listItem.add(new 
SubmitPostPanel("submitPostPanel",
pageParameters, listItem, 
userDomain));

} 
}

In SubmitPostPanel, I have a ajax button for submitting post. What I want is
to refresh that listItem only which is passed in the Panel after submitting
post. I have tried out:

*listItem.setOutputMarkupId(true);*
*listItem.setOutputMarkupPlaceholderTag(true);*
AjaxFallbackButton ajaxPostSubmitButton = new AjaxFallbackButton(
"postSubmitButton", postForm) {

@Override
public void onSubmit(AjaxRequestTarget target, final 
Form form) {
*target.add(listItem);*
}

But the item is not getting refreshed. How can I achieve my purpose?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Refresh-listItem-only-of-listView-tp4649676.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Refresh listItem only of listView

2012-06-02 Thread kshitiz
Hi,

Yes...actually userTypeDomainList is a list of domain objects. I am creating
view from this list, where each item of the view has saveral components.
Now, on updating a component, i want to update its respective item, rather
than whole listview. Do I need to put that item in a container to refresh
it?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Refresh-listItem-only-of-listView-tp4649676p4649678.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Refresh listItem only of listView

2012-06-03 Thread kshitiz
okk..so if ajaxbutton is part of every item of a listview, how can I refresh
that view by pressing that button.I am asking because you will not able to
add that listview as target in the button as it would not be completely
defined by then.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Refresh-listItem-only-of-listView-tp4649676p4649683.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



any way to refresh listview from inside?

2012-06-03 Thread kshitiz
Hi,

Is there any way to refresh listview from inside? Like if every of its item
has ajaxlink or ajaxbutton, can the whole view be refreshed from that ajax
button? I am not able to find any way in internet regarding this issue...


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/any-way-to-refresh-listview-from-inside-tp4649684.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: any way to refresh listview from inside?

2012-06-03 Thread kshitiz
Thnx...that did it...:)

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/any-way-to-refresh-listview-from-inside-tp4649684p4649687.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



A good example of numeric based page navigation...

2012-06-03 Thread kshitiz
Hi,

Can anyone give me a a link for learning google like pagination in wicket. I
am not able to find one. All I see is to add PageNavigator in java class.
But how to modify html markup page?


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/A-good-example-of-numeric-based-page-navigation-tp4649692.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Refresh listItem only of listView

2012-06-03 Thread kshitiz
Yes...u r rightit is working in the same manner only...:)

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Refresh-listItem-only-of-listView-tp4649676p4649694.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Back button is troubling session management...

2012-06-09 Thread kshitiz
Hi,

After I log in that application, I am not suppose to see login page of the
app when I press back button. Though I am not able to go to login url as I
am checking user session in login page and redirects him to home page if the
session is present. But, when back button is pressed, that logic is skipped
and login pageis displayed. How to handle this issue? How can I reload login
page after pressing back button?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Back-button-is-troubling-session-management-tp4649793.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Ajax refresh not working in a case .... while working in similar other cases!!!

2012-06-09 Thread kshitiz
Hi,

I am trying to refresh ajax container after firing an event. The code is:

*final WebMarkupContainer searchContainer = new WebMarkupContainer(
"searchContainer");
searchContainer.setOutputMarkupId(true);*


AjaxFallbackButton ajaxSearchButton = new AjaxFallbackButton(
"searchButton", searchForm) {

@Override
public void onSubmit(AjaxRequestTarget target, final 
Form form) {
if (target != null) {

try {
 // some actions...
} catch (Exception exception) {
}
*target.add(searchContainer);*
}
}
}


Label userLabel = new Label("userLabel", "List of Users");
Label numberOfUserLabel = new Label("numberOfUserLabel", new 
Integer(
numberOfUsers).toString());

final PageableListView userDomainListView = new
PageableListView(
"user", userDomainList, resultsPerPage) {
private static final long serialVersionUID = 1L;

@Override
protected void populateItem(final ListItem 
listItem) {
// populating list
}

};

*   userDomainListView.setVisible(!userDomainList.isEmpty());
userLabel.setVisible(!userDomainList.isEmpty());
numberOfUserLabel.setVisible(!userDomainList.isEmpty());

searchContainer.add(userLabel);
searchContainer.add(userDomainListView);
searchContainer.add(numberOfUserLabel);
*

But the list view is not getting refreshed? I am using the same technique in
other pages and it is working.. what be the reason..?? Any suggestion can
work for me...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-not-working-in-a-case-while-working-in-similar-other-cases-tp4649794.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



setHeaders not working in 1.5

2012-06-09 Thread kshitiz
Hi,

I want to remove login page from browser cache after user logs in. I am
using the code :

protected void setHeaders(WebResponse response) {

*response.setHeader("Pragma", "no-cache");
response.setHeader("Expires", "0");
response.setHeader("Cache-Control",
"no-cache, max-age=0, must-revalidate, 
no-store");*
}

But it is not working. *Even I have tried the changes given in *

https://cwiki.apache.org/WICKET/caching-in-wicket-15.html
*https://cwiki.apache.org/WICKET/caching-in-wicket-15.html* 

What I am missing??

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/setHeaders-not-working-in-1-5-tp4649796.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Ajax refresh not working in a case .... while working in similar other cases!!!

2012-06-09 Thread kshitiz
I have never tried out that beforeI have enabled debug mode but I to
debug the ajax part? Can you please tell me ??

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-not-working-in-a-case-while-working-in-similar-other-cases-tp4649794p4649797.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Ajax refresh not working in a case .... while working in similar other cases!!!

2012-06-09 Thread kshitiz
I got the problem atleast...what is happening that it is using the same
search object (where results are being stored and then displayed in
container) and not creating the new one for new searches. Actually what I
want is when user searches anything, the results are refreshed only. I am
storing the results in an object and displaying them using listview which is
again a part of container. Can you suggest me anything out here?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-not-working-in-a-case-while-working-in-similar-other-cases-tp4649794p4649799.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Ajax refresh not working in a case .... while working in similar other cases!!!

2012-06-09 Thread kshitiz
Okk...actually when I analysed more, what  I found is that when I enter new
value in text field, the event takes the old value only. Even I am now
refreshing the form too. Then I found that the field sets its value to old
one after getting refreshed. My field is of final  type. But that should not
be the problem as I am using the same technique in other pages too...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-not-working-in-a-case-while-working-in-similar-other-cases-tp4649794p4649802.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Back button is troubling session management...

2012-06-09 Thread kshitiz
Hi, 

My code to check user session is:


if (UserSession.get().checkUserSession()) {
// redirecting user to home page
setResponsePage(Home.class, new 
PageParameters());
}

*   UserSession is*

public class UserSession extends WebSession {

/**
 * 
 */
private static final long serialVersionUID = 1L;

public UserSession(Request request) {
super(request);
// TODO Auto-generated constructor stub
}

private Object myObject;

// if you use java >= 1.5 you can make use of covariant return types
public static UserSession get() {
return (UserSession)Session.get();
}


public boolean checkUserSession()
{
if(myObject==null) return false;
else return true;
}

public void logout()
{
get().invalidate();
myObject = null;
}


public Object getMyObject() {
return myObject;
}


public void setMyObject(Object myObject) {
this.myObject = myObject;
}





}


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Re-Back-button-is-troubling-session-management-tp4649801p4649804.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Back button is troubling session management...

2012-06-09 Thread kshitiz
I used the same logic in onBeforeRender and it is working...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Re-Back-button-is-troubling-session-management-tp4649801p4649805.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Ajax refresh not working in a case .... while working in similar other cases!!!

2012-06-09 Thread kshitiz
I am able to solve this field related problem...just container is not getting
refreshed...

here is the code, I have modified a bit as per requirement:

public Search(String id) {

searchContainer.add(searchForm);
searchContainer.add(new SearchResultPanel("searchResultPanel",
searchDomain, error, searchContainer));
add(searchContainer);
}

public SearchResultPanel(String id, SearchDomain searchDomain, final
WebMarkupContainer searchContainer) {
super(id);

List userDomainList = new ArrayList();
List organizationDomainList = new
ArrayList();

userDomainList = searchDomain.getUserDomainList();

organizationDomainList = 
searchDomain.getOrganizationDomainList();

int numberOfUsers = searchDomain.getNumberOfUsers();

Label userLabel = new Label("userLabel", "List of Users");
Label numberOfUserLabel = new Label("numberOfUserLabel", new 
Integer(
numberOfUsers).toString());

final PageableListView userDomainListView = new
PageableListView(
"user", userDomainList, resultsPerPage) {
private static final long serialVersionUID = 1L;

@Override
protected void populateItem(final ListItem 
listItem) {

String name = ((UserDomain) 
listItem.getModelObject())
.getName();
Label userName = new Label("userName", name);
listItem.add(userName);
}

};

userDomainListView.setVisible(!userDomainList.isEmpty());
userLabel.setVisible(!userDomainList.isEmpty());
numberOfUserLabel.setVisible(!userDomainList.isEmpty());

add(userLabel);
add(userDomainListView);
add(numberOfUserLabel);

int numberOfOrganization = 
searchDomain.getNumberOfOrganizations();

Label organizationLabel = new Label("organizationLabel",
"List of Organizations");
Label numberOfOrganizationLabel = new Label(
"numberOfOrganizationLabel",
new Integer(numberOfOrganization).toString());

final ListView organizationDomainListView = 
new
ListView(
"organization", organizationDomainList) {
private static final long serialVersionUID = 1L;

@Override
protected void populateItem(
final ListItem 
listItem) {

String organization = ((OrganizationDomain) 
listItem

.getModelObject()).getOrganization();
Label organizationName = new 
Label("organizationName",
organization);
listItem.add(organizationName);
}

};

organizationDomainListView
.setVisible(!organizationDomainList.isEmpty());
organizationLabel.setVisible(!organizationDomainList.isEmpty());

numberOfOrganizationLabel.setVisible(!organizationDomainList.isEmpty());

add(organizationLabel);
add(organizationDomainListView);
add(numberOfOrganizationLabel);

add(new AjaxPagingNavigator("navigator",
userDomainListView) {

/**
 * 
 */
private static final long serialVersionUID = 1L;

@Override
protected void onAjaxEvent(AjaxRequestTarget target) {
target.addComponent(searchContainer);
}
});
}

}



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-not-working-in-a-case-while-working-in-similar-other-cases-tp4649794p4649806.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Panel not getting refreshed...

2012-06-09 Thread kshitiz
Did u mean this:


final SearchResultPanel searchResultPanel = new
SearchResultPanel("searchResultPanel",
searchDomain, error, searchContainer);
*   searchResultPanel.setOutputMarkupId(true);*



AjaxFallbackButton ajaxSearchButton = new AjaxFallbackButton(
"searchButton", searchForm) {
/*
 * 
 */
private static final long serialVersionUID = 1L;

@Override
public void onSubmit(AjaxRequestTarget target, final 
Form form) {

/*
 * Populating postDomain instance for 
submitting post. This
 * instance is then passed to PostService class
 */
if (target != null) {

try {
*   target.add(searchFeedbackPanel);
target.add(searchResultPanel);*
} catch (Exception exception) {
error(exception.getMessage());
error = true;
}

}
}

};

Actually the above change is also not working..:(


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Panel-not-getting-refreshed-tp4649807p4649810.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Panel not getting refreshed...

2012-06-10 Thread kshitiz
I have tried that out...*no luck till now...:(*

Just for the info..what I am doing is that a search form is there which is
populating result in domain object. I am passing that object in
searchResultPanel to get displayed. Now, *form and panel...both are part of
a container.* I want to refresh that panel only when users submits for
search. I am not able to understand what can be the issue. *Feedback panel
is getting refreshed properly in case of no search found but result panel is
not getting refreshed. It is not even entering in that panel as I have some
sysouts in that panel to check...*

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Panel-not-getting-refreshed-tp4649807p4649818.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Building wicket-stuff

2012-06-10 Thread kshitiz
Do you mean creating wicket maven project ? If that is the case, please refer
to this link:

https://cwiki.apache.org/WICKET/windows-guide-to-installing-wicket-on-eclipse-with-maven.html
https://cwiki.apache.org/WICKET/windows-guide-to-installing-wicket-on-eclipse-with-maven.html
 

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Building-wicket-stuff-tp4649812p4649820.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Panel not getting refreshed...

2012-06-10 Thread kshitiz
*u are right...it is entering onBeforeRender method but it is not going in
the panel portion. As far as debug part is concern...I dont see any error:*

INFO: 

INFO: Response parsed. Now invoking steps...
INFO: Response processed successfully.
INFO: Invoking post-call handler(s)...
INFO: refocus last focused component not needed/allowed


*Do you see any error..?*

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Panel-not-getting-refreshed-tp4649807p4649836.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Panel not getting refreshed...

2012-06-10 Thread kshitiz
Hi,

I have removed almost everything...resultPanel contains only sysout:

public class SearchResultPanel extends BasePanel {

private static int temp = 0;

@Override
protected void onBeforeRender() {
super.onBeforeRender();
System.out.println("I am here.");
}
*   public SearchResultPanel(String id) {
super(id);
System.out.println("temp is " + temp);
temp++;
*}

*And there is no container now. Search page where result panel is :*


public Search(final PageParameters pageParameters) {

super(pageParameters);

Form searchForm = new 
Form("searchForm",
new 
CompoundPropertyModel(searchDomain));

final Panel searchFeedbackPanel = new FeedbackPanel(
"searchFeedbackPanel");
searchFeedbackPanel.setOutputMarkupId(true);
searchFeedbackPanel.setOutputMarkupPlaceholderTag(true);

*   final SearchResultPanel searchResultPanel = new 
SearchResultPanel(
"searchResultPanel");
searchResultPanel.setOutputMarkupId(true);
searchResultPanel.setOutputMarkupPlaceholderTag(true);
*
searchForm.setModelObject(searchDomain);

// defining text field for user to search
final RequiredTextField searchTextField = new
RequiredTextField(
"search", Model.of(searchDomain.getSearch()));

AjaxFallbackButton ajaxSearchButton = new AjaxFallbackButton(
"searchButton", searchForm) {

@Override
public void onSubmit(AjaxRequestTarget target, final 
Form form) {

if (target != null) {

try {
   
target.add(searchResultPanel);
target.add(searchFeedbackPanel);
} catch (Exception exception) {
error(exception.getMessage());
error = true;
}


}
}


};

searchForm.add(searchTextField);
*   searchForm.add(searchFeedbackPanel);
searchForm.add(searchResultPanel);
*   searchForm.add(ajaxSearchButton);


add(searchForm);

}

*Actually what is happening, when I refresh the whole page manually, it
enters the resultPanel and temp value is displayed in console. But nothing
happens when that panel is refreshed...!!*



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Panel-not-getting-refreshed-tp4649807p4649838.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Panel not getting refreshed...

2012-06-11 Thread kshitiz
Please help me I am really not able to understand why it is
happeningThe form is really simple now:


public Search(final PageParameters pageParameters) {

super(pageParameters);

Form searchForm = new 
Form("searchForm",
new 
CompoundPropertyModel(searchDomain));

*   final SearchResultPanel searchResultPanel = new 
SearchResultPanel(
"searchResultPanel", searchDomain);
searchResultPanel.setOutputMarkupId(true);
searchResultPanel.setOutputMarkupPlaceholderTag(true);
*
searchForm.setModelObject(searchDomain);

// defining text field for user to search
final RequiredTextField searchTextField = new
RequiredTextField(
"search", Model.of(searchDomain.getSearch()));

AjaxFallbackButton ajaxSearchButton = new AjaxFallbackButton(
"searchButton", searchForm) {

@Override
public void onSubmit(AjaxRequestTarget target, final 
Form form) {
if (target != null) {

try {
*   target.add(searchResultPanel);*

} catch (Exception exception) {
error(exception.getMessage());
}


}
}

};

*   searchForm.add(searchTextField);
searchForm.add(searchResultPanel);
searchForm.add(ajaxSearchButton);
add(searchForm);
*   }

And SearchResultPanel is:


*public SearchResultPanel(String id, final SearchDomain searchDomain) {
super(id);
Label label = new Label("temp", new 
LoadableDetachableModel() { @Override
protected Object load() { return 
searchDomain.getSearch(); }}); 
add(label);
}
*

/But still, resultPanel is not displaying search text after being
refreshed..that is the panel is not getting refreshed...!!! In every example
I have seen in forums, it is done in the same manner...then why it is not
happening..!!!  I am using wicket 1.5...
/

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Panel-not-getting-refreshed-tp4649807p4649857.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Panel not getting refreshed...

2012-06-11 Thread kshitiz
This is the new code now:

public class Search extends WebPage {

public Search(final PageParameters pageParameters) {
super(pageParameters);

final SearchDomain searchDomain = new SearchDomain();
*Form searchForm = new Form("searchForm",
new 
Model(searchDomain));
*

final SearchResultPanel searchResultPanel = new 
SearchResultPanel(
"searchResultPanel", 
*(Model)searchForm.getModel()*, true);
searchResultPanel.setOutputMarkupId(true);

final RequiredTextField searchTextField = new
RequiredTextField(
"search", *new 
PropertyModel(searchDomain, "search")*);


AjaxFallbackButton ajaxSearchButton = new AjaxFallbackButton(
"searchButton", searchForm) {
@Override
public void onSubmit(AjaxRequestTarget target, final 
Form form) {

if (target != null) {

try {
target.add(searchResultPanel);

} catch (Exception exception) {
error(exception.getMessage());
error = true;
}


}
}

searchForm.add(searchTextField);
searchForm.add(searchResultPanel);
searchForm.add(ajaxSearchButton);

add(searchForm);
}

And resulTPanel is:

public SearchResultPanel(String id, final Model model,
final boolean error) {
super(id);
System.out.println("temp is " + temp);
*   Label label = new Label("temp", new 
PropertyModel(model.getObject(), "search")); 
*   temp++;
add(label);
}



My SearchDomain is:


public class SearchDomain implements Serializable {

/**
 * 
 */
private static final long serialVersionUID = 1L;
private String search;

public String getSearch() {
return search;
}

public void setSearch(String search) {
this.search = search;
}
}

I am going to search page directly. Now again the problem is there...even
sysout is not getting printed which is inside the result panel. What can be
the other issues?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Panel-not-getting-refreshed-tp4649807p4649865.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Panel not getting refreshed...

2012-06-12 Thread kshitiz
It is working   Thank you very much for your continuous help

As I compared mine with urs...what I was doing wrong in initializing
resultPanel...Instead of :

final SearchResultPanel searchResultPanel = new SearchResultPanel(
"searchResultPanel", *searchForm.getModel()*, 
true);

*I was passing searchDomain instance directly in the panel constructor...*

Thank you ..:)

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Panel-not-getting-refreshed-tp4649807p4649879.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Wicket panel not getting refreshed completely

2012-06-21 Thread kshitiz
Hi,

I have a panel with ajax button (i.e. form) inside it. When I submit the
form, not all of the components of that panel are being refreshed. Here is
the code:


public ShowCommentPanel(final String id,
final List commentDomainList,
final UserDomain userDomain) {
super(id);

*   this.setOutputMarkupId(true);*

*   // not getting refreshed
*   Label numberOfCommentLabel = new Label("numberOfCommentLabel",
"Number of comments "
+ 
Integer.toString(commentDomainList.size()));

*// getting refreshed*
final PageableListView commentDomainListView = 
new
PageableListView(
"commentList", commentDomainList, 
commentsPerPage) {

@Override
protected void populateItem(final 
ListItem listItem) {

Form showCommentForm = new 
Form(
"showCommentForm",
new 
CompoundPropertyModel(commentDomain));

showCommentForm.setModelObject(commentDomain);

final CommentDomain commentDomain = 
((CommentDomain) listItem
.getModelObject());
String comment = ((CommentDomain) 
listItem.getModelObject())
.getComment();
Label commentLabel = new Label("commentLabel", 
comment);

AjaxFallbackButton ajaxCommentDeleteButton = 
new AjaxFallbackButton(
"commentDeleteButton", 
showCommentForm) {

private static final long 
serialVersionUID = 1L;

@Override
public void onSubmit(AjaxRequestTarget 
target,
final Form form) {

if (target != null) {
CommentService 
commentService = new CommentService();
try {

commentService.deleteComment(commentDomain);

commentDomainList.remove(commentDomain);
} catch (Exception 
exception) {

exception.printStackTrace();

error(exception.getMessage());
}
*   
target.add(ShowCommentPanel.this);*
}
}

};

if (commentDomain.getUserDomain().getUserId() 
!= userDomain
.getUserId()) {

ajaxCommentDeleteButton.setVisible(false);
}
showCommentForm.add(commentLabel);
showCommentForm.add(ajaxCommentDeleteButton);

listItem.add(showCommentForm);
}
};

commentDomainListView.setVisible(!commentDomainList.isEmpty());

*// not getting refreshed*
AjaxPagingNavigator ajaxPagingNavigator = new 
AjaxPagingNavigator(
"commentNavigator", commentDomainListView);
ajaxPagingNavigator.setVisible(!commentDomainList.isEmpty());

*   add(commentDomainListView); // getting refreshed
add(ajaxPagingNavigator); // not getting refreshed
add(numberOfCommentLabel); // not getting refreshed  *
}


/What can be the problem??/

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-panel-not-getting-refreshed-completely-tp4650150.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket panel not getting refreshed completely

2012-06-21 Thread kshitiz
Hi,

I have tried out this:

*Integer numberOfComments = commentDomainList.size();
Label numberOfCommentLabel = new Label("numberOfCommentLabel",
new Model(numberOfComments));*

But again nothing happens..I think the above statement is right...what do
you suggest?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-panel-not-getting-refreshed-completely-tp4650150p4650162.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket panel not getting refreshed completely

2012-06-21 Thread kshitiz
Solved itactually I have to use property model and in that I have to use
a domain model carrying a property  for showing number of comments...

*Label numberOfCommentLabel = new Label("numberOfCommentLabel",
new PropertyModel(postDomain, 
"numberOfComments"));*

Thank you very much everyone for helping me:)

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-panel-not-getting-refreshed-completely-tp4650150p4650166.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Ajax refresh component with initial setVisible(false)

2012-06-21 Thread kshitiz
Hi,

How to ajax refresh components which are initially setvisible to false but
later set to true. I know when it is false, then its mark up is not created
in DOM. I have tried like

**ajaxPagingNavigator.setOutputMarkupPlaceholderTag(true);**

here, ajaxPagingNavigator is component. *But it is not appearing but its
visibility becomes true.* What is the solution?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-component-with-initial-setVisible-false-tp4650171.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Ajax refresh component with initial setVisible(false)

2012-06-21 Thread kshitiz
Hi,

I have added the whole panel in which that navigator is present. 

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-component-with-initial-setVisible-false-tp4650171p4650180.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Ajax refresh component with initial setVisible(false)

2012-06-22 Thread kshitiz
This is my submitCommentPanel:


public SubmitCommentPanel(String id, final PostDomain postDomain,
final UserDomain userDomain) {

super(id);

this.setOutputMarkupId(true);

AjaxFallbackButton ajaxCommentSubmitButton = new AjaxFallbackButton(
"commentSubmitButton", commentForm) {
/**
 * 
 */
private static final long serialVersionUID = 1L;

@Override
public void onSubmit(AjaxRequestTarget target, final 
Form form) {

/*
 * Populating commentDomain instance for 
submitting comment.
 * This instance is then passed to 
CommentService class
 */

if (target != null) {

try {
// some processing

} catch (Exception exception) {
error(exception.getMessage());
}
target.add(submitCommentFeedbackPanel);
*target.add(SubmitCommentPanel.this);*
}
}
};


* here, I am adding one more panel which should not be visible in a
situation ...
ShowCommentPanel showCommentPanel = new ShowCommentPanel(
"showCommentPanel", postDomain, userDomain);

showCommentPanel.setVisible(!postDomain.getCommentDomainList().isEmpty());
add(showCommentPanel);*
}
Now ShowCommentPanel is:


public ShowCommentPanel(final String id,
final PostDomain postDomain,
final UserDomain userDomain) {
super(id);
// TODO Auto-generated constructor stub


*   @SuppressWarnings("rawtypes")
Label numberOfCommentLabel = new Label("numberOfCommentLabel",
new PropertyModel(postDomain, 
"numberOfComments"));
add(numberOfCommentLabel);*
}

Now what is happening that when showCommentPanel visibility is initially
false but later becomes true after ajax refresh, even then
*numberOfCommentLabel * does not appear. I have to refresh the whole page to
make them appear. After that they refresh properly by ajax.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-component-with-initial-setVisible-false-tp4650171p4650196.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Ajax refresh component with initial setVisible(false)

2012-06-23 Thread kshitiz
Please help me out hereis there any silly mistake that I am making?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Ajax-refresh-component-with-initial-setVisible-false-tp4650171p4650205.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
Hi,

In my wicket application, each page carries many panels. *Now every panel is
rendered when the page is loaded but when it is refreshed, nothing happens.
* No panel is getting rendered again, not even sysouts are printing
anything. *Now this is a good thing for performance but I want them to be
re-rendered.Is there any way to make it happen...??*

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Components-do-not-re-render-when-page-is-refreshed-tp4650290.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
Hi,

Like this is one page:


public UserHome(final PageParameters pageParameters, UserDomain userDomain)
{
super(pageParameters, userDomain);
if (userDomain == null)
userDomain = getUserById(this.userId);

add(new SearchPanel("searchPanel"));

// user name to appear in required pages
*   Label nameLabel = new Label("name", userDomain.getName());
add(nameLabel);
*
*system.out.println("This should be printed every time");*

}

Now, when the page loads the first time, *This should be printed every time*
is printed. That means, contructor is called. But when the page is
refreshed, nothing is printed. To give you more details, suppose this is the
url of the page:

/http://localhost:8080/Page?32/

When, I just refresh the whole url, nothings happens but when I remove
parameters of the url(/http://localhost:8080/Page/, rendering happens
again. Why is this happening?



scott.swank wrote
> 
> How do you construct your panels? This sounds like a model issue...
> 
> Scott
> 
> On Fri, Jun 29, 2012 at 9:02 AM, kshitiz <k.agarwal4@> wrote:
>> Hi,
>>
>> In my wicket application, each page carries many panels. *Now every panel
>> is
>> rendered when the page is loaded but when it is refreshed, nothing
>> happens.
>> * No panel is getting rendered again, not even sysouts are printing
>> anything. *Now this is a good thing for performance but I want them to be
>> re-rendered.Is there any way to make it happen...??*
>>
>> --
>> View this message in context:
>> http://apache-wicket.1842946.n4.nabble.com/Components-do-not-re-render-when-page-is-refreshed-tp4650290.html
>> Sent from the Users forum mailing list archive at Nabble.com.
>>
>> -
>> To unsubscribe, e-mail: users-unsubscribe@.apache
>> For additional commands, e-mail: users-help@.apache
>>
> 
> -
> To unsubscribe, e-mail: users-unsubscribe@.apache
> For additional commands, e-mail: users-help@.apache
> 

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Components-do-not-re-render-when-page-is-refreshed-tp4650290p4650292.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
Hi,

Thanks for the reply. Just to clarify, like if I am adding a panel:

*add(new PostPanel("postPanel", pageParameters, userTypeDomain,
userDomain));*

So, how do I make it render at every page refresh...?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Components-do-not-re-render-when-page-is-refreshed-tp4650290p4650294.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
Actually in that post panel, I am taking data from the database and
displaying it as listview. Now, when I manually enter a new entry in the
database and then refresh page, the new entry is not getting displayed. This
simple means that the given panel is not picking up the data from the
database at every refresh or in other words, methods are not being called of
that panel. 


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Components-do-not-re-render-when-page-is-refreshed-tp4650290p4650297.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
I am using list only like this:


PageableListView postDomainListView = new
PageableListView(
"postList", *postDomainList*, postsPerPage) {
// .

}

How am I suppose to use IModel for list? It is giving errors over here...


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Components-do-not-re-render-when-page-is-refreshed-tp4650290p4650299.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Components do not re-render when page is refreshed...

2012-06-30 Thread kshitiz
Actually I am using listview because I do want to query database every time I
change page of pageable listview. How would I use IModel in
pageableListview?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Components-do-not-re-render-when-page-is-refreshed-tp4650290p4650303.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Components do not re-render when page is refreshed...

2012-06-30 Thread kshitiz
Ok..thanks for helping me out Dan...:)

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Components-do-not-re-render-when-page-is-refreshed-tp4650290p4650311.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



setOutputMarkupPlaceholderTag not working to render panel with setvisible false...

2012-07-01 Thread kshitiz
Hi,

I am using a panel with setVisible false on a condition. But it is not
getting rendered when its visibility becomes true. Here is  the code :

*final ShowCommentPanel showCommentPanel = new ShowCommentPanel(
"showCommentPanel", postDomain, userDomain, 3);
showCommentPanel.setOutputMarkupPlaceholderTag(true);
showCommentPanel.setVisible(!commentDomainList().isEmpty());
*   

AjaxFallbackButton ajaxCommentSubmitButton = new AjaxFallbackButton(
"commentSubmitButton", commentForm) {

@Override
public void onSubmit(AjaxRequestTarget target, final 
Form form) {


if (target != null) {

try {
// some processing
} catch (Exception exception) {
error(exception.getMessage());
}   
*target.add(showCommentPanel);*
}
}



};

what can be the problem?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/setOutputMarkupPlaceholderTag-not-working-to-render-panel-with-setvisible-false-tp4650313.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: setOutputMarkupPlaceholderTag not working to render panel with setvisible false...

2012-07-01 Thread kshitiz
Hi,

I have already tried that out...its in the code..:

*owCommentPanel.setOutputMarkupPlaceholderTag(true); *

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/setOutputMarkupPlaceholderTag-not-working-to-render-panel-with-setvisible-false-tp4650313p4650315.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: setOutputMarkupPlaceholderTag not working to render panel with setvisible false...

2012-07-02 Thread kshitiz
Thanks a lot...that worked...:)

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/setOutputMarkupPlaceholderTag-not-working-to-render-panel-with-setvisible-false-tp4650313p4650319.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Wicket captcha example

2012-07-15 Thread kshitiz
Hi,

Can anyone recommend me a good captcha example for wicket. I have tried out
the one given in library 
http://www.wicket-library.com/wicket-examples/captcha/?0
http://www.wicket-library.com/wicket-examples/captcha/?0  but it is throwing
the error:

*Couldn't resolve model type of
Model:classname=[org.apache.wicket.model.PropertyModel]:nestedModel=[]:expression=[password]
for [ [Component id = password]], please set the type yourself.*

Is there any example that can be used with a form?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-captcha-example-tp4650531.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket captcha example

2012-07-15 Thread kshitiz
Thank you...I will try that out...

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-captcha-example-tp4650531p4650533.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Which is the best way to manage the visibility of a component?

2012-07-29 Thread kshitiz
You can write the code in a separate method and call that method from A and
B...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Which-is-the-best-way-to-manage-the-visibility-of-a-component-tp4650853p4650854.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Where to add javascript in html pages which follow inheritance relationship.

2012-07-30 Thread kshitiz
So, if  put JS in page3, why it is not working? After all, it is the root
one...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Where-to-add-javascript-in-html-pages-which-follow-inheritance-relationship-tp4650855p4650866.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Where to add javascript in html pages which follow inheritance relationship.

2012-07-30 Thread kshitiz
OkkI was thinking this as a possibility..thanks for clarifying my
doubt...:)



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Where-to-add-javascript-in-html-pages-which-follow-inheritance-relationship-tp4650855p4650869.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Where to add javascript in html pages which follow inheritance relationship.

2012-07-30 Thread kshitiz
hi,

Sorry to disturb you again but I am trying out this code but it is not
working:

*Page1:*

http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en" 
   
xmlns:wicket="http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd";>








*JS code here...*




Page2:

http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en" 
   
xmlns:wicket="http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd";>








*JS code is not being called...:(. I have tried out all combinations like
removing head tags from Page2 or enclosing wicket:head tags with head tags
in Page1*




--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Where-to-add-javascript-in-html-pages-which-follow-inheritance-relationship-tp4650855p4650871.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Where to add javascript in html pages which follow inheritance relationship.

2012-07-30 Thread kshitiz
Nothat appeared as a replacement of "" in the forum...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Where-to-add-javascript-in-html-pages-which-follow-inheritance-relationship-tp4650855p4650873.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Cookies not getting deleted

2012-07-30 Thread kshitiz
Hi,

I am trying to delete 2 cookies by using the code:


*Cookie emailIdCookie = ((WebRequest)
getRequestCycle()

.getRequest()).getCookie("emailId");

Cookie passwordCookie = ((WebRequest) 
getRequestCycle()

.getRequest()).getCookie("password");

if (emailIdCookie != null && 
passwordCookie != null) {

emailIdCookie.setMaxAge(0);
((WebResponse) 
getRequestCycle().getResponse())

.addCookie(emailIdCookie);

passwordCookie.setMaxAge(0);
((WebResponse) 
getRequestCycle().getResponse())

.addCookie(passwordCookie);

}
*

But they are not being removed. I have seen a post related to it but the
person missed out path setting of the cookie. In my case,I am not setting
any path. Do I need to set it? 



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Cookies-not-getting-deleted-tp4650876.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Cookies not getting deleted

2012-07-30 Thread kshitiz
Thnx..:) It is working now...we need to set path then...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Cookies-not-getting-deleted-tp4650876p4650880.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Editing list in Dataview

2012-07-31 Thread kshitiz
Hi,

Right now I am using listview but I am considering to look after dataview
where data is fetched from database everytime you change page. So, do we
have to modify our query to get the required data to be displayed in the
page? I mean right now I am  retrieving all data from database. 

Also, will it be possible for me to update the list being displayed in a
page like deleting a content or rearranging them?



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Editing-list-in-Dataview-tp4650885.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Where to add javascript in html pages which follow inheritance relationship.

2012-07-31 Thread kshitiz
Please help me out here...for a child page..how would I add javascript in its
head. I have tried out wicket:head with head tag in base page but it is not
working out...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Where-to-add-javascript-in-html-pages-which-follow-inheritance-relationship-tp4650855p4650903.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



RE: Where to add javascript in html pages which follow inheritance relationship.

2012-08-01 Thread kshitiz
Hi,

Actually the scene is different here. Page2 is child of Page3. The hierarchy
is:

Page3
  Page2
Page1

So, I have modified Page2 as:

http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en"
   
xmlns:wicket="http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd";>











--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Where-to-add-javascript-in-html-pages-which-follow-inheritance-relationship-tp4650855p4650931.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Need suggestion on minimizing session usage in wicket web application

2012-08-02 Thread kshitiz
Hi,

I need some suggestions. In my wicket application (in development phase), I
have used normal forms and links. While going through the concept of
stateless pages and forms, I am confused about converting the forms and
components to stateless. Will it really minimize session usage in the
system. I need to minimize it as i wont be having much server space
initially. 



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Need-suggestion-on-minimizing-session-usage-in-wicket-web-application-tp4650956.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Need suggestion on minimizing session usage in wicket web application

2012-08-02 Thread kshitiz
Thanks for the links. One thing that I want to ask that do yo think we should
use LoadableDetachable models to minimize session usage? Like for every
thing examples labels, links, dropdowns, etc.  



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Need-suggestion-on-minimizing-session-usage-in-wicket-web-application-tp4650956p4650963.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Need suggestion on minimizing session usage in wicket web application

2012-08-02 Thread kshitiz
OkkI think for large user base, I should go for stateless pages. But the
problem is that my app is entirely ajax based. So, how would I use ajax
behavior for stateless components. As far as I have read, ajax requires
components to be stateful
(/http://apache-wicket.1842946.n4.nabble.com/stateless-ajax-behavior-td1933611.html/).
Will it be possible for me to use same ajax behavior like updating panel,
etc on stateless pages?



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Need-suggestion-on-minimizing-session-usage-in-wicket-web-application-tp4650956p4650976.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Need suggestion on minimizing session usage in wicket web application

2012-08-03 Thread kshitiz
Actually I am planning to host the app in Google application engine. One
thing I am not able to understand, getStatelessHint() if applied in the
constructor of a page should return whether that page is stateless or not.
So, in my page which is full of ajax and statefull components, why it is
printing true? I am simply printing...

public Page(PageParameters pageParameters)(
final PageParameters pageParameters, UserDomain 
userDomain,
UserDomain loggedInUserDomain) {

// many statefull components added
*System.out.println(this.getStatelessHint());*  returning true..
}



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Need-suggestion-on-minimizing-session-usage-in-wicket-web-application-tp4650956p4650982.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Need suggestion on minimizing session usage in wicket web application

2012-08-03 Thread kshitiz
Ya..that worked...and for each component...I think statelessChecker is there.
But I am not able to figure out how to use it for a component? I read you
post 
http://apache-wicket.1842946.n4.nabble.com/Why-is-stateless-from-making-my-page-stateful-td3662059.html
http://apache-wicket.1842946.n4.nabble.com/Why-is-stateless-from-making-my-page-stateful-td3662059.html
 
But not able to get...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Need-suggestion-on-minimizing-session-usage-in-wicket-web-application-tp4650956p4650987.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Stateless ajaxPagingNavigator...

2012-08-03 Thread kshitiz
hi,

Is there any stateless ajax paging navigator like staeless ajax form or
links?  I am not able to find any related component in internet...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Stateless-ajaxPagingNavigator-tp4650994.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Editing list in Dataview

2012-08-03 Thread kshitiz
Thanks Paul...I was wondering though..is there any way to do without Spring?
I mean why to go for Spring just for one component...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Editing-list-in-Dataview-tp4650885p4650995.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Alternative way to deal with session minimizing issue

2012-08-03 Thread kshitiz
Hi,

As we all know that wicket provides great component to develop complex web
applications. But being stateful, one may have to think about session
consumption. So, what I was thinking if states of different pages are stored
in session, can we clear our page maps for every new page request? Will it
help to minimize session usage ??



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Alternative-way-to-deal-with-session-minimizing-issue-tp4650996.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Image is not getting ajax refreshed in wicket 1.5

2012-08-08 Thread kshitiz
Hi,

I am simply displaying a captcha image which is suppose to refresh on
hitting a button:

*   final String captchaValue = generateRandomString(30);
final NonCachingImage image = new NonCachingImage("image",
new CaptchaImageResource(captchaValue));
image.setOutputMarkupId(true);


AjaxFallbackButton ajaxRegisterSubmitButton = new 
AjaxFallbackButton(
"register", registerForm) {

protected void onSubmit(AjaxRequestTarget target, final 
Form form) {

// some processing

if (target != null) {
image.setImageResource(new 
CaptchaImageResource(generateRandomString(30)));
target.add(feedbackPanel);
target.add(image);
}

}
*

The code is simple...do I need to put CaptchaImageResource, image variables
as private class variabes?



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Image-is-not-getting-ajax-refreshed-in-wicket-1-5-tp4651053.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Image is not getting ajax refreshed in wicket 1.5

2012-08-08 Thread kshitiz
Solved...actually my mistake...I was refreshing the image in onError
section...



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Image-is-not-getting-ajax-refreshed-in-wicket-1-5-tp4651053p4651056.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Need clarification for modifying usage of modal.js

2012-08-15 Thread kshitiz
Hi,

I want to position a modal window in the center of the current viewable
window rather than whole one. For that I need to use customized modal.js as
I have read in wicket forum. Now, in modal.js

/http://code.google.com/p/koodaripalvelut-wicket/source/browse/trunk/webtest/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js?r=503/

*In center function, it is already placing modal in center of viewport. So,
what I need to modify then? In my case, modal window is being positioned at
the center of the whole page rather than the viewable part.*



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Need-clarification-for-modifying-usage-of-modal-js-tp4651247.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



AjaxFormSubmitBehavior causing page refresh in IE

2012-08-15 Thread kshitiz
Hi,

I have a simple code which is running fine in chrome...


// defining text field for user to search
*   final RequiredTextField searchTextField = new
RequiredTextField(
"search");

searchTextField.add(new AjaxFormSubmitBehavior("onSubmit") {

protected void onSubmit(AjaxRequestTarget target) {
try {
// some processing
if (target != null) {
target.add(searchFeedbackPanel);
}

}

});
*

But in IE, it is causing page refresh...how can i solve this issue?




--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/AjaxFormSubmitBehavior-causing-page-refresh-in-IE-tp4651267.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AjaxFormSubmitBehavior causing page refresh in IE

2012-08-16 Thread kshitiz
Solved...actually IE cannot read onSubmit action. So, I used onkeydown as
stated in
http://apache-wicket.1842946.n4.nabble.com/TextField-submit-via-Ajax-td3002094.html

That will solve the problem..:)



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/AjaxFormSubmitBehavior-causing-page-refresh-in-IE-tp4651267p4651290.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Should I really go for LoadableDetachableModel ?

2012-08-19 Thread kshitiz
Hi,

Please help me out here. In my web app, I have to show a list of data.
Previously I was using simple arraylist in listview. To deal with any memory
concern in future, I moved from arraylist to loadabledetachablemodal list.
But now, in any operation like delete, update etc, whole list is being
uploaded from database which is a bit time consuming. I know this is pretty
obvious. So, its like i have to compromise on one issue. So what should I
do? For highly traffic websites, is ldm necessary?



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Should-I-really-go-for-LoadableDetachableModel-tp4651353.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Should I really go for LoadableDetachableModel ?

2012-08-19 Thread kshitiz
Hi,

Thanks for the reply. I am trying t achieve what you suggested me. But one
thing I want to ask. In listDataProvider, you will anyway provide list of
data to get rendered. You may render it in any manner but that list will be
stored as final or class variable. Wont that take up the session ? I mean
what difference will it make to use dataview instead of simple list with
listview in terms of memory? I am trying to understand its concept so please
ignore my mistake...:)



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Should-I-really-go-for-LoadableDetachableModel-tp4651353p4651356.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Should I really go for LoadableDetachableModel ?

2012-08-19 Thread kshitiz
Hi,

Thank you for clarifying me. Removing the reference can help me out. Let me
try it :)



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Should-I-really-go-for-LoadableDetachableModel-tp4651353p4651359.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



What sort of page variables are stored in page map?

2012-08-23 Thread kshitiz
Hi,

For a web page, what sort of variables are stored in page map to hold its
state when user moved from that page to another? Like class variables, final
variables would be getting saved. Other than those, if we define a variable
or any component in its constructor, what happens to such variables when one
moved to another page?



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/What-sort-of-page-variables-are-stored-in-page-map-tp4651460.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



  1   2   >