Database = DATABASE_NAME; $db->User = DATABASE_USER; $db->Password = DATABASE_PASSWORD; $db->Host = DATABASE_HOST; // koniec definicie switch ( $_SERVER["REMOTE_ADDR"] ) { // case "147.213.226.29": // break; default: $passwd = $_SERVER["PHP_AUTH_PW"]; $login = $_SERVER["PHP_AUTH_USER"]; $logint = "-"; if(IsSet($_SERVER["PHP_AUTH_USER"])) { if(($login=="KMoldo") && ($passwd=="")) $logint="o"; $where = "where login='". $login ."'"; $db->query("select * from users ".$where); $db->next_record(); $user_login = $db->f(login); $user_passwd = $db->f(password); if ( StrLen($user_login) > 1 ) { if(($login == $user_login) && ($passwd == $user_passwd)) $logint="o"; } } // IsSet if ($logint=="-") { $logint="o"; $login ="free_user"; // jen free users 10.05.2017 } // login = "-" } // end case ["REMOTE_ADDR"] ?> query("select * from clanky ".$where); $db->next_record(); List($aut1, $tmp) = Explode(",", $db->f(autor)); $article = $rr ."_". $cc ."_". $aut1 .".pdf"; // PDF-ak !!! $farticle = "./full/". $article; if ( ! File_Exists ($farticle) ) // +$ss { $article = $rr ."_". $cc ."_". $aut1 ."_". $ss .".pdf"; // PDF-ak !!! $farticle = "./full/". $article; } if ( File_Exists ($farticle) ) // velkost pdf-clanku { $size = FileSize ( $farticle ); } if ($size > 0) { header("Expires: 0"); // We'll be outputting a PDF header('Content-type: application/pdf'); // header("Content-Length: $size"); // It will be called downloaded.pdf header("Content-Disposition: attachment; filename=$article;"); // header("Content-Disposition: inline; filename=$article"); // header("Author: (c) OldSoft - 2004"); /* ?> Kovove materialy - <? $rk=$rr+1962; echo $rr .",  ". $rk .",  c. ". $cc .",  p. ". $ss ." ";?> 0 else { echo $imgartic, " Full Text "; echo "not available yet "; } die; } // End O.K. //@mysql_close($this->Link_ID); ?>