<? if (isset($_SESSION['murrix']['languages']) && is_array($_SESSION['murrix']['languages'])) { foreach ($_SESSION['murrix']['languages'] as $language) { if ($language == $_SESSION['murrix']['language']) continue; ?> <form name="sLangswitch" id="sLangswitch" action="javascript:void(null);" onsubmit="Post('langswitch','sLangswitch');"> <div> <input class="hidden" type="hidden" name="language" value="<?php echo $language; ?> "/> <input type="image" src="<?php echo imgpath("{$language}.jpg"); ?> " alt="<?php echo ucf(i18n($language)); ?> "/> </div> </form> <? } } ?>
?> <?php echo ucf(i18n("month")); ?> <?php echo cmd(img(imgpath("right.png")), "exec=calendar&view=" . $args['view'] . "&date=" . date("Ymd", strtotime("+1 month", strtotime($args['date'])))); ?> · <?php echo cmd(img(imgpath("left.png")), "exec=calendar&view=" . $args['view'] . "&date=" . date("Ymd", strtotime("-1 year", strtotime($args['date'])))); ?> <?php echo ucf(i18n("year")); ?> <?php echo cmd(img(imgpath("right.png")), "exec=calendar&view=" . $args['view'] . "&date=" . date("Ymd", strtotime("+1 year", strtotime($args['date'])))); ?> </fieldset> <div style="margin-right: 20px;"> <? $firstday = strtotime(date("Y-m", strtotime($args['date']))."-01"); for ($p = 1; $p <= 3; $p++) { $args_small = array("events"=>$args['events'],"firstday"=>$firstday); ?> <div style="float: left; display: inline; width: 150px; margin-right: 10px;"> <?php echo compiletplWithOutput("scripts/calendar/small_month", $args_small); ?> </div> <?
<? echo compiletpl("title/big", array("left"=>"License")); global $abspath; ?> <div class="text_height"> <?php echo nl2br(getFile("{$abspath}/docs/LICENSE.txt")); ?> </div> <center> <? echo cmd(img(imgpath("left.png")), "exec=install&action=preinstall"); echo cmd(img(imgpath("right.png")), "exec=install&action=database"); ?> </center>
?> " style="display: none;"> <div class="date"> <div class="right"> <? foreach ($persons as $person) echo cmd(img(geticon($person->getIcon()))." ".$person->getName(), "exec=show&node_id=".$person->getNodeId()); ?> <a href="javascript:noneDisplay('event_more_<?php echo $event->getNodeId(); ?> ');blockDisplay('event_less_<?php echo $event->getNodeId(); ?> ')"><?php echo img(imgpath("1downarrow.png")); ?> </a> </div> <? echo $datetime; ?> <div class="clear"></div> </div> <hr/> <?php echo $description; ?> </div> <? }
$_SESSION['murrix']['rightcache']['file'][] = $value_id; ?> <div class="container"> <? echo ucf(i18n("file"))." $n ".i18n("of")." ".count($family)."<br/>"; if ($prev !== false) echo cmd(img(imgpath("left.png")), "exec=show&node_id=".$prev->getNodeId()); else echo img(imgpath("gray_left.png")); echo " ".cmd(img(imgpath("up.png")), "exec=show&node_id=".$parent->getNodeId())." "; if ($next !== false) echo cmd(img(imgpath("right.png")), "exec=show&node_id=".$next->getNodeId()); else echo img(imgpath("gray_right.png")); ?> </div> <?/*<a target="top" href="?file=<?php echo $value_id; ?> "><?php echo $data; ?> </a>*/?> <?php echo $data; ?> <table cellspacing="0" style="width: <?php
function ResampleImage($file_dir, $file_name, $size, $delete = false, $quality) { $dot = strrpos($file_name, '.'); $fext = substr($file_name, $dot); switch (strtolower($fext)) { case '.jpeg': // расширение не поддерживается: // расширение не поддерживается: case '.jpg': if (!function_exists('ImageCreateFromJPEG')) { return false; } break; case '.gif': if (!function_exists('ImageCreateFromGIF')) { return false; } break; case '.png': if (!function_exists('ImageCreateFromPNG')) { return false; } break; default: return false; } $img_size = @GetImageSize($file_dir . '/' . $file_name); if ($img_size[2] > 3) { return false; } # 1-GIF;2-JPG;3-PNG if (isset($size[1])) { $new_size = ImageSize2($img_size, $size[0], $size[1]); } else { $new_size = ImageSize2($img_size, $size[0]); } if ($img_size[0] == $new_size[0] && $img_size[1] == $new_size[1]) { $ret = $file_dir . '/' . $file_name; return imgpath($ret); # No changes needed } switch ($img_size[2]) { case 1: $src = @ImageCreateFromGIF($file_dir . '/' . $file_name); break; case 2: $src = @ImageCreateFromJPEG($file_dir . '/' . $file_name); break; case 3: $src = @ImageCreateFromPNG($file_dir . '/' . $file_name); break; } if (!$src) { return $file_name; } if ($img_size[2] != '1' && function_exists('ImageCreateTrueColor')) { # GIF не поддерживается $dst = ImageCreateTrueColor($new_size[0], $new_size[1]); ImageCopyResampled($dst, $src, 0, 0, 0, 0, $new_size[0], $new_size[1], $img_size[0], $img_size[1]); } else { $dst = ImageCreateTrueColor($new_size[0], $new_size[1]); $trans_color = imagecolorallocate($dst, 255, 0, 0); $color = imagecolorallocate($dst, 255, 255, 255); imagecolortransparent($dst, $trans_color); ImageCopyResized($dst, $src, 0, 0, 0, 0, $new_size[0], $new_size[1], $img_size[0], $img_size[1]); } if (!$delete) { switch ($img_size[2]) { case 1: ImageGIF($dst, $file_dir . '/' . $file_name . '1'); break; case 2: ImageJPEG($dst, $file_dir . '/' . $file_name . '1', $quality); break; case 3: ImagePNG($dst, $file_dir . '/' . $file_name . '1'); break; } } else { switch ($img_size[2]) { case 1: ImageGIF($dst, $file_dir . '/' . $file_name); break; case 2: ImageJPEG($dst, $file_dir . '/' . $file_name, $quality); break; case 3: ImagePNG($dst, $file_dir . '/' . $file_name); break; } } ImageDestroy($src); ImageDestroy($dst); $new_name = new_file_name($file_name, "_" . $size[0]); if (file_exists($file_dir . '/' . $new_name)) { $num = 1; while (file_exists($file_dir . '/' . new_file_name($file_name, '[' . $num . ']' . "_" . $size[0]))) { $num++; } $new_name = new_file_name($file_name, '[' . $num . ']' . "_" . $size[0]); } if (!$delete) { rename($file_dir . '/' . $file_name . '1', $file_dir . '/' . $new_name); } else { rename($file_dir . '/' . $file_name, $file_dir . '/' . $new_name); } $ret = $file_dir . '/' . $new_name; return imgpath($ret); }
<? echo compiletpl("title/big", array("left"=>"Database checks")); $list = array(); $list[] = array("Test", "Status"); $fatal = false; foreach ($args['checks'] as $check) { if ($check['fatal'] && !$check['status']) $fatal = true; $list[] = array($check['text'], $check['status'] ? "Yes" : "No".($check['fatal'] ? " - fatal error" : "")); } echo compiletpl("table", array("list"=>$list, "endstring"=>" ")); ?> <center> <? echo cmd(img(imgpath("left.png")), "exec=install&action=database"); if ($fatal) echo img(imgpath("gray_right.png")); else echo cmd(img(imgpath("right.png")), "exec=install&action=config"); ?> </center>
if ($home_id > 0) { $home = new mObject($home_id); $children = fetch("FETCH node WHERE link:node_top='$home_id' AND link:type='sub' AND !property:class_name='comment' NODESORTBY property:version SORTBY property:name"); ?> <div class="title"> <? if (count($children) > 0) { ?> <a class="right" href="javascript:void(null)" onclick="toggleSidebarContainer('<?php echo $home_id; ?> ')"><?php echo img(imgpath("1downarrow.png"), "", "", $home_id . "_arrow"); ?> </a> <? } echo cmd(ucf($home->getName()), "exec=show&node_id=$home_id", $class); ?> </div> <div id="<?php echo $home_id; ?> _container" class="container"> <? foreach ($children as $child) echo compiletpl("scripts/show/small_line", array("class"=>$class), $child); ?>
<? if ($num_pages > 1) { ?> <div class="main"> <div class="container"> <? if ($page_num-1 <= 0) echo img(imgpath("leftarrow.png"))." "; else echo cmd(img(imgpath("leftarrow.png"))." ", "exec=show&".$pagername."_page=".($page_num-1)); for ($i = 1; $i <= $num_pages; $i++) { if ($i == $page_num) echo "<b>$i</b> "; else echo cmd("$i ", "exec=show&".$pagername."_page=$i"); } if ($page_num+1 > $num_pages) echo img(imgpath("rightarrow.png")); else echo cmd(img(imgpath("rightarrow.png")), "exec=show&".$pagername."_page=".($page_num+1)); ?> </div> </div> <? } ?>
foreach ($result as $lang) $hide .= "document.getElementById('edit_$lang').style.display='none';document.getElementById('select_$lang').className='tab';"; $show = "document.getElementById('edit_$language').style.display='block';document.getElementById('select_$language').className='tab_selected';"; ?><a id="select_<?php echo $language; ?> " class="tab<?php echo $language == $_SESSION['murrix']['language'] ? "_selected" : ""; ?> " href="javascript:void(null)" onclick="<?php echo $hide . $show; ?> "><?php echo img(imgpath("{$language}.jpg")) . " " . ucf(i18n($language)); ?> </a><? } ?> <br/> <div class="clear"></div> </div> <? } foreach ($_SESSION['murrix']['languages'] as $language) { $style = ""; if ($language != $_SESSION['murrix']['language']) $style = "style=\"display: none;\"";
?> <a href="http://murrix.berlios.de/"><img alt="MURRiX" src="<?php echo imgpath("murrix.gif"); ?> " style="width: 80px; height: 15px;"/></a><br/><br/> <a href="http://validator.w3.org/check?uri=referer"><img src="<?php echo imgpath("valid-xhtml10.gif"); ?> " alt="Valid XHTML 1.1" style="height: 15px; width: 80px;"/></a><br/><br/> <a href="http://jigsaw.w3.org/css-validator/check/referer"><img src="<?php echo imgpath("valid-css.gif"); ?> " alt="Valid CSS!" style="height: 15px; width: 80px;"/></a><br/><br/> <a href="http://www.getfirefox.com/"><img alt="Firefox" src="<?php echo imgpath("getfirefox.gif"); ?> " style="width: 80px; height: 15px;"/></a> </td> </tr> </table> </td> <td class="fade_right"></td> </tr> <tr> <td colspan="3" class="bottom"> <?php echo compiletpl("footer", array()); ?> </td> </tr>
<input class="form" id="<?php echo $args['varname']; ?> " name="<?php echo $args['varname']; ?> " type="text" value="<?php echo $args['value']; ?> "/> <a id="button<?php echo $args['varname']; ?> " href="javascript:void(null);" onclick="openCalendar('<?php echo $args['varname']; ?> ', 'button<?php echo $args['varname']; ?> ')"><?php echo img(imgpath("calendar.jpg"), ucf(i18n("calendar"))); ?> </a>
$active_polls = array(); $now = time(); foreach ($polls as $object) { if (strtotime($object->getVarValue("closedate")) < $now || strtotime($object->getVarValue("opendate")) > $now) continue; $active_polls[] = $object; } if (count($active_polls) > 0) { ?> <div class="title"> <a class="right" href="javascript:void(null)" onclick="toggleSidebarContainer('polls')"><?php echo img(imgpath("1downarrow.png"), "", "", "polls_arrow"); ?> </a> <?php echo ucf(i18n("polls")); ?> </div> <div id="polls_container" class="container"> <div class="polls_wrapper"> <div class="polls_wrapper_margin"> <? $polldir_id = getNode("/root/polls"); if ($polldir_id <= 0) { ?>
<? echo compiletpl("title/big", array("left"=>"Pre-installation checks")); $list = array(); $list[] = array("Test", "Status"); $fatal = false; foreach ($args['checks'] as $check) { if ($check['fatal'] && !$check['status']) $fatal = true; $list[] = array($check['text'], $check['status'] ? "Yes" : "No".($check['fatal'] ? " - fatal error" : "")); } echo compiletpl("table", array("list"=>$list, "endstring"=>" ")); ?> <center> <? echo img(imgpath("gray_left.png")); if ($fatal) echo img(imgpath("gray_right.png")); else echo cmd(img(imgpath("right.png")), "exec=install&action=license"); ?> </center>
echo $args['default_path']; ?> " type="text"><br/> <br/><br/> Transport<br/> <select class="selectbox" name="transport"> <option <?php echo "standard" == $args['transport'] ? "selected" : ""; ?> value="standard">Standard</option> <option <?php echo "ajax" == $args['transport'] ? "selected" : ""; ?> value="ajax">Ajax</option> </select> <br/><br/> Administrator password<br/> <input class="textline" name="password" value="<?php echo $args['password']; ?> " type="password"><br/> </form> <center> <? echo cmd(img(imgpath("left.png")), "exec=install&action=database"); echo runjs(img(imgpath("right.png")), "Post('install','sInstall')"); ?> </center>
<? if (isset($_SESSION['murrix']['languages']) && is_array($_SESSION['murrix']['languages'])) { foreach ($_SESSION['murrix']['languages'] as $language) { if ($language == $_SESSION['murrix']['language']) continue; ?> <form name="sLangswitch" id="sLangswitch" action="javascript:void(null);" onsubmit="Post('langswitch','sLangswitch');"> <div> <input class="hidden" type="hidden" name="language" value="<?php echo $language; ?> "/> <input class="image" type="image" src="<?php echo imgpath($language . ".jpg"); ?> " alt="<?php echo ucf(i18n($language)); ?> "/><br/> <?php echo ucf(i18n($language, $language)); ?> </div> </form> <? } } ?>
echo img(imgpath("1downarrow.png"), "", "", "login_arrow"); ?> </a> <?php echo ucf(i18n("login")); ?> </div> <div id="login_container" class="container"> <?php echo $_SESSION['murrix']['system']->createZone("zone_login"); ?> </div> <div class="title"> <a class="right" href="javascript:void(null)" onclick="toggleSidebarContainer('calendar')"><?php echo img(imgpath("1downarrow.png"), "", "", "calendar_arrow"); ?> </a> <?php echo cmd(ucf(i18n("calendar")), "exec=calendar", "sidebar"); ?> </div> <div id="calendar_container" class="container"> <div class="container"> <?php echo compiletpl("scripts/calendar/small_month", array("firstday" => strtotime(date("Y-m") . "-01"))); ?> </div> </div> <?php
<? echo compiletpl("title/big", array("left"=>"Finish")); echo $args['logtext']; ?> <center> <? echo cmd(img(imgpath("left.png")), "exec=install&action=config"); echo "<a href=\"./\">".img(imgpath("right.png"))."</a>"; ?> </center>
<? for ($i = $args['start']; $i < $args['end']; $i++) { $object = $args['objects'][$i]; ?> <div class="sub_title"> <a class="right" href="javascript:void(null)" onclick="toggleSidebarContainer('<?php echo $object->getNodeId(); ?> ')"><?php echo img(imgpath("1downarrow.png"), "", "", $object->getNodeId() . "_arrow"); ?> </a> <?php echo cmd(img(getIcon($object->getIcon())) . " " . $object->getName(), "exec=show&node_id=" . $object->getNodeId()); ?> <div class="clear"></div> </div> <div id="<?php echo $object->getNodeId(); ?> _container"> <?php echo compiletpl("scripts/show/data", array(), $object); ?> <?php echo compiletpl("scripts/show/children", array(), $object); ?> </div> <? }
<? echo compiletpl("scripts/show/tabs", array("view"=>"versions"), $object); echo compiletpl("title/big", array("left"=>img(geticon($object->getIcon()))." ".$object->getName()), $object); $num_versions = count($object->getVersionNumbers()); foreach ($_SESSION['murrix']['languages'] as $language) { $versions = fetch("FETCH object WHERE property:node_id='".$object->getNodeId()."' AND property:language='$language' NODESORTBY property:version,property:name"); echo compiletpl("title/medium", array("left"=>img(imgpath("$language.jpg"))." ".ucf(i18n($language))), $object); $versionlist = array(); $versionlist[] = array(ucf(i18n("version")), ucf(i18n("created")), ucf(i18n("name")), ucf(i18n("user")), " "); foreach ($versions as $version) { $user = $version->getUser(); if ($user->id == 0) $user = ucf(i18n("unknown")); else $user = $user->name; $edit = ""; if ($object->hasRight("write")) { $edit = cmd(img(geticon("edit"))." ".ucf(i18n("new version from here")), "exec=edit&action=editversion&object_id=".$version->getId()); $edit .= " "; if ($num_versions == 1) $edit .= cmd(img(geticon("delete"))." ".ucf(i18n("delete")), "exec=delete&node_id=".$version->getNodeId());