Changeset 773 for trunk


Ignore:
Timestamp:
03/13/07 11:34:27 (12 years ago)
Author:
ray
Message:

see Ticket #981 changed config var to xinha_config.browserQuirksMode = true|false

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XinhaCore.js

    r772 r773  
    413413  this.charSet = (typeof document.characterSet != 'undefined') ? document.characterSet : document.charset; 
    414414 
    415   // Doctype of the iframe, default is the doctype of the document 
    416   this.doctype = ''; 
     415  // Whether the edited document should be rendered in Quirksmode or Standard Compliant (Strict) Mode 
     416  // This is commonly known as the "doctype switch" 
     417  // for details read here http://www.quirksmode.org/css/quirksmode.html 
     418  // 
     419  // Possible values: 
     420  //    true     :  Quirksmode is used 
     421  //    false    :  Strict mode is used 
     422  // leave empty :  the mode of the document Xinha is in is used 
     423  this.browserQuirksMode = ''; 
    417424 
    418425  // URL-s 
     
    24012408   
    24022409  Xinha.freeLater(this, '_doc'); 
    2403    
     2410 
    24042411  doc.open("text/html","replace"); 
    24052412  var html = ''; 
     2413  if ( editor.config.browserQuirksMode === false ) 
     2414  { 
     2415    var doctype = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">'; 
     2416  } 
     2417  else if ( editor.config.browserQuirksMode === true ) 
     2418  { 
     2419     var doctype = ''; 
     2420  } 
     2421  else 
     2422  { 
     2423     var doctype = Xinha.getDoctype(document); 
     2424  } 
    24062425  if ( !editor.config.fullPage ) 
    24072426  { 
    2408     html += editor.config.doctype ? editor.config.doctype : Xinha.getDoctype(document) + "\n"; 
     2427    html += doctype + "\n"; 
    24092428    html += "<html>\n"; 
    24102429    html += "<head>\n"; 
Note: See TracChangeset for help on using the changeset viewer.