0

about cookies

asked 2009-06-02 11:41:06 +0800

shilpa gravatar image shilpa
51 4

Hello...
I have one problem, that is i have two pages (one is admin page and user page) in both pages i have a common icon( i.e. one search page will come when i click on that icon),inside that icon (that is search page) there is a exit button," WHAT I WANT IS IF SUPPOSE I ENTERED TO SEARCH PAGE FROM ADMIN PAGE( THROUGH ICON),WHEN I CLICKED ON THE EXIT BUTTON THAT ADMIN PAGE SHOULD COME .......SIMILARLY IF SUPPOSE FROM USERPAGE ,IT SHOULD GO TO THE USERPAGE.......
I WANT A LOGIC FOR THE EXIT METHOD INORDER TO GO TO THE ADMIN OR USER PAGE... I THINK IT WILL SOLVE BY COOKIES.....
SO PLZ HELP ME IN THIS .......ITS VERY URGENT.......

delete flag offensive retag edit

10 Replies

Sort by ยป oldest newest

answered 2009-06-03 03:07:53 +0800

iantsai gravatar image iantsai
2755 1

Maybe you could use some pics to describe what you want.

link publish delete flag offensive edit

answered 2009-06-03 04:58:44 +0800

shilpa gravatar image shilpa
51 4

i have two login one is admin and another is user......both have their own user id and password ......if admin login's then admin page will open ,if user login's then user page will open.......
In both page one page is common(eg search page , this can use by both)...in that page there is a exit button ......if we opened that search page from admin page at that time if we click on exit button in the search page...then it should come back to admin page not user page....and similarly for user page ....
so plz help me......

link publish delete flag offensive edit

answered 2009-06-03 06:34:33 +0800

iantsai gravatar image iantsai
2755 1

then, the destination of your exit button should be decided by outer page(eg: admin or user pages).

you can use macro component for doing this.

ZK Documentation: Macro Component

link publish delete flag offensive edit

answered 2009-06-03 08:45:15 +0800

shilpa gravatar image shilpa
51 4

i am calling exit() method when clicked on exit button...so inside the exit()method code will decide to go to the perticular page(if search page from admin page) that is admin page ....(if search page from user page then it should go to the userpage)....
The logic should write in the exit button only ...."if we opened that search page by admin page else by userpage"
plz help mme.......

link publish delete flag offensive edit

answered 2009-06-03 11:17:18 +0800

shilpa gravatar image shilpa
51 4

i want to go to the just current back page .......

link publish delete flag offensive edit

answered 2009-06-04 03:12:14 +0800

iantsai gravatar image iantsai
2755 1

if you want to do "Exit", you must have a destination to go.
If the destination couldn't come from exit() itself (which means you already have a context to get the information, something like page, URL, bookmark, etc...), Then your exit() should except a link as it's Destination.

if you thought page.setVariable() is not good, you can use page.getName()(Don't forget to assign the page's name) to get back current page name.

link publish delete flag offensive edit

answered 2009-06-04 04:57:21 +0800

shilpa gravatar image shilpa
51 4

i just want the logic that is in "if statement ,if suppose the page (search page opened) from admin page then it should go back to admin page only (when clicked on exit button in the search page) else it should go to the user page.....
plz help me.......

link publish delete flag offensive edit

answered 2009-06-04 06:42:34 +0800

iantsai gravatar image iantsai
2755 1

Then use page.getName(), and see if the name is indicated to admin.

link publish delete flag offensive edit

answered 2009-06-04 08:45:20 +0800

shilpa gravatar image shilpa
51 4

i just want to go to the previous page.....

link publish delete flag offensive edit

answered 2009-06-05 01:18:51 +0800

iantsai gravatar image iantsai
2755 1

Then, please Google:"zk sendredirect"

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2009-06-02 11:41:06 +0800

Seen: 803 times

Last updated: Jun 05 '09

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More