Technical Details
Forum version : #phpBB3Position : Founder
Concerned browser(s) : Mozilla Firefox, Google Chrome, Internet Explorer, Opera, Safari, Other
Who the problem concerns : All members
Forum link : http://alla-omar.mo-rpg.com
Description of problem
i want it to do the same act but with window to insert the img url
the code
- Code:
$(function() {
 if ($.sceditor) {
  $.sceditor.command.set('tbl', {
   exec : function() {
    this.insert('[tbl=',']');
   },
   txtExec : function() {
    this.insert('[tbl=',']');
   },
   tooltip : 'ŰźÙÙÙŰ© ۧÙÙ Ù۶ÙŰč'
  });
  toolbar += ',tbl';
 }
 for (var a = $('.post .content'), i = 0, j = a.length; i < j; i++) {
  if (/\[tbl=.*?\]/i.test(a[i].innerHTML)) {
   a[i].innerHTML = a[i].innerHTML.replace(/\[tbl=(.*?)\]/i, function(M, $1) {
    a[i].style.backgroundImage = 'url(' + $1 + ')';
    return '';
   });
  }
 }
});
Last edited by alla13 on Sun 20 May - 14:59; edited 1 time in total