Changeset 1335

Show
Ignore:
Timestamp:
12/30/08 08:27:17 (15 months ago)
Author:
pazu2k@…
Message:

demos/index.html - slimmed down the php code parts.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/demos/index.html

    r1316 r1335  
    5050</head> 
    5151<body> 
    52 <?php } else { 
    53         $base = 'repository/trunk/demos/'; 
    54         $section = $base . $_GET['load']; 
    55  
    56         ?> 
    57         <script type="text/javascript"> 
    58                 var section; 
    59  
    60                 <?php printf ('section = "%s";', $section); ?> 
    61  
    62                 section && jQuery(function($){ 
    63                         $('dl.nav a').each(function(){ 
    64                                 this.setAttribute('href', '/' + section + '/' + this.getAttribute('href')); 
    65                                 $(this).attr('target', 'preview'); 
    66                         }); 
    67                 }); 
    68         </script> 
    6952<?php } ?> 
    7053 
     
    9578                                                         
    9679                        <div class="normal"> 
    97                                         <?php if(isset($plain) && isset($_GET['load'])) {  
    98                                                 echo html_entity_decode('&lt;h4 class="demo-subheader"&gt;Functional demo:&lt;/h4&gt;'); 
    99                                                 echo html_entity_decode('&lt;h3&gt;'. $_GET['load'] .'&lt;/h3&gt;');  
    100                                                 echo html_entity_decode('&lt;div class="demo-config"&gt;'); 
    101                                                 echo html_entity_decode('&lt;iframe id="preview" name="preview" src="/'. $section .'/default.html" width="520" height="314" border="0" frameborder="0" style="overflow:auto"&gt;&lt;/iframe&gt;');  
    102                                                 echo html_entity_decode('&lt;div class="demo-config-menu"&gt;'); 
    103                                                 include($section .'/index.html');  
    104                                                 echo html_entity_decode('&lt;/div&gt;');                                                 
    105                                                 echo html_entity_decode('&lt;/div&gt;'); 
    106                                         } else { ?> 
     80                                        <?php if(isset($plain) && $content) { echo $content; } else { ?> 
    10781                                 
    10882                                        <h3>Instructions</h3>