| Re: Quote comment(s) button? |
| by marcionline on 2007/6/18 21:28:34 Well, I have found a javascript that can be used to do something like I want but I don't know to integrate it into XOOPS comments form. Here is the code: le="color: #000000"><?php <script> var isNav4Min = (navigator.appName == "Netscape" && parseInt(navigator.appVersion) >= 4) var isIE4Min = (navigator.appName.indexOf("Microsoft") != -1 && parseInt(navigator.appVersion) >= 4) function quoteSelection() { var userSelection = false; var textarea = document.postform.message; if (isNav4Min && window.getSelection() != '') { userSelection = window.getSelection(); } else if (isIE4Min && document.selection) { userSelection = document.selection.createRange().text; } if (userSelection) { insert_text( '[quote]n' + userSelection + 'n[/quote]n', true, false); textarea.focus(); userSelection = ''; return; } else { alert('Select a text in page and try again'); } } </script> To use it is just to create a link like this: le="color: #000000"><?php <a href="#" onclick="quoteSelection(); return false;">Quote Selected</a> How could I use it with XOOPS comments? Thanks in advance. |
| Re: Quote comment(s) button? |
| by giba on 2007/5/25 15:08:47 Hi Marcio. You is member team http://www.xoops.net.br , look in forum privative. Thanks |
| Quote comment(s) button? |
| by marcionline on 2007/5/25 13:59:38 Is there a way to include a "quote comment" button to comments, like in many others CMS ?? Thanks
|