1. #1
    Ext JS Premium Member
    Join Date
    Mar 2007
    Location
    Virginia, USA
    Posts
    504
    Vote Rating
    0
    vtswingkid is on a distinguished road

      0  

    Default Do not set body.innerHTML='' if scripts are loaded in body

    Do not set body.innerHTML='' if scripts are loaded in body


    If I move all the scripts into the head all is well.
    All is well in netscape and firefox as is.
    Problem is most of the css is lost in IE and Opera.

    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
    <html>
    	<head>
    		<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    		<title>Untitled Document</title>
    	</head>
    	<body>
    		<link rel='stylesheet' type='text/css' href='ext/resources/css/ext-all.css' />
    		<script type='text/javascript' src='ext/yui-utilities.js'></script>
    		<script type='text/javascript' src='ext/ext-all.js'></script>
    		<script type='text/javascript' src='ext/ext-bridge-yui.js'></script>
    		<script type='text/javascript'>
    			Main = function(){
    				var layout;
    				return{
    					Init:function(){
    						document.body.innerHTML='';
    						layout = new Ext.BorderLayout(document.body,{
    							north:{
    								initialSize: 50	
    							},
    							west:{
    								split: true,
    								initialSize: 150,
    								minSize: 100,
    								maxSize: 300,
    								titlebar: true,
    								animate: true						
    							},
    							center:{
    								tabPosition: 'top',
    			                    closeOnTab: true,
    			                    alwaysShowTabs: true,
    			                    resizeTabs: true
    							}
    						});
    						layout.beginUpdate();
    						layout.add('north', new Ext.ContentPanel('header',{autoCreate:true}));
    						layout.add('west', new Ext.ContentPanel('menu',{autoCreate:true, title:'Menu'}));
    						layout.add('center', new Ext.ContentPanel('home',{autoCreate:true, title:'Home'}));
    						layout.endUpdate();
    					}
    				}
    			}();
    			Ext.onReady(Main.Init);
    
    		</script>
    	</body>
    </html>
    Oh, let me double check that this works on the .40 release.

    EDIT:

    Was wrong this isn't working in .40 release...

  2. #2
    Sencha - Community Support Team JeffHowden's Avatar
    Join Date
    Mar 2007
    Location
    Forest Grove, OR
    Posts
    1,038
    Vote Rating
    1
    JeffHowden is on a distinguished road

      0  

    Default


    It probably should fail as you're trying to reference tags (script and style) that may only be placed in the head in a document with a strict doctype.

  3. #3
    Sencha User
    Join Date
    Mar 2007
    Posts
    7,854
    Vote Rating
    4
    tryanDLS is on a distinguished road

      0  

    Default


    Does the strict DTD enforce putting script in the head tag only?

  4. #4
    Ext JS Premium Member
    Join Date
    Mar 2007
    Location
    Virginia, USA
    Posts
    504
    Vote Rating
    0
    vtswingkid is on a distinguished road

      0  

    Default


    I removed the document strict line at the top.... Same result.
    I also tried it with
    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/loose.dtd">

  5. #5
    Ext JS Premium Member
    Join Date
    Mar 2007
    Location
    Virginia, USA
    Posts
    504
    Vote Rating
    0
    vtswingkid is on a distinguished road

      0  

    Default document.body.innerHTML='';

    document.body.innerHTML='';


    The problem is:
    Code:
    document.body.innerHTML='';
    I guess IE and Opera must wipe out the script files that were loaded into the body.
    Firefox does not.

    Well it has nothing to do with alpha 1.0...
    But for future reference don't erase the body if you are putting scripts in it.

Similar Threads

  1. [1.0a3r4]Transformed <select> gets moved before</body&
    By mystix in forum Ext 2.x: Help & Discussion
    Replies: 3
    Last Post: 16 Mar 2007, 6:50 AM
  2. Ext.Button(document.body, {...}) failes to render???
    By vtswingkid in forum Ext 1.x: Help & Discussion
    Replies: 2
    Last Post: 19 Jan 2007, 9:59 AM
  3. BorderLayout within FORM rather than BODY
    By kalebwalton in forum Community Discussion
    Replies: 2
    Last Post: 22 Dec 2006, 2:38 PM
  4. BorderLayout ContentPanel body height
    By pomata in forum Ext 1.x: Bugs
    Replies: 0
    Last Post: 30 Nov 2006, 6:24 PM
  5. overlay.body has no properties?
    By thejoker101 in forum Ext 1.x: Help & Discussion
    Replies: 6
    Last Post: 26 Oct 2006, 7:50 AM

Thread Participants: 2

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi