Wednesday, May 20, 2009

How to change standard alert() popup to fancy alert popup in Joomla 1.5

I have recently found an interesting jQuery plugin which is called jQuery Alerts Dialog. This plugin aims to replace the basic functionality provided by the standard JavaScript alert(), confirm(), and prompt() functions. In each browser alert() popup looks different, but this plugin can help to make it look equal and attractive. I decided to make it friends with my favorite CMS Joomla!. As a result I created 'Fancy Alerts' plugin which replaces standard alert() popup with fancy popup. You can download the plugin here.

18 comments:

  1. This is interesting - have you had any conflicts because of it?

    ReplyDelete
  2. Hi, Matt,

    I have tested it on Joomla 1.5 and all worked fine, but if you have any problem, please, report about it and I try to fix it in the future releases.

    ReplyDelete
  3. Won't work, if Javascript is disabled. But very nice.

    ReplyDelete
  4. if javascript is disabled, it makes no sense because alert() is native javascript function ;)

    ReplyDelete
  5. I added plugin to my J! installation but could determine how to get it to function. I tested a login error to see if i would get a response with no success. Is there a demo the plugin?

    ReplyDelete
  6. Sorry, but this plugin without demo, it looks like on jQuery plugin demo page, you can see it here http://abeautifulsite.net/notebook_files/87/demo/

    ReplyDelete
  7. This certainly looks like an interesting plugin. Is there any short tutorial? Newbies like myself would really appreciate it :).

    ReplyDelete
  8. Hi, Aleksandar,
    Only install and enable this plugin, that's all :)

    ReplyDelete
  9. Hello Alex,

    This is an excellent component, great work as it solves a lot of obtrusive problems, however I could not get it to work.

    I am trying to get the native Joomla errors to display in Fancy Alerts is this possible?

    Thanks in advance..

    ReplyDelete
  10. Hi xdrone,

    Fancy alerts popup only replaces alert() javascript function, but your proposal is interesting and I'll try to do it in the next release of the plugin.

    ReplyDelete
  11. How must I call javascript function? alert() or jalert()? I enabled the plugin, but it seams that don't work. With alert() i had a clasic javascript pop-up, but with jalert() it disply nothing. I use Joomla 1.5

    ReplyDelete
  12. Hi Eugen,

    Could you provide link to page where you use the plugin?

    ReplyDelete
  13. I'm just in developing it. I didn't publish it yet.

    ReplyDelete
  14. Sorry, but I can't help in this case because it can be conflict with other extensions and I need to see javascript errors that investigate this issue.

    ReplyDelete
  15. You can find it here: http://publisind.mocka.ro/index.php/cumparaturi
    You must complete a valid e-mail (eg. test@test.com) to the bottom of the page and press "Trimite comanda" button.
    Thank you very much for your help answer.

    ReplyDelete
  16. The plugin replaces core 'alert' function with fancy alert when DOM of a page is ready. Your alert is called before this event. You can use window.addEvent('load', function() {
    // code of your alert goes here
    }); code for your alert that resolve this problem.

    ReplyDelete
  17. Thank you very, very much for your answer. It solved my problem <:-p

    ReplyDelete
  18. just add below java script to your master page and all done..(also include jalert files and dependables)

    window.alert = function (message) {
    jAlert(message, "Manthan");
    }

    ReplyDelete