Changeset 31


Ignore:
Timestamp:
03/05/05 06:47:41 (15 years ago)
Author:
gogo
Message:

Applied patch from ticket #31 to return editor from HTMLArea.replace()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/htmlarea.js

    r27 r31  
    547547 
    548548/** Helper function: replaces the TEXTAREA with the given ID with HTMLArea. */ 
    549 HTMLArea.replace = function(id, config) { 
     549HTMLArea.replace = function(id, config) 
     550{ 
    550551  var ta = HTMLArea.getElementById("textarea", id); 
    551   return ta ? (new HTMLArea(ta, config)).generate() : null; 
     552  if (ta) 
     553  { 
     554    var taobj = new HTMLArea(ta, config); 
     555    taobj.generate(); 
     556    return taobj; 
     557  } 
     558  else 
     559  { 
     560    return null; 
     561  }; 
    552562}; 
    553563 
Note: See TracChangeset for help on using the changeset viewer.