Talk:Usability of Mediawiki as a collaborative workspace for knowledge creation

From Opasnet
Revision as of 07:21, 13 July 2010 by Tekerane (talk | contribs) (progress)
Jump to navigation Jump to search

AJAX and PHP testing on eractest wiki

Started testing some AJAX/PHP code on Eractest. This test code is not connected to the wiki and will only be accessible through the specific URL. Copied Rating Bar extension and renamed to TeeBar on Eractest. This extension will be used as a base for the new rating bar extension for Opasnet.

TeeBar extension

This extension will include all the functionality of the Rating Bar extension, only adding a second bar under the current one. The two bars will be named "Scientific Quality" and "Usefulness".

Things to do for the extension

  • Create tables into SQL database (DONE)
    • Design the SQL tables needed! (DONE)
      • See how the current tables work (DONE)
  • Make the extension behave like it should
    • SQL-queries altered to handle two types of rating
      • INSERTs (done, needs testing)
      • UPDATEs (done, needs testing)
      • SELECTs (done, needs testing)
    • Javascript updated to handle two types of rating
      • onmouseover (buggy, fix this)
      • things that happen on page load (buggy?)
  • Make the extension look like it should (layout will be considered after the bars work)
    • Change colors to fit OpasNet blue-purple-red? Keep old colors commented out in case they look better. (DONE)
    • Position of elements (bars, text fields) inside the rating box
  • Test the extension
  • Deploy to Opasnet
    • Squash bugs before deployment

Things that have been done wrong

  • (technical) Ideally, rewrite the whole thing with proper AJAX (current implementation is closer to "AJAH", doqueries returning HTML instead of XML)
  • (technical) Additionally, the rating bars could probably be done with two divs, instead of the current 101 div implementation. One div for background, one div to represent the bar, changing size on mouseover.
  • (usability) Currently the bars are not immediately clear about what they are displaying. Normally, they display the average rating. On mouseover, they start displaying the user's vote instead (or rather, vote-to-be)

Bugs to fix

  • You voted RATINGBAR_NO_TYPE % on page load (needs testing) (fixed, until proven otherwise)
    • doqueries.php: $vote_sent gets passed into initial page load as empty parameter (if-logic issue). This is wrong, by definition of the "load" request, which means the request should not ever pass a vote.
  • Counting of votes is misleading (fixed, until proven otherwise)
    • SELECT AVG(rating) FROM db.tab WHERE rating_type = t AND page_id=id;
    • this counts average of ALL votes, including "history" votes (votes already overwritten)
  • javascript displaying the ratings wrong and erratically