View Single Post
  #1  
Old 14th June 2010, 09:48
mat22 mat22 is offline
Senior Member
 
Join Date: Jun 2009
Latvia
Posts: 119
Default Show/Hide News Don't Work
Hello again BL users! I have pretty small problem but I can't solve it. I don't use block system and I have news in my index.php with "Show/Hide" buttons but they don't work. My friend has got same source, only few files are different but this mod works for him. Here's my index.php:
[code]<?
require "include/bittorrent.php";
dbconn(false);
loggedinorreturn();

if ($_SERVER["REQUEST_METHOD"] == "POST")
{
$choice = $_POST["choice"];
if ($CURUSER && $choice != "" && $choice < 256 && $choice == floor($choice))
{
$res = mysql_query("SELECT * FROM polls ORDER BY added DESC LIMIT 1") or sqlerr(__FILE__, __LINE__);
$arr = mysql_fetch_assoc($res) or die("Nav jautājuma");
$pollid = $arr["id"];
$userid = $CURUSER["id"];
$res = mysql_query("SELECT * FROM pollanswers WHERE pollid=$pollid && userid=$userid") or sqlerr(__FILE__, __LINE__);
$arr = mysql_fetch_assoc($res);
if ($arr) die("
Attached Thumbnails
screen.png  
Reply With Quote