[ Index ] |
|
Code source de phpMyVisites 2.3 |
1 <?php 2 /** 3 * ClickHeat : Mise à jour des informations d'un groupe / Group info update 4 * 5 * @author Yvan Taviaud - LabsMedia - www.labsmedia.com 6 * @since 04/04/2007 7 **/ 8 9 /** Direct call forbidden */ 10 if (!defined('CLICKHEAT_LANGUAGE')) 11 { 12 exit; 13 } 14 15 $group = isset($_GET['group']) ? str_replace('/', '', $_GET['group']) : ''; 16 17 if (file_exists($clickheatConf['logPath'].$group.'/url.txt')) 18 { 19 $f = @fopen($clickheatConf['logPath'].$group.'/url.txt', 'r'); 20 $webPage = trim(fgets($f, 1024)); 21 fclose($f); 22 } 23 else 24 { 25 $webPage = ''; 26 } 27 $webPage = explode('>', $webPage); 28 if (count($webPage) !== 4) 29 { 30 $webPage = array('../', 0, 0, 0); 31 } 32 $url = &$webPage[0]; 33 $left = (int) $webPage[1]; 34 $center = (int) $webPage[2]; 35 $right = (int) $webPage[3]; 36 unset($webPage); 37 38 $pos = strpos($group, ','); 39 if ($pos === false) 40 { 41 $groupTitle = &$group; 42 } 43 else 44 { 45 $groupTitle = substr($group, $pos + 1); 46 } 47 ?> 48 <span class="float-right"><a href="#" onclick="hideGroupLayout(); return false;"><img src="<?php echo CLICKHEAT_PATH ?>images/ko.png" width="16" height="16" align="absmiddle" alt="Close" /></a></span> 49 <h1><?php echo LANG_LAYOUT ?> '<em><?php echo htmlentities($groupTitle); ?></em>'</h1> 50 <form action="#" method="get" onsubmit="return false;"> 51 <?php echo LANG_EXAMPLE_URL ?> <input type="text" name="url" id="formUrl" value="<?php echo htmlentities($url); ?>" size="50" /> <a href="#" onclick="saveGroupLayout(); return false;"><img src="<?php echo CLICKHEAT_PATH ?>images/save.png" width="16" height="16" alt="Save" /></a><br /> 52 <span class="layout-left-fixed"><?php echo LANG_LAYOUT_FIXED ?></span> <span class="layout-left-liquid"><?php echo LANG_LAYOUT_LIQUID ?></span> <span class="layout-left-empty"><?php echo LANG_LAYOUT_NONE ?></span><br /> 53 <table cellpadding="0" cellspacing="2" border="0"> 54 <?php 55 for ($i = 0; $i < 7; $i++) 56 { 57 $leftFixed = ($i & 1) === 1; 58 $centerFixed = ($i & 2) === 2; 59 $rightFixed = ($i & 4) === 4; 60 $selected = ($leftFixed === false && $left === 0 || $leftFixed === true && $left !== 0) && ($centerFixed === false && $center === 0 || $centerFixed === true && $center !== 0) && ($rightFixed === false && $right === 0 || $rightFixed === true && $right !== 0); 61 echo '<tr><td><div class="layout-left-', $leftFixed ? 'fixed' : ($centerFixed ? 'empty' : 'liquid'), '"><div class="layout-center-', $centerFixed ? 'fixed' : 'liquid', '"><div class="layout-right-', $rightFixed ? 'fixed' : ($centerFixed ? 'empty' : 'liquid'), '"></div></div></div></td>'; 62 echo '<td>', constant('LANG_LAYOUT_'.$i), '</td>'; 63 echo '<td><span id="layout-span-', $i, '" style="display:none;">'; 64 echo $leftFixed ? LANG_LAYOUT_LEFT.' <input type="text" name="left-'.$i.'" id="layout-left-'.$i.'" size="3" value="'.$left.'" /> ' : '<input type="hidden" name="left-'.$i.'" id="layout-left-'.$i.'" value="0" />'; 65 echo $centerFixed && !$leftFixed && !$rightFixed ? LANG_LAYOUT_CENTER.' <input type="text" name="center-'.$i.'" id="layout-center-'.$i.'" size="3" value="'.$center.'" /> ' : '<input type="hidden" name="center-'.$i.'" id="layout-center-'.$i.'" value="0" />'; 66 echo $rightFixed ? LANG_LAYOUT_RIGHT.' <input type="text" name="right-'.$i.'" id="layout-right-'.$i.'" size="3" value="'.$right.'" />' : '<input type="hidden" name="right-'.$i.'" id="layout-right-'.$i.'" value="0" />'; 67 echo '<a href="#" onclick="saveGroupLayout(); return false;"><img src="', CLICKHEAT_PATH, 'images/save.png" width="16" height="16" align="absmiddle" alt="Save" /></a></span></td>'; 68 echo '<td><input type="radio" name="layout-radio" id="layout-radio-', $i, '"', $selected ? ' checked="checked"' : '', ' onclick="showRadioLayout(', $i, ');" /></td></tr>'; 69 } 70 ?> 71 </table> 72 </form>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Mon Nov 26 14:10:01 2007 | par Balluche grâce à PHPXref 0.7 |
![]() |