Convert this code to JQuery

Convert this code to JQuery

Hello;
I need this code to be converted to jQuery, any help is welcome :

  1. function showtime () {
  2. var now = new Date();
  3. var hours = now.getHours();
  4. var minutes = now.getMinutes();
  5. var seconds = now.getSeconds();
  6. var shownow = hours+minutes+seconds;
  7. return shownow;
  8. }
  9. window.addEvent( 'domready', function() {
  10. $$('.like-{$id} img').addEvent('click', function(likeit) {
  11. likeit.stop();
  12. var ajax = new Request({
  13. url: '{$like}'+'&time=' + showtime(),
  14. method: 'get',
  15. noCache: 'true',
  16. onRequest: function(load) {
  17. $('status-{$id}').empty();
  18. $('status-{$id}').set('html','{$loading}');
  19.           },
  20. onComplete: function(response) {
  21. var res = JSON.decode(response);
  22. $('status-'+res.article).empty();
  23. if (res.msg) {
  24. $('status-'+res.article).set('html',res.msg);
  25. }
  26. if (res.count){
  27. $('lc-'+res.article).empty();
  28. $('lc-'+res.article).set('html',res.count);
  29. }
  30. }
  31. }).send();
  32. });
  33. $$('.unlike-{$id} img').addEvent('click', function(unlikeit) {
  34. unlikeit.stop();
  35. var ajax = new Request({
  36. url: '{$unlike}'+'&time=' + showtime(),
  37. method: 'get',
  38. noCache: 'true',
  39. onRequest: function(load) {
  40. $('status-{$id}').empty();
  41. $('status-{$id}').set('html','{$loading}');
  42.           },
  43. onComplete: function(response) {
  44. var res = JSON.decode(response);
  45. $('status-'+res.article).empty();;
  46. if (res.msg) {
  47. $('status-'+res.article).set('html',res.msg);
  48. //new Element('div',{id: 'loading'}).setHTML(res.msg).injectInside($('status-'+res.article));
  49. }
  50. if (res.count){
  51. $('unlc-'+res.article).empty();
  52. $('unlc-'+res.article).set('html',res.count);
  53. //new Element('div').setHTML(res.count).injectInside($('unlc-'+res.article));
  54. }
  55. }
  56. }).send();
  57. });
  58. });