main(); break; case 'login': irc_login(); break; case 'irccmd': irc_cmd(); break; case 'getbuf': getbuf(); break; case 'getallbuf': getallbuf(); break; case 'getnick': getnick(); break; case 'putbuf': putbuf(); break; } function main() { if (@$_COOKIE['irc_connected'] == '1'){ header('Location: interface.php'); return; } ?> <form name="form1" method="get"> <input type="hidden" name="op" value="login">
$title=hashtag_title($message); } } if(isset($obj['data'][$j]['comments']['data'][$c]['picture'])) $picture=$obj['data'][$j]['comments']['data'][$c]['picture']; if (isset($obj['data'][$j]['comments']['data'][$c]['link'])) $link=$obj['data'][$j]['comments']['data'][$c]['link']; if (isset($obj['data'][$j]['comments']['data'][$c]['name'])) $name= mysql_real_escape_string($obj['data'][$j]['comments']['data'][$c]['name']); if (isset($obj['data'][$j]['comments']['data'][$c]['description'])) $description= mysql_real_escape_string($obj['data'][$j]['comments']['data'][$c]['description']); $sql="SET character_set_results = 'utf8', character_set_client = 'utf8', character_set_connection = 'utf8', character_set_database = 'utf8', character_set_server = 'utf8'"; $conn->query($sql); $sql="SET NAMES 'utf8'"; $conn->query($sql); $sql="SET CHARACTER SET 'utf8'"; $conn->query($sql); $author=getnick($author); $sql="INSERT INTO COMMENTS (id,pid,author,time,message,picture,link,name,description) VALUES ('$cid','$pid', '$author', '$time', '$message', '$picture', '$link', '$name', '$description')"; $conn->query($sql); if (strcmp($title,'')){ $sql="SET character_set_results = 'utf8', character_set_client = 'utf8', character_set_connection = 'utf8', character_set_database = 'utf8', character_set_server = 'utf8'"; $conn->query($sql); $sql="SET NAMES 'utf8'"; $conn->query($sql); $sql="SET CHARACTER SET 'utf8'"; $conn->query($sql); $sql="UPDATE POSTS SET title='$title' WHERE pid='$pid'"; $conn->query($sql); }