\n"; $adv.="\n\n"; $adv1 ="
\n"; $adv1.="\n
\n"; $adv2 ="
\n"; $adv2.="\n
\n"; $bookmark =""; $bookmark.="
"; $page2='current'; $field='regular'; require("/usr/local/www/peoples.ru/req/utils_new.class"); $my=new class_utils; $my->sql_connect(); $gotid=$my->check_search_string(trim($id)); $catalogornot=explode("-",$gotid); if (empty($catalogornot[1])==true) {$catalog='yes'; } else { $catalog='no';}; //$path=explode("$catalogornot[0]-",$gotid); $counting=strlen($catalogornot[0])+1; //echo $counting." . ||".$catalogornot[0]."||"; $paths=substr($gotid,$counting); //echo $paths; if ($catalog=='no'): endif; $txt=""; $i=0; if ($catalog=='yes'): $aSQL = "SELECT * FROM describe_ru WHERE section='$gotid' AND field='$field' ORDER BY id DESC LIMIT 30"; $aQResult = mysql_query($aSQL); if (mysql_error()) { print(mysql_error()); } while ($row = mysql_fetch_array($aQResult)): $i++; $name=trim($row['name']) ; $idnum=trim($row['id']) ; $nameengl=trim($row['nameengl']); $datepub=trim($row['datepub']); $path=trim($row['path']) ; $section=trim($row['section']) ; $visitors=trim($row['visitors']) ; $KodPersons=trim($row['KodPersons']) ; $description=nl2br(trim($row['description'])); $description_small=substr(trim($row['description']),0,200); $qSQL = "SELECT * FROM describe_ru_section WHERE nameengl='$section' ORDER BY RAND() LIMIT 1"; $qQResult = mysql_query($qSQL); if (mysql_error()) { print(mysql_error()); } while ($qrow = mysql_fetch_array($qQResult)): $sectionname=$qrow['name']; $title=$qrow['name']; endwhile; $firstpicture=""; $qSQL = "SELECT * FROM describe_ru_photo WHERE id_describe='$idnum' ORDER BY RAND() LIMIT 1"; $qQResult = mysql_query($qSQL); if (mysql_error()) { print(mysql_error()); } while ($qrow = mysql_fetch_array($qQResult)): $photoname=trim($qrow['photoname']) ; $width=trim($qrow['width']) ; if ($width>50) { $width=50; }; $firstpicture="http://www.describe.ru/images/$photoname"; endwhile; if ((empty($firstpicture)==true) && (empty($KodPersons)<>true)): $txt.="\n".$my->personsgetimg($KodPersons,'0',$width)."\n"; else: $txt.="\n\"\"\n"; endif; $txt.="\n"; $txt.="

$name

\n"; $txt.="

$description_small\nдалее »

\n\n"; $txt.="$datepub\n$visitors\n\n"; // $txt.="
  • $name
  • \n"; endwhile; if ($i>0) { $txt="

    $sectionname


    \n\n"; }; $menu="Начало / "; else: $aSQL = "SELECT * FROM describe_ru WHERE section='$catalogornot[0]' AND path='$paths'"; //echo $aSQL; $aQResult = mysql_query($aSQL); if (mysql_error()) { print(mysql_error()); } while ($row = mysql_fetch_array($aQResult)): $i++; $visitors=trim($row['visitors']) ; $idnum=trim($row['id']) ; $name=trim($row['name']) ; $title=trim($row['name']) ; $KodPersons=trim($row['KodPersons']) ; $source=""; if (empty($KodPersons)<>true): $whole_infos=$my->findpersoninfo($KodPersons); $whole_info=split("##", $whole_infos); $russian_name=$whole_info[0]; $english_name=$whole_info[1]; $IAllUrlInSity=$whole_info[2]; $in_site_path=$whole_info[3]; $who_is=$whole_info[4]; $source="Источник
    \n"; endif; $tags=trim($row['tags']) ; $nameengl=trim($row['nameengl']); $path=trim($row['path']) ; $section=trim($row['section']) ; $description=nl2br(trim($row['description'])); $description_small=substr(trim($row['description']),0,200); $count_desc=strlen($description); if ($count_desc<200): $description=$description; elseif ($count_desc>2500): $count_desc_max=$count_desc-1000; $description=$adv1.substr($description,0,$count_desc_max)."$adv".substr($description,-1000); else: $description=$adv1.$description; endif; $youtube=trim($row['youtube']) ; $datepub=trim($row['date_pub']) ; if (empty($youtube)<>true): $video="\n

    \n"; endif; $txt.="

    $name /$russian_name

    \n$description
    $adv2
    $bookmark $video
    $source Дата: ".$my->date_rus_time($datepub)." Посетителей: $visitors
    \n"; endwhile; $visitors++; $aSQL = "UPDATE describe_ru SET visitors='$visitors' WHERE id='$idnum'"; $aQResult = mysql_query($aSQL); if (mysql_error()) { print(mysql_error()); } $menu="Home / $section "; if ($i>0): $ii=0; $photoname=""; $aSQL = "SELECT * FROM describe_ru_photo WHERE id_describe='$idnum'"; $aQResult = mysql_query($aSQL); if (mysql_error()) { print(mysql_error()); } while ($row = mysql_fetch_array($aQResult)): $ii++; $photoname=trim($row['photoname']) ; $photodescription=trim($row['photodescription']) ; $width=trim($row['width']) ; if ($width>400) { $width=400; }; $txt.="
    \n$photodescription
    \n"; if ($ii==1) { $firstpicture="http://www.describe.ru/images/$photoname"; }; endwhile; if ((empty($photoname)==true) && (empty($KodPersons)<>true)): //echo "!!!".$KodPersons."!$photoname!"; $txt.="\n".$my->personsgetimgwhole($KodPersons,'0',450)."
    \n"; endif; // $wholeimages=$this->personsgetimgwhole($KodPersons,$IHistories_id); endif; endif; $my->sql_close(); if (empty($txt)<>true): /* $aSQL = "CREATE TABLE describe_ru ("; $aSQL .= "KodPersons int(8) default NULL,"; $aSQL .= "name varchar(240) default NULL,"; $aSQL .= "nameengl varchar(240) default NULL,"; $aSQL .= "description TEXT default NULL,"; $aSQL .= "path varchar(200) default NULL,"; $aSQL .= "section varchar(100) default NULL,"; $aSQL .= "datepub date default '0000-00-00',"; $aSQL .= "gener varchar(1) default '0',"; $aSQL .= "admin varchar(8) default NULL,"; $aSQL .= "ip varchar(16) default NULL,"; $aSQL .= "id int(11) NOT NULL auto_increment,"; $aSQL .= "date_registration timestamp default now(),"; $aSQL .= "PRIMARY KEY (id))"; $aQResult = mysql_query($aSQL); if (mysql_error()) { print(mysql_error()); } $aSQL = "CREATE TABLE describe_ru_photo ("; $aSQL .= "KodPersons int(8) default NULL,"; $aSQL .= "id_describe int(8) default NULL,"; $aSQL .= "photoname varchar(200) default NULL,"; $aSQL .= "photodescription varchar(240) default NULL,"; $aSQL .= "first varchar(1) default 'N',"; $aSQL .= "problem varchar(1) default 'N',"; $aSQL .= "gener varchar(1) default '0',"; $aSQL .= "width int(5) default '0',"; $aSQL .= "height int(5) default '0',"; $aSQL .= "admin varchar(8) default NULL,"; $aSQL .= "ip varchar(16) default NULL,"; $aSQL .= "id int(11) NOT NULL auto_increment,"; $aSQL .= "date_registration timestamp default now(),"; $aSQL .= "PRIMARY KEY (id))"; $aQResult = mysql_query($aSQL); if (mysql_error()) { print(mysql_error()); } $my->sql_close(); */ /* $my->sql_connect(); $aSQL = "SELECT * FROM describe_ru WHERE id='$id'"; $aQResult = mysql_query($aSQL); if (mysql_error()) { print(mysql_error()); } while ($row = mysql_fetch_array($aQResult)): $name=$row['name'] ; $KodPersons=$row['KodPersons'] ; */ //$description_small=substr($description,0,200); ?> <? echo $title; ?> , Хочу все знать, Хочу всё знать, описание, краткое описание" />
    */ echo $txt; echo $menu; require_once('/usr/local/www/describe.ru/www/ssi/video_out.shtml'); require_once('/usr/local/www/describe.ru/www/ssi/foot-dynamic-page.shtml'); endif; else: ?> <"; } else { $prev = "<"; } if($page>"; } else { $next = ">"; } for($i=0;$i<$pages;$i++) { if($i==$page){ $return.="[".($i+1)."]"; } else { $return.="[".($i+1)."]"; } } return $prev.$return.$next; } ?>