I wonder if it would be possible to save client state in an iFrame when going from one page to another 开发者_StackOverflowin a RESTful application.
Example:
There is a navigation tree on the page and the user has elapsed and collapsed its nodes. When he clicks on a node the entire page changes, but the state of the navigation tree should be the same on the new page. Is that possible with an iFrame? Or is there any other trick (before HTML5)?
The trick is to use cookies, specifically use JavaScript and document.cookie
, because the iFrame will obviously disappear when the page reloads.
精彩评论