• Post Reply Bookmark Topic Watch Topic
  • New Topic

Insert data into databse without page reload  RSS feed

 
Johan Greyling
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

I have jsp with a menu with links,eachlink opens a new window. How do I insert a record - ex. username from session - into the database without reloading the page when a link is clicked?

Thank you
 
Hendy Setyo Mulyo
Ranch Hand
Posts: 219
Firefox Browser Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can use AJAX implementation here. So every time you click the menu link, at first, you can request a dummy page which is inserting a record to database and then you can open the new window.

You can also insert a record to database inside the page that you want to display when you open the new window by using jspInit() method (if you are using pure JSP).
[ August 19, 2008: Message edited by: Hendy Setyo Mulyo ]
 
Johan Greyling
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

Thank you, I posted a question asking help with Ajax. You are the first person to give a nice answer and not a snotty remark, thank you.

I still don't know how to use Ajax, I am in the middle of a project and don't have time to learn(as was suggested) and trouble shoot.

Can you maybe assit me?
 
Hussein Baghdadi
clojure forum advocate
Bartender
Posts: 3479
Clojure Mac Objective C
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you don't know Ajax and don't have time to learn it, then don't employ it in your project!
Simply tell your manager you have to spend some time with Ajax in order to use it in the application or the feature will not be available in the project.
(Kind of mutual bulling hair strategy).
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!