Advertisement
hxxxrz

Скрипт вывода ссылок

Nov 28th, 2017
377
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. <?php
  2. error_reporting(E_ALL);
  3. ignore_user_abort(true);
  4. ini_set('display_errors', 'on');
  5. ini_set('error_log','error_log.txt');
  6. header('X-Robots-Tag: noindex');
  7.  
  8. require_once('php/func.php');
  9.  
  10. $format = @strip_tags(trim($_GET['format']));
  11.  
  12. $format_permissible = array('txt');
  13. if (!in_array($format, $format_permissible)) {
  14. $format = 'index';
  15. }
  16.  
  17. $pagelist = $db->query("SELECT url, category FROM pages WHERE date < ".$time." ORDER BY date DESC;");
  18.  
  19. $i =0;
  20. while ($echo = $pagelist->fetchArray()) {
  21. $i++;
  22.  
  23. echo $httpscheme.'://'.$host.'/'.$echo['category'].'/'.$echo['url'].'/<br />';
  24.  
  25. }
  26. ;
  27.  
  28. $db->close();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement