开发者

JSP and HTML - Refreshing that doesn't up data the webpage

In my web client I have inside an if statement开发者_JS百科 a command like this

myList = myBean.getNewList();

that references a global List and is displayed in table form in the web page.

How is it that my web page doesn't update the table on screen till I refresh the page again? It seems to refresh by its self straight away after a button is pressed


Where is that code? In the *.jsp file, or in some backing java action?

Most likely, that code is never called until there is a request made to the server, via a button click which would probably do one of the following (depending on your application):

  1. Submitting a form or making some request to the server and building some response object to be rendered by your browser
  2. Make some Ajax call to change the innerHtml of one of your DOM elements
  3. use jQuery (or some other javascript) to change the innerHTML on the fly with some hard-coded data
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜