function view_name($link) { require ("connect.php"); $query = "SELECT name FROM `menu1` WHERE id='$link' limit 1"; $result = mysql_query($query); $row = mysql_fetch_array($result); $name = $row["name"]; echo $name; } function view_name_test($link) { require ("connect.php"); $query = "SELECT name FROM `menu_test` WHERE id='$link' limit 1"; $result = mysql_query($query); $row = mysql_fetch_array($result); $name = $row["name"]; echo $name; } function view_name_test2($link) { require ("connect.php"); $query = "SELECT name FROM `test` WHERE id='$link' limit 1"; $result = mysql_query($query); $row = mysql_fetch_array($result); $name = $row["name"]; echo $name; } function colvo_test($link) { require ("connect.php"); $query = "SELECT sum FROM `test` WHERE id='$link' limit 1"; $result = mysql_query($query); $row = mysql_fetch_array($result); $sum = $row["sum"]; return $sum; } function colvo_book($link) { require ("connect.php"); $query = "SELECT id FROM `info` WHERE parent_menu='$link'"; $result = mysql_query($query); $n=mysql_numrows($result); echo $n; } function img_resize($src, $dest, $width, $height, $rgb=0xFFFFFF, $quality=75) { if (!file_exists($src)) return false; $size = getimagesize($src); if ($size === false) return false; $format = strtolower(substr($size['mime'], strpos($size['mime'], '/')+1)); $icfunc = "imagecreatefrom" . $format; if (!function_exists($icfunc)) return false; $isrc = $icfunc($src); $idest = imagecreatetruecolor($width, $height); imagecopyresampled($idest, $isrc, 0, 0, 0, 0, ImageSX($idest), ImageSY($idest), ImageSX($isrc), ImageSY($isrc)); imagejpeg($idest, $dest, $quality); imagedestroy($isrc); imagedestroy($idest); return true; } function menu_obraz_res($id) { $query = "SELECT cleft, cright FROM `adv_catalogue` WHERE id='$id' limit 1"; $result = mysql_query($query); $row = mysql_fetch_array($result); $cleft = $row["cleft"]; $cright = $row["cright"]; $query = "SELECT cleft FROM `adv_catalogue` WHERE cleft>'$cleft' AND cleft<'$cright'"; $result = mysql_query($query); $row = mysql_fetch_array($result); $cleft = $row["cleft"]; echo $name; } function encode($in_str, $charset) { $out_str = $in_str; if ($out_str && $charset) { // define start delimimter, end delimiter and spacer $end = "?="; $start = "=?" . $charset . "?B?"; $spacer = $end . "\r\n " . $start; // determine length of encoded text within chunks // and ensure length is even $length = 90- strlen($start) - strlen($end); $length = floor($length/2) * 2; // encode the string and split it into chunks // with spacers after each chunk $out_str = base64_encode($out_str); $out_str = chunk_split($out_str, $length, $spacer); // remove trailing spacer and // add start and end delimiters $spacer = preg_quote($spacer); $out_str = preg_replace("/" . $spacer . "$/", "", $out_str); $out_str = $start . $out_str . $end; } return $out_str; } function strings_isemail($string) { return preg_match('%[-\\.\\w]+@[-\\w]+(?:\\.[-\\w]+)+%', $string); } function strings_clear($string) { $string = trim($string); $string = stripslashes($string); return htmlspecialchars($string, ENT_QUOTES); } function strings_stripstring($text, $wrap, $length) { $text = preg_replace('%(\\S{'.$wrap.'})%', '\\\\1 ', $text); return substr($text, 0, $length); } function sovp($num) { switch($num%10) { case "1": echo""; break; case "2": echo""; break; case "3": echo""; break; case "4": echo""; break; default: echo""; break; } } ?> if (isset($_POST['auth_name'])) { $name=mysql_real_escape_string($_POST['auth_name']); $pass=mysql_real_escape_string($_POST['auth_pass']); $query = "SELECT name FROM user WHERE log='$name' AND pass='$pass'"; $res = mysql_query($query) or trigger_error(mysql_error().$query); if ($row = mysql_fetch_assoc($res)) { session_start(); $_SESSION['user_id'] = $row['id']; $_SESSION['ip'] = $_SERVER['REMOTE_ADDR']; $_SESSION['name'] = $row['name']; } header("Location: http://".$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']."?link=$_POST[l]&type=$_POST[t]"); exit; } if (isset($_GET['action']) AND $_GET['action']=="logout") { session_start(); session_destroy(); header("Location: http://".$_SERVER['HTTP_HOST']."/"); exit; } if (isset($_REQUEST[session_name()])) session_start(); ?>
|
||||||||||||
: , 10 2024
|
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193
|
:
" -2006" 1 " -2007"
-2010
-2010 V - () 90- : : : . : : , : 2010 - - - - (16 - 17 2010 .) - (25 - 26 2010 .) - (2 - 3 2010 .) - (4 - 5 2010 .) " . " " . " 2007/2008 2008/2009 2009/2010 III - 2009 IV - IV - " " . Intel " " " Intel" |
|