prepareQuery(); $table = $config->sql_tablename_publish_de(); header("Content-Type: text/plain; charset=UTF-8"); header("Expires: on, 01 Jan 1970 00:00:00 GMT"); header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); header('X-UA-Compatible: IE=edge,chrome=1'); header("Pragma: cache"); /* $random = strtolower(trim($func->stripHtml($_REQUEST['r']))); if ($random == "1"){ $stmt = $pdo->prepare("SELECT * FROM $table WHERE id>0 AND p_isonline=1 ORDER BY RAND LIMIT 30"); } else { $stmt = $pdo->prepare("SELECT * FROM $table WHERE id>0 AND p_isonline=1 ORDER BY p_timestamp DESC LIMIT 300000"); } */ $stmt = $pdo->prepare("SELECT * FROM $table WHERE id>0 AND p_isonline=1 ORDER BY RAND() LIMIT 3"); $stmt->execute(); while($rows = $stmt->fetch(PDO::FETCH_ASSOC)) { $shortcode = $rows["p_shortcode"]; $headline = $rows["p_headline"]; $keywords = $rows["p_tags"]; $linkingcode = "https://www.buzzerstar.com/".$func->makeArticleLink($shortcode); echo "$shortcode###$headline###$keywords###$linkingcode\n"; } $stmt = null; // doing this is mandatory for connection to get closed $pdo = null; exit(0); ?>