Opened 18 years ago
Closed 18 years ago
#3099 closed enhancement (fixed)
AJAX Responsiveness
Reported by: | mdawaffe | Owned by: | |
---|---|---|---|
Milestone: | 2.1 | Priority: | normal |
Severity: | normal | Version: | 2.1 |
Component: | Administration | Keywords: | ajax listman prototype |
Focuses: | Cc: |
Description
http://comox.textdrive.com/pipermail/wp-hackers/2006-August/007873.html
Cool things
- Switch to prototype.
- New WPAjax class. Some API, but mostly some simple error checking and cookie passing.
- New listman class. Keep old listman class for now (mostly as a comparison).
- Recolor list by swapping class names. The sexy fades take too long. We should look into it again later.
- When adding or updating content, wait for the server to respond (same as before).
- When deleting, approving, etc., update display immediately. When response comes, check it for errors and put back the old content if we need to.
- As many AJAX instances going as you want.
Things to worry about
- Since we update the display before the data is even fully sent, the user may browse away before the action catches. Solution not yet implemented. Will likely do something like tinyMCE does ("Don't go away, I'm still updating things!").
- Double posting the same request.
- Version is set to rand() in script loader to avoid caching. Obviously, this will change when it's been beaten down some more.
Attachments (5)
Change History (12)
#3
@
18 years ago
3099b.diff
- New WP_Ajax_Response class outputting the following format: http://codex.wordpress.org/User:MDAWaffe/admin_ajax
- Can pass WP_Errors through XML to client.
- Fix onXXXXXX handlers.
Still need to worry about the same old things:
- Since we update the display before the data is even fully sent, the user may browse away before the action catches. Solution not yet implemented. Will likely do something like tinyMCE does ("Don't go away, I'm still updating things!").
- Double posting the same request.
- Version is set to rand() in script loader to avoid caching. Obviously, this will change when it's been beaten down some more.
#5
@
18 years ago
3099c.diff
- When adding, clear froms right away. Restore as necessary.
- If user tries to navigate away from page before data is sent, warn with a confirmation dialog. Does not work in Opera (others?) since requires .onbeforeunload. Could write annoying loop with .onunload, but that seems hideous. Thoughts? Throbbers or GMail-like "Loading..." could be implemented as well.
- Double posting shouldn't be a problem now that we clear the form right away, but the feedback for this isn't great. Try it out.
Before Committing:
- Update version info in script-loader.
- svn mv wp-admin/list-manipulation-js.php wp-includes/js/list-manipulation-js.php, delete contents of that file, and overwrite with patch.
#6
@
18 years ago
3099d.diff
- Needs testing in "slow" environments. Delete something and then try to navigate away from page before it's all done.
- Needs testing in IE (and Opera... and everything else). Especially try doing an AJAX call and seeing if subsequent actions on the same object still go through AJAX or if it does a traditional request. Moderate/Unmod the same comment several times. Update the same custom field twice in a row. Add cats in Manage Cats and then delete them.
- Play around on the write post screen. Does doing ony other AJAX stuff conflict with autosave?
- Try double submitting.
Note: See
TracTickets for help on using
tickets.
1