[ Index ] |
|
Code source de Joomla 1.0.13 |
1 <?php 2 /** 3 * @version $Id: contentwindow.php 5864 2006-11-27 22:54:44Z Saka $ 4 * @package Joomla 5 * @copyright Copyright (C) 2005 Open Source Matters. All rights reserved. 6 * @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.php 7 * Joomla! is free software. This version may have been modified pursuant 8 * to the GNU General Public License, and as distributed it includes or 9 * is derivative of works licensed under the GNU General Public License or 10 * other free or open source software licenses. 11 * See COPYRIGHT.php for copyright notices and details. 12 */ 13 14 // Set flag that this is a parent file 15 define( "_VALID_MOS", 1 ); 16 17 require_once ( '../includes/auth.php' ); 18 include_once ( $mosConfig_absolute_path . '/language/' . $mosConfig_lang . '.php' ); 19 20 // limit access to functionality 21 $option = strval( mosGetParam( $_SESSION, 'option', '' ) ); 22 $task = strval( mosGetParam( $_SESSION, 'task', '' ) ); 23 24 switch ($option) { 25 case 'com_content': 26 case 'com_typedcontent': 27 if ( $task != 'edit' && $task != 'editA' && $task != 'new' ) { 28 echo _NOT_AUTH; 29 return; 30 } 31 break; 32 33 default: 34 echo _NOT_AUTH; 35 return; 36 break; 37 } 38 39 $css = mosGetParam( $_REQUEST, 't', '' ); 40 41 // css file handling 42 // check to see if template exists 43 if ( $css != '' && is_dir($mosConfig_absolute_path .'/templates/'. $css .'/css/template_css.css' )) { 44 $css = $css; 45 } else if ( $css == '' ) { 46 $css = 'rhuk_solarflare_ii'; 47 } 48 49 $iso = split( '=', _ISO ); 50 // xml prolog 51 echo '<?xml version="1.0" encoding="'. $iso[1] .'"?' .'>'; 52 ?> 53 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 54 <html xmlns="http://www.w3.org/1999/xhtml"> 55 <base href="<?php echo($mosConfig_live_site); ?>/" /> 56 <head> 57 <title>Content Preview</title> 58 <link rel="stylesheet" href="templates/<?php echo $css;?>/css/template_css.css" type="text/css" /> 59 <script> 60 var form = window.opener.document.adminForm 61 var title = form.title.value; 62 63 var alltext = form.introtext.value; 64 if (form.fulltext) { 65 alltext += form.fulltext.value; 66 } 67 68 // do the images 69 var temp = new Array(); 70 for (var i=0, n=form.imagelist.options.length; i < n; i++) { 71 value = form.imagelist.options[i].value; 72 parts = value.split( '|' ); 73 74 temp[i] = '<img src="images/stories/' + parts[0] + '" align="' + parts[1] + '" border="' + parts[3] + '" alt="' + parts[2] + '" hspace="6" />'; 75 } 76 77 var temp2 = alltext.split( '{mosimage}' ); 78 79 var alltext = temp2[0]; 80 81 for (var i=0, n=temp2.length-1; i < n; i++) { 82 alltext += temp[i] + temp2[i+1]; 83 } 84 </script> 85 <meta http-equiv="Content-Type" content="text/html; <?php echo _ISO; ?>" /> 86 </head> 87 <body style="background-color:#FFFFFF"> 88 <table align="center" width="90%" cellspacing="2" cellpadding="2" border="0"> 89 <tr> 90 <td class="contentheading" colspan="2"><script>document.write(title);</script></td> 91 </tr> 92 <tr> 93 <script>document.write("<td valign=\"top\" height=\"90%\" colspan=\"2\">" + alltext + "</td>");</script> 94 </tr> 95 <tr> 96 <td align="right"><a href="#" onClick="window.close()">Close</a></td> 97 <td align="left"><a href="javascript:;" onClick="window.print(); return false">Print</a></td> 98 </tr> 99 </table> 100 </body> 101 </html>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Wed Nov 21 14:43:32 2007 | par Balluche grâce à PHPXref 0.7 |
![]() |