";
echo "Nu esti autentificat
";
echo "Sau sesiunea ta a expirat
";
echo "Autentificare";
echo "
";
echo "Nu ai permisiunea sa vezi continutul acestui forum
";
echo "Prim";
echo "
";
$crdate = time();
//$uid = getuid_sid($sid);
$texst = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_topics WHERE name LIKE '".$ntitle."' AND fid='".$fid."'"));
if($texst[0]==0)
{
$res = false;
$ltopic = mysql_fetch_array(mysql_query("SELECT crdate FROM lib3rtymrc_topics WHERE authorid='".$uid."' ORDER BY crdate DESC LIMIT 1"));
global $topic_af;
$antiflood = time()-$ltopic[0];
if($antiflood>$topic_af)
{
if((trim($ntitle)!="")||(trim($tpctxt)!=""))
{
$res = mysql_query("INSERT INTO lib3rtymrc_topics SET name='".$ntitle."', fid='".$fid."', authorid='".$uid."', text='".$tpctxt."', crdate='".$crdate."', lastpost='".$crdate."'");
}
if($res)
{
$usts = mysql_fetch_array(mysql_query("SELECT posts, plusses FROM lib3rtymrc_users WHERE id='".$uid."'"));
$ups = $usts[0]+1;
$upl = $usts[1]+1;
mysql_query("UPDATE lib3rtymrc_users SET posts='".$ups."', plusses='".$upl."' WHERE id='".$uid."'");
$tnm = htmlspecialchars($ntitle);
echo "Topic $tnm Creat cu succes";
$tid = mysql_fetch_array(mysql_query("SELECT id FROM lib3rtymrc_topics WHERE name='".$ntitle."' AND fid='".$fid."'"));
echo "
";
echo "Vizualizeaza topic";
}else{
echo "Eroare in crearea noului topic";
}
}else{
$af = $topic_af -$antiflood;
echo "Antiflood Control: $af";
}
}else{
echo "Numele topicului deja exista";
}
$fname = getfname($fid);
echo "
";
echo "$fname
";
echo "";
echo "Prim";
echo "
";
echo "Nu ai permisiunea sa vezi continutul acestui forum
";
echo "Prim";
echo "
";
$crdate = time();
$fid = getfid($tid);
//$uid = getuid_sid($sid);
$res = false;
$closed = mysql_fetch_array(mysql_query("SELECT closed FROM lib3rtymrc_topics WHERE id='".$tid."'"));
if(($closed[0]!='1')||(ismod($uid)))
{
$lpost = mysql_fetch_array(mysql_query("SELECT dtpost FROM lib3rtymrc_posts WHERE uid='".$uid."' ORDER BY dtpost DESC LIMIT 1"));
global $post_af;
$antiflood = time()-$lpost[0];
if($antiflood>$post_af)
{
if(trim($reptxt)!="")
{
$res = mysql_query("INSERT INTO lib3rtymrc_posts SET text='".$reptxt."', tid='".$tid."', uid='".$uid."', dtpost='".$crdate."', quote='".$qut."'");
$numart =mysql_query("SELECT uid FROM abonaretopic where nrtopic='".$tid."'");
$tinfo = mysql_fetch_array(mysql_query("SELECT name, text, authorid, crdate, views, fid, pollid from lib3rtymrc_topics WHERE id='".$tid."'"));
$tnm = htmlspecialchars($tinfo[0]);
$pmtext="Un comentariu nou a fost adaugat pe [topic=$tid]".$tnm."[/topic]";
while ($abon= mysql_fetch_array($numart))
{
$tm=time();
mysql_query("INSERT INTO lib3rtymrc_private SET text='".$pmtext."', byuid='4', touid='".$abon[0]."', timesent='".$tm."'");
}
}
if($res)
{
$usts = mysql_fetch_array(mysql_query("SELECT posts, plusses FROM lib3rtymrc_users WHERE id='".$uid."'"));
$ups = $usts[0]+10;// aici am mod
$upl = $usts[1]+10;// aici am mod
mysql_query("UPDATE lib3rtymrc_users SET posts='".$ups."', plusses='".$upl."' WHERE id='".$uid."'");
mysql_query("UPDATE lib3rtymrc_topics SET lastpost='".$crdate."' WHERE id='".$tid."'");
echo "Mesaj postat cu succes";
echo "
";
echo "Vizualizeaza topic";
}else{
echo "Eroare in postarea mesajului";
}
}else{
$af = $post_af -$antiflood;
echo "Antiflood Control: $af";
}
}else{
echo "Topicul este inchis postarilor";
}
$fname = getfname($fid);
echo "
";
echo "$fname
";
echo "";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM abonaretopic WHERE uid='".$uid."' and nrtopic='".$idt."'"));
if($exs[0]==0)
{
$res = mysql_query("insert into abonaretopic SET uid='".$uid."', nrtopic='".$idt."'");
if($res)
{
echo "Abonarea realizta
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Esti deja abonat
";
}
echo "";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM abonaretopic WHERE uid='".$uid."' and nrtopic='".$idt."'"));
if($exs[0]!=0)
{
$res = mysql_query("Delete from abonaretopic where uid='".$uid."' and nrtopic='".$idt."'");
if($res)
{
echo "dezabonarea realizta
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Nu esti abonta
";
}
echo "";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_xinfo WHERE uid='".$uid."'"));
if($exs[0]>0)
{
$res = mysql_query("UPDATE lib3rtymrc_xinfo SET country='".$ucon."', city='".$ucit."', street='".$ustr."', timezone='".$utzn."', phoneno='".$uphn."' WHERE uid='".$uid."'");
if($res)
{
echo "Adresa actualizata cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
$res = mysql_query("INSERT INTO lib3rtymrc_xinfo SET uid='".$uid."', country='".$ucon."', city='".$ucit."', street='".$ustr."', timezone='".$utzn."', phoneno='".$uphn."'");
if($res)
{
echo "Adresa actualizata cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}
echo "";
echo "Setari extinse
";
echo "";
echo "Prim";
echo "
"; $whnick = getnick_uid($who); echo "$whnick"; echo "
"; echo ""; $exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_clubmembers WHERE uid='".$who."' AND clid=".$clid."")); $cow = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_clubs WHERE owner='".$uid."' AND id=".$clid."")); if($exs[0]>0 && $cow[0]>0) { $mpt = mysql_fetch_array(mysql_query("SELECT points FROM lib3rtymrc_clubmembers WHERE uid='".$who."' AND clid='".$clid."'")); if($giv=="1") { $pnt = $mpt[0]+$pnt; }else{ $pnt = $mpt[0]-$pnt; if($pnt<0)$pnt=0; } $res = mysql_query("UPDATE lib3rtymrc_clubmembers SET points='".$pnt."' WHERE uid='".$who."' AND clid='".$clid."'"); if($res) { echo "Puncte club actualizate cu succes!"; }else{ echo "Eroare in baza de date!"; } }else{ echo "Lipseste Info!"; } echo "
"; echo ""; echo ""; echo "Prim"; echo "
"; echo ""; $whnick = getnick_uid($who); echo "$whnick"; echo "
"; echo ""; echo "Pentru ca unii au inteles gresit treaba cu acordarea de plusuri, proprietarii de cluburi nu mai pot da plusuri"; echo "
"; echo ""; echo ""; echo "Prim"; echo "
"; echo "";
$uid = getuid_sid($sid);
$exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_xinfo WHERE uid='".$uid."'"));
if($exs[0]>0)
{
$res = mysql_query("UPDATE lib3rtymrc_xinfo SET sitedscr='".$usds."', budsonly='".$ubon."', sexpre='".$usxp."' WHERE uid='".$uid."'");
if($res)
{
echo "Preferinte actualizate cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
$res = mysql_query("INSERT INTO lib3rtymrc_xinfo SET uid='".$uid."', sitedscr='".$usds."', budsonly='".$ubon."', sexpre='".$usxp."'");
if($res)
{
echo "Preferinte actualizate cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}
echo "";
echo "Setari extinse
";
echo "";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_xinfo WHERE uid='".$uid."'"));
if($exs[0]>0)
{
$res = mysql_query("UPDATE lib3rtymrc_xinfo SET gmailun='".$ugun."', gmailpw='".$ugpw."', gmailchk='".$ugch."', gmaillch='".time()."' WHERE uid='".$uid."'");
if($res)
{
echo "Setari Gmail actualizate cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
$res = mysql_query("INSERT INTO lib3rtymrc_xinfo SET uid='".$uid."', gmailun='".$ugun."', gmailpw='".$ugpw."', gmailchk='".$ugch."', gmaillch='".time()."'");
if($res)
{
echo "Setari Gmail actualizate cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}
echo "";
echo "Setari extinse
";
echo "";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_xinfo WHERE uid='".$uid."'"));
if($exs[0]>0)
{
$res = mysql_query("UPDATE lib3rtymrc_xinfo SET height='".$uhig."', weight='".$uwgt."', realname='".$urln."', eyescolor='".$ueys."', profession='".$upro."', racerel='".$ueor."',hairtype='".$uher."' WHERE uid='".$uid."'");
if($res)
{
echo "Date personale actualizate cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
$res = mysql_query("INSERT INTO lib3rtymrc_xinfo SET uid='".$uid."', height='".$uhig."', weight='".$uwgt."', realname='".$urln."', eyescolor='".$ueys."', profession='".$upro."', racerel='".$ueor."',hairtype='".$uher."'");
if($res)
{
echo "Date personale actualizate cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}
echo "";
echo "Setari extinse
";
echo "";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_xinfo WHERE uid='".$uid."'"));
if($exs[0]>0)
{
$res = mysql_query("UPDATE lib3rtymrc_xinfo SET likes='".$ulik."', deslikes='".$udlk."', habitsb='".$ubht."', habitsg='".$ught."', favsport='".$ufsp."', favmusic='".$ufmc."',moretext='".$umtx."' WHERE uid='".$uid."'");
if($res)
{
echo "Info actualizat cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
$res = mysql_query("INSERT INTO lib3rtymrc_xinfo SET uid='".$uid."', likes='".$ulik."', deslikes='".$udlk."', habitsb='".$ubht."', habitsg='".$ught."', favsport='".$ufsp."', favmusic='".$ufmc."',moretext='".$umtx."'");
if($res)
{
echo "Info actualizat cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}
echo "";
echo "Setari extinse
";
echo "";
echo "Prim";
echo "
";
if ($rpass=="")
{
$cns = 1;
}else{
$cns = 0;
}
$prooms = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_rooms WHERE static='0'"));
if($prooms[0]<10)
{
$res = mysql_query("INSERT INTO lib3rtymrc_rooms SET name='".$rname."', pass='".$rpass."', censord='".$cns."', static='0', lastmsg='".time()."'");
if($res)
{
echo "Camera creata cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Sunt create deja 10 camere
";
}
echo "Meniu chat
";
echo "Prim";
echo "
";
echo "Nu poti semna in cartea de vizita a acestui user
";
echo "Prim";
echo "
";
$crdate = time();
//$uid = getuid_sid($sid);
$res = false;
if(trim($msgtxt)!="")
{
$res = mysql_query("INSERT INTO lib3rtymrc_gbook SET gbowner='".$who."', gbsigner='".$uid."', dtime='".$crdate."', gbmsg='".$msgtxt."'");
}
if($res)
{
if(automsgs($who))
{
$msg = "".getnick_uid($uid)." ti-a adaugat un comentariu la profil![br/][i]P.S.:acesta este un pm automat,va rugam sa nu raspundeti la el![/i]";
echo pmautomat($msg, $who);
}
echo "Mesaj postat cu succes";
}else{
echo "Eroare in postarea mesajului";
}
echo "
";
echo "";
echo "Prim";
echo "
";
$voted = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_presults WHERE uid='".$uid."' AND pid='".$plid."'"));
if($voted[0]==0)
{
$res = mysql_query("INSERT INTO lib3rtymrc_presults SET uid='".$uid."', pid='".$plid."', ans='".$ans."'");
if($res)
{
echo "Multumim pentru vot";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Deja ai votat in acest chestionar";
}
echo "
";
echo "Prim";
echo "
";
$pid = mysql_fetch_array(mysql_query("SELECT pollid FROM lib3rtymrc_users WHERE id='".$uid."'"));
$res = mysql_query("UPDATE lib3rtymrc_users SET pollid='0' WHERE id='".$uid."'");
if($res)
{
$res = mysql_query("DELETE FROM lib3rtymrc_presults WHERE pid='".$pid[0]."'");
$res = mysql_query("DELETE FROM lib3rtymrc_pp_pres WHERE pid='".$pid[0]."'");
$res = mysql_query("DELETE FROM lib3rtymrc_polls WHERE id='".$pid[0]."'");
echo "Chestionar sters";
}else{
echo "Eroare in baza de date!";
}
echo "
";
echo "Prim";
echo "
";
$pid = mysql_fetch_array(mysql_query("SELECT owner FROM lib3rtymrc_clubs WHERE id='".$clid."'"));
$exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_announcements WHERE id='".$anid."' AND clid='".$clid."'"));
if(($uid==$pid[0])&&($exs[0]>0))
{
$res = mysql_query("DELETE FROM lib3rtymrc_announcements WHERE id='".$anid."'");
if($res)
{
echo "Anunt sters";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Nu poti sterge acest anunt!";
}
echo "
";
echo "Prim";
echo "
";
$pid = mysql_fetch_array(mysql_query("SELECT owner FROM lib3rtymrc_clubs WHERE id='".$clid."'"));
if($uid==$pid[0])
{
$res = deleteClub($clid);
if($res)
{
echo "Club sters";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Nu poti sterge acest club!";
}
echo "
";
echo "Prim";
echo "
";
if($imgt=="idc")
{
$imgo = "http://klubro.net/rwidc.php?id=$uid";
}else if($imgt == "avt")
{
$av = mysql_fetch_array(mysql_query("SELECT avatar FROM lib3rtymrc_users WHERE id='".$uid."'"));
if(strpos($av[0], "http://")===false)
{
$av[0] = "../".$av[0];
}
$imgo = $av[0];
}else if($imgt=="sml")
{
$sml = mysql_fetch_array(mysql_query("SELECT imgsrc FROM lib3rtymrc_smilies WHERE scode='".strtolower(trim($imgo))."'"));
$imgo = "../".$sml[0];
}else
{
$imgo = strtolower(trim($imgo));
}
$smsg = trim($smsg);
$isu = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_mypage WHERE uid='".$uid."'"));
if ($isu[0]>0)
{
$res = mysql_query("UPDATE lib3rtymrc_mypage SET thid='".$thms."', mimg='".$imgo."', msg='".$smsg."' WHERE uid='".$uid."'");
}else{
$res = mysql_query("INSERT INTO lib3rtymrc_mypage SET uid='".$uid."', thid='".$thms."', mimg='".$imgo."', msg='".$smsg."'");
}
echo mysql_error();
if($res)
{
echo "Site-ul tau a fost actualizat cu succes
";
echo "Vizualizeaza site-ul";
}else{
echo "Eroare in baza de date!";
}
echo "
";
echo "Prim";
echo "
";
$pid = mysql_fetch_array(mysql_query("SELECT pollid FROM lib3rtymrc_topics WHERE id='".$tid."'"));
$res = mysql_query("UPDATE lib3rtymrc_topics SET pollid='0' WHERE id='".$tid."'");
if($res)
{
$res = mysql_query("DELETE FROM lib3rtymrc_presults WHERE pid='".$pid[0]."'");
$res = mysql_query("DELETE FROM lib3rtymrc_polls WHERE id='".$pid[0]."'");
echo "Chestionar sters";
}else{
echo "Eroare in baza de date!";
}
echo "
";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$isin = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_clubmembers WHERE uid='".$uid."' AND clid='".$clid."'"));
if($isin[0]==0){
$res = mysql_query("INSERT INTO lib3rtymrc_clubmembers SET uid='".$uid."', clid='".$clid."', accepted='0', points='0', joined='".time()."'");
if($res)
{
echo "Cerere trimisa! proprietarul clubului ar trebuie sa iti accepte cererea";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Esti deja in acest club sau ai deja o cerere trimisa care nu a fost inca acceptata";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET hidden='".$acts."' WHERE id='".$uid."'");
if($res)
{
echo "Mod invizibil/vizibil actualizat cu succes
";
}else{
echo "Eroare in actualiarea modului
";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET notificare='".$acts."' WHERE id='".$uid."'");
if($res)
{
echo "Notificare PM acctualizata cu succes
";
}else{
echo "Eroare in actualiarea modului
";
}
echo "
";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$isin = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_clubmembers WHERE uid='".$uid."' AND clid='".$clid."'"));
if($isin[0]>0){
$res = mysql_query("DELETE FROM lib3rtymrc_clubmembers WHERE uid='".$uid."' AND clid='".$clid."'");
if($res)
{
echo "Iesit din club cu succes";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Nu esti membru al acestui club!";
}
echo "
";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$cowner = mysql_fetch_array(mysql_query("SELECT owner FROM lib3rtymrc_clubs WHERE id='".$clid."'"));
if($cowner[0]==$uid){
$res = mysql_query("UPDATE lib3rtymrc_clubmembers SET accepted='1' WHERE clid='".$clid."' AND uid='".$who."'");
if($res)
{
echo "Membru adaugat cu succes in club";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Acest club nu este al tau";
}
echo "
";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$cowner = mysql_fetch_array(mysql_query("SELECT owner FROM lib3rtymrc_clubs WHERE id='".$clid."'"));
if($cowner[0]==$uid){
$res = mysql_query("UPDATE lib3rtymrc_clubmembers SET accepted='1' WHERE clid='".$clid."'");
if($res)
{
echo "Toti membrii acceptati";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Acest club nu este al tau";
}
echo "
";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$cowner = mysql_fetch_array(mysql_query("SELECT owner FROM lib3rtymrc_clubs WHERE id='".$clid."'"));
if($cowner[0]==$uid){
$res = mysql_query("DELETE FROM lib3rtymrc_clubmembers WHERE accepted='0' AND clid='".$clid."'");
if($res)
{
echo "Refuza-i pe toti";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Acest club nu este al tau";
}
echo "
";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$cowner = mysql_fetch_array(mysql_query("SELECT owner FROM lib3rtymrc_clubs WHERE id='".$clid."'"));
if($cowner[0]==$uid){
$res = mysql_query("DELETE FROM lib3rtymrc_clubmembers WHERE clid='".$clid."' AND uid='".$who."'");
if($res)
{
echo "Membru sters cu succes din club";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Acest club nu este al tau";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
if(getplusses(getuid_sid($sid))>=30)
{
$pid = mysql_fetch_array(mysql_query("SELECT pollid FROM lib3rtymrc_users WHERE id='".$uid."'"));
if($pid[0] == 0)
{
$pques = $_POST["pques"];
$opt1 = $_POST["opt1"];
$opt2 = $_POST["opt2"];
$opt3 = $_POST["opt3"];
$opt4 = $_POST["opt4"];
$opt5 = $_POST["opt5"];
if((trim($pques)!="")&&(trim($opt1)!="")&&(trim($opt2)!=""))
{
$pex = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_polls WHERE pqst LIKE '".$pques."'"));
if($pex[0]==0)
{
$res = mysql_query("INSERT INTO lib3rtymrc_polls SET pqst='".$pques."', opt1='".$opt1."', opt2='".$opt2."', opt3='".$opt3."', opt4='".$opt4."', opt5='".$opt5."', pdt='".time()."'");
if($res)
{
$pollid = mysql_fetch_array(mysql_query("SELECT id FROM lib3rtymrc_polls WHERE pqst='".$pques."' "));
mysql_query("UPDATE lib3rtymrc_users SET pollid='".$pollid[0]."' WHERE id='".$uid."'");
echo "Chestionar creat cu succes";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Este deja un chestionar cu aceiasi intrebare";
}
}else{
echo "Un chestionar trebuie sa aiba macar o intrebare si doua variante de raspuns";
}
}else{
echo "Ai deja un chestionar";
}
}else{
echo "Ai nevoie de macar 30 de plusuri pentru a crea un chestionar";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
if((getplusses(getuid_sid($sid))>=500)||ismod($uid))
{
$pid = mysql_fetch_array(mysql_query("SELECT pollid FROM lib3rtymrc_topics WHERE id='".$tid."'"));
if($pid[0] == 0)
{
$pques = $_POST["pques"];
$opt1 = $_POST["opt1"];
$opt2 = $_POST["opt2"];
$opt3 = $_POST["opt3"];
$opt4 = $_POST["opt4"];
$opt5 = $_POST["opt5"];
if((trim($pques)!="")&&(trim($opt1)!="")&&(trim($opt2)!=""))
{
$pex = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_polls WHERE pqst LIKE '".$pques."'"));
if($pex[0]==0)
{
$res = mysql_query("INSERT INTO lib3rtymrc_polls SET pqst='".$pques."', opt1='".$opt1."', opt2='".$opt2."', opt3='".$opt3."', opt4='".$opt4."', opt5='".$opt5."', pdt='".time()."'");
if($res)
{
$pollid = mysql_fetch_array(mysql_query("SELECT id FROM lib3rtymrc_polls WHERE pqst='".$pques."' "));
mysql_query("UPDATE lib3rtymrc_topics SET pollid='".$pollid[0]."' WHERE id='".$tid."'");
echo "Chestionar creat cu succes";
}else{
echo "Eroare in baza de date!";
}
}else{
echo "Este deja un chestionar cu aceiasi intrebare";
}
}else{
echo "Un chestionar trebuie sa aiba o intrebare si macar doua variante de raspuns";
}
}else{
echo "Acest topic are deja un chestionar";
}
}else{
echo "Ai nevoie de macar 30 de plusuri pentru a crea un chestionar";
}
echo "
";
echo "Prim";
echo "
";
echo "Ai nevoie de macar 30 de plusuri pentru a aduce o remarca in jurnal
";
echo "Prim";
echo "
";
$crdate = time();
//$uid = getuid_sid($sid);
$res = false;
if((trim($msgtxt)!="")&&(trim($btitle)!=""))
{
$res = mysql_query("INSERT INTO lib3rtymrc_blogs SET bowner='".$uid."', bname='".$btitle."', bgdate='".$crdate."', btext='".$msgtxt."'");
}
if($res)
{
echo "Mesaj postat cu succes";
}else{
echo "Eroare in postarea mesajului";
}
echo "
";
echo "";
echo "Prim";
echo "
";
echo "Ai nevoie de macar 25 de plusuri pentru a aduce un element la descarca
";
echo "Prim";
echo "
";
$crdate = time();
//$uid = getuid_sid($sid);
$res = false;
if((trim($vilink)!="")&&(trim($viname)!=""))
{
$res = mysql_query("INSERT INTO lib3rtymrc_vault SET uid='".$uid."', title='".mysql_escape_string($viname)."', pudt='".$crdate."', itemurl='".$vilink."'");
}
if($res)
{
echo "Element adaugat cu succes";
}else{
echo "Eroare in adaugarea elementului";
}
echo "
";
echo "";
echo "Prim";
echo "
";
if(getplusses(getuid_sid($sid))<1500)
{
echo "Ai nevoie de 1500 de puncte pentru a posta mesaje live!";
}else{
$shtxt = $shtxt;
//$uid = getuid_sid($sid);
$shtm = time();
//
$uid = getuid_sid($sid);
$tm = time();
//$antiflood = 1800;/// anti flood time
$lastshout = mysql_fetch_array(mysql_query("SELECT MAX(shtime) FROM lib3rtymrc_shouts1 WHERE shouter='".$uid."'"));
//$lastshout = mysql_fetch_array(mysql_query("SELECT MAX(shtime) FROM lib3rtymrc_shouts1"));
//$shoutfl = $lastshout[0]+$antiflood;
$shoutfl = $lastshout[0]+getliveaf();
if(ismod($uid))$shoutfl=0;
if($shoutfl<$tm)
{
//
$res = mysql_query("INSERT INTO lib3rtymrc_shouts1 SET shout='".$shtxt."', shouter='".$uid."', shtime='".$shtm."'");
if($res)
{
$shts = mysql_fetch_array(mysql_query("SELECT shouts from lib3rtymrc_users WHERE id='".$uid."'"));
$shts = $shts[0]+1;
mysql_query("UPDATE lib3rtymrc_users SET shouts='".$shts."' WHERE id='".$uid."'");
echo "Mesaj live adaugat cu succes";
$live = parsepm($shtxt,$sid);
echo "
$live";
}else{
echo "Eroare in baza de date";
}
}else{
$rema = $shoutfl - $tm;
echo "";
echo "Anti-Flood $rema secunde!
Pentru discutii interminabile intrati pe chat!enjoy...
";
}
}
echo "
";
echo "Prim";
echo "
";
$timpul = mysql_fetch_array(mysql_query("SELECT shtime FROM lib3rtymrc_shouts WHERE shouter='".$uid."' order by id desc"));
$timps=time()-$timpul[0];
if(getplusses(getuid_sid($sid))<1500)
{
echo "Ai nevoie de 1500 de puncte pentru a posta mesaje live!";
}else{
$shtxt = $shtxt;
//$uid = getuid_sid($sid);
$shtm = time();
//
$uid = getuid_sid($sid);
$tm = time();
//$antiflood = 1800;/// anti flood time
$lastshout = mysql_fetch_array(mysql_query("SELECT MAX(shtime) FROM lib3rtymrc_shouts WHERE shouter='".$uid."'"));
//$lastshout = mysql_fetch_array(mysql_query("SELECT MAX(shtime) FROM lib3rtymrc_shouts"));
//$shoutfl = $lastshout[0]+$antiflood;
if(!ismod($sid))
{
$shoutfl = $lastshout[0]+getliveaf();
}
if(ismod($uid))$shoutfl=0;
if($shoutfl<$tm)
{
//
$res = mysql_query("INSERT INTO lib3rtymrc_shouts SET shout='".$shtxt."', shouter='".$uid."', shtime='".$shtm."'");
if($res)
{
$shts = mysql_fetch_array(mysql_query("SELECT shouts from lib3rtymrc_users WHERE id='".$uid."'"));
$shts = $shts[0]+1;
mysql_query("UPDATE lib3rtymrc_users SET shouts='".$shts."' WHERE id='".$uid."'");
echo "Mesaj live adaugat cu succes";
$live = parsepm($shtxt,$sid);
echo "
$live";
}else{
echo "Eroare in baza de date";
}
}else{
$rema = $shoutfl - $tm;
echo "";
echo "Anti-Flood $rema secunde!
Pentru discutii interminabile intrati pe chat!enjoy...
";
}
}
echo "
";
echo "Prim";
echo "
";
if($cow[0]!=$uid)
{
echo "Acesta nu este clubul tau!";
}else{
$shtxt = $shtxt;
//$uid = getuid_sid($sid);
$shtm = time();
$res = mysql_query("INSERT INTO lib3rtymrc_announcements SET antext='".$antx."', clid='".$clid."', antime='".$shtm."'");
if($res)
{
echo "Anunt adaugat!";
}else{
echo "Eroare in baza de date";
}
}
echo "
";
echo "Prim";
echo "
";
$vb = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_brate WHERE uid='".$uid."' AND blogid='".$bid."'"));
if($vb[0]==0)
{
$res = mysql_query("INSERT INTO lib3rtymrc_brate SET uid='".$uid."', blogid='".$bid."', brate='".$brate."'");
if($res)
{
echo "Jurnal votat cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Ai mai votat deja acest jurnal
";
}
echo "
";
echo "";
echo "Prim";
echo "
";
if(candelgb(getuid_sid($sid), $mid))
{
$res = mysql_query("DELETE FROM lib3rtymrc_gbook WHERE id='".$mid."'");
if($res)
{
echo "Mesaj sters din cartea de vizita
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Nu poti sterge acest mesaj";
}
echo "
";
echo "";
echo "Prim";
echo "
";
$itemowner = mysql_fetch_array(mysql_query("SELECT uid FROM lib3rtymrc_vault WHERE id='".$vid."'"));
if(ismod(getuid_sid($sid))||getuid_sid($sid)==$itemowner[0])
{
$res = mysql_query("DELETE FROM lib3rtymrc_vault WHERE id='".$vid."'");
if($res)
{
echo "Element sters de la descarcari
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Nu poti sterge acest element de la descarcari";
}
echo "
";
echo "";
echo "Prim";
echo "
";
if(candelbl(getuid_sid($sid), $bid))
{
$res = mysql_query("DELETE FROM lib3rtymrc_blogs WHERE id='".$bid."'");
if($res)
{
echo "Jurnal sters
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Nu poti sterge acest jurnal";
}
echo "
";
echo "";
echo "Prim";
echo "
";
$pinfo = mysql_fetch_array(mysql_query("SELECT reported FROM lib3rtymrc_manele WHERE id='".$vid."'"));
if($pinfo[0]=="0")
{
$str = mysql_query("UPDATE lib3rtymrc_manele SET reported='1' WHERE id='".$vid."' ");
if($str)
{
echo "Element descarcari raportat moderatorilor cu succes";
}else{
echo "Nu poti raporta acest element pentru moment";
}
}else{
echo "Acest Element descarcari este deja raportat";
}
echo "
";
echo "";
echo "Prim";
echo "
";
$pinfo = mysql_fetch_array(mysql_query("SELECT reported FROM lib3rtymrc_posts WHERE id='".$pid."'"));
if($pinfo[0]=="0")
{
$str = mysql_query("UPDATE lib3rtymrc_posts SET reported='1' WHERE id='".$pid."' ");
if($str)
{
echo "Post raportat moderatorilor cu succes";
}else{
echo "Nu poti raporta postul pentru moment";
}
}else{
echo "Acest Post este deja raportat";
}
echo "
";
echo "";
echo "Prim";
echo "
";
$pinfo = mysql_fetch_array(mysql_query("SELECT reported FROM lib3rtymrc_topics WHERE id='".$tid."'"));
if($pinfo[0]=="0")
{
$str = mysql_query("UPDATE lib3rtymrc_topics SET reported='1' WHERE id='".$tid."' ");
if($str)
{
echo "Topic raportat moderatorilor cu succes";
}else{
echo "Nu poti raporta topicul pentru moment";
}
}else{
echo "Topicul acesta este deja raportat";
}
echo "
";
echo "";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$unick = getnick_uid($uid);
$tnick = getnick_uid($who);
if($todo=="add")
{
if(budres($uid,$who)!=3){
if(arebuds($uid,$who))
{
echo "$tnick este deja prietenul tau
";
}else if(budres($uid, $who)==0)
{
$res = mysql_query("INSERT INTO lib3rtymrc_buddies SET uid='".$uid."', tid='".$who."', reqdt='".time()."'");
if($res)
{
if(automsgs($who))
{
$msg = "".getnick_uid($uid)." ti-a trimis o cerere de prietenie![br/][i]P.S.:acesta este un pm automat,va rugam sa nu raspundeti la el![/i]";
echo pmautomat($msg, $who);
}
echo "O cerere a fost trimisa catre $tnick pentru a fi adugat in lista ta de prieteni
";
}else{
echo "Nu poti aduce pe $tnick in lista ta de prieteni
";
}
}
else if(budres($uid, $who)==1)
{
$res = mysql_query("UPDATE lib3rtymrc_buddies SET agreed='1' WHERE uid='".$who."' AND tid='".$uid."'");
if($res)
{
if(automsgs($who))
{
$msg = "".getnick_uid($uid)." te-a acceptat in lista lui de prieteni[br/][i]P.S.:acesta este un pm automat,va rugam sa nu raspundeti la el![/i]";
echo pmautomat($msg, $who);
}
echo "$tnick adaugat in lista de prieteni cu succes
";
}else{
echo "Nu poti aduce pe $tnick in lista ta de prieteni
";
}
}
else{
echo "Nu poti aduce pe $tnick in lista ta de prieteni
";
}
}else{
echo "Nu poti aduce pe $tnick in lista ta de prieteni
";
}
}else if($todo="del")
{
$res= mysql_query("DELETE FROM lib3rtymrc_buddies WHERE (uid='".$uid."' AND tid='".$who."') OR (uid='".$who."' AND tid='".$uid."')");
if($res)
{
if(automsgs($who))
{
$msg = "".getnick_uid($uid)." te-a sters din lista lui de prieteni[br/][i]P.S.:acesta este un pm automat,va rugam sa nu raspundeti la el![/i]";
echo pmautomat($msg, $who);
}
echo "$tnick sters din lista de prieteni
";
}else{
echo "Nu poti sterge pe $tnick din lista ta de prieteni
";
}
}
echo "";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET budmsg='".$mesaj."' WHERE id='".$uid."'");
if($res)
{
echo "Status setat cu succes
";
}else{
echo "Nu poti actualiza Statustul
";
}
echo "
";
echo "";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$avlnk = mysql_fetch_array(mysql_query("SELECT avlink FROM lib3rtymrc_avatars WHERE id='".$avid."'"));
$res = mysql_query("UPDATE lib3rtymrc_users SET avatar='".$avlnk[0]."' WHERE id='".$uid."'");
if($res)
{
echo "Avatar Selectat
";
}else{
echo "Eroare in baza de date!
";
}
echo "
";
echo "";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET chmood='".$cmid."' WHERE id='".$uid."'");
if($res)
{
echo "Chef selectat
";
}else{
echo "Eroare in baza de date!
";
}
echo "
";
echo "";
echo "Camera chat
";
echo "";
echo "Meniu chat
";
echo "";
echo "Prim";
echo "
";
$ncl = mysql_query("UPDATE lib3rtymrc_users SET automsgs='1' WHERE id='".$uid."'");
echo "Mesaje automate activate cu succes
";
echo "
"; echo ""; echo "Prim"; echo "
"; echo "";
$ncl = mysql_query("UPDATE lib3rtymrc_users SET automsgs='0' WHERE id='".$uid."'");
echo "Mesaje automate dezactivate cu succes
";
echo "
"; echo ""; echo "Prim"; echo "
"; echo "";
//$uid = getuid_sid($sid);
$gpsf = mysql_fetch_array(mysql_query("SELECT gplus FROM lib3rtymrc_users WHERE id='".$uid."'"));
$gpst = mysql_fetch_array(mysql_query("SELECT gplus FROM lib3rtymrc_users WHERE id='".$who."'"));
if($gpsf[0]>=$ptg){
$gpsf = $gpsf[0]-$ptg;
$gpst = $gpst[0]+$ptg;
$res = mysql_query("UPDATE lib3rtymrc_users SET gplus='".$gpst."' WHERE id='".$who."'");
if($res)
{
$res = mysql_query("UPDATE lib3rtymrc_users SET gplus='".$gpsf."' WHERE id='".$uid."'");
echo "Plusuri joc actualizate cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Nu ai destule plusuri joc pentru a da altcuiva
";
}
echo "
";
echo "";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
if(getplusses($uid)>=500)
{
$noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_clubs WHERE owner='".$uid."'"));
if($noi[0]<3)
{
if(($clnm=="")||($clds=="")||($clrl==""))
{
echo "Verifica daca ai completat, nume club, descriere si reguli";
}else{
$nmex = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_clubs WHERE name LIKE '".$clnm."'"));
if($nmex[0]>0)
{
echo "Nume club deja exista";
}else{
$res = mysql_query("INSERT INTO lib3rtymrc_clubs SET name='".$clnm."', owner='".$uid."', description='".$clds."', rules='".$clrl."', logo='".$cllg."', plusses='0', created='".time()."'");
if($res)
{
$clid = mysql_fetch_array(mysql_query("SELECT id FROM lib3rtymrc_clubs WHERE owner='".$uid."' AND name='".$clnm."'"));
echo "Felicitari, ai propriul club, propriile reguli, propriul mesaj de bun venit, camera de chat, anunturi, forum si 50 de puncte club";
mysql_query("INSERT INTO lib3rtymrc_clubmembers SET uid='".$uid."', clid='".$clid[0]."', accepted='1', points='50', joined='".time()."'");
//$ups = getplusses($uid);
//$ups += 5;
//mysql_query("UPDATE lib3rtymrc_users SET plusses='".$ups."' WHERE id='".$uid."'");
$fnm = $clnm;
$cnm = $clnm;
mysql_query("INSERT INTO lib3rtymrc_forums SET name='".$fnm."', position='0', cid='0', clubid='".$clid[0]."'");
mysql_query("INSERT INTO lib3rtymrc_rooms SET name='".$cnm."', pass='', static='1', mage='0', chposts='0', perms='0', censord='0', freaky='0', lastmsg='".time()."', clubid='".$clid[0]."'");
}else{
echo "Eroare in baza de date!";
}
}
}
}else{
echo "Ai deja 3 cluburi";
}
}else{
echo "Nu mai poti adauga alt club";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$judg = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM lib3rtymrc_judges WHERE uid='".getuid_sid($sid)."'"));
$gpst = mysql_fetch_array(mysql_query("SELECT battlep FROM lib3rtymrc_users WHERE id='".$who."'"));
if(ismod(getuid_sid($sid))||$judg[0]>0)
{
if ($giv=="1")
{
$gpst = $gpst[0]+$ptg;
}else{
$gpst = $gpst[0]-$ptg;
if($gpst<0)$gpst=0;
}
$res = mysql_query("UPDATE lib3rtymrc_users SET battlep='".$gpst."' WHERE id='".$who."'");
if($res)
{
$vnick = getnick_uid($who);
if ($giv=="1")
{
$ms1 = " Aduse $ptg puncte la ";
}else{
$ms1 = " Retrase $ptg puncte de la ";
}
mysql_query("INSERT INTO lib3rtymrc_mlog SET action='bpoints', details='".getnick_uid(getuid_sid($sid))." $ms1 $vnick', actdt='".time()."'");
echo "Puncte batalie actualizate cu succes
";
}else{
echo "Eroare in baza de date!
";
}
}else{
echo "Nu poti face asta
";
}
echo "
";
echo "";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$tnick = getnick_uid($who);
if($todo=="add")
{
if(ignoreres($uid, $who)==1)
{
$res= mysql_query("INSERT INTO lib3rtymrc_ignore SET name='".$uid."', target='".$who."'");
if($res)
{
echo "$tnick a fost adaugat cu succes in lista de ignorati
";
}else{
echo "Eroare actualizand baza de date
";
}
}else{
echo "Nu poti aduce pe $tnick in lista de ignorati
";
}
}else if($todo="del")
{
if(ignoreres($uid, $who)==2)
{
$res= mysql_query("DELETE FROM lib3rtymrc_ignore WHERE name='".$uid."' AND target='".$who."'");
if($res)
{
echo "$tnick a fost sters din lista de ignorati
";
}else{
echo "Eroare actualizand baza de date
";
}
}else{
echo "$tnick nu este ignorat de tine
";
}
}
echo "
";
echo "Lista ignorati
";
echo "";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET avatar='".$savat."', email='".$semail."', site='".$usite."', birthday='".$ubday."', location='".$uloc."', signature='".$usig."', sex='".$usex."' WHERE id='".$uid."'");
if($res)
{
echo "Profilul tau a fost actualizat cu succes
";
}else{
echo "Eroare in actualiarea profilului
";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET hvia='".$acts."' WHERE id='".$uid."'");
if($res)
{
echo "Vizibilitate emotii actualizata cu succes
";
echo "";
echo "Setari
";
}else{
echo "Eroare in actualiarea profilului
";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET chef='".$acts."' WHERE id='".$uid."'");
if($res)
{
echo "Chef setat cu succes in lista de conectati
";
echo "";
echo "Setari
";
}else{
echo "Eroare in actualiarea profilului
";
}
echo "
";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET setavatar='".$acts."' WHERE id='".$uid."'");
if($res)
{
echo "Avatar actualizat cu succes
";
echo "";
echo "Setari
";
}else{
echo "Eroare in actualiarea profilului
";
}
echo "
";
echo "Prim";
echo "
";
$uid = getuid_sid($sid);
$res = mysql_query("UPDATE lib3rtymrc_users SET alerte='".$acts."' WHERE id='".$uid."'");
if($res)
{
echo "Alerte activate doar pentru prieteni
";
echo "";
echo "Setari
";
}else{
echo "Eroare in actualiarea alertelor
";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$alerte = mysql_query("UPDATE lib3rtymrc_users SET popmsg='".$popmsg."' WHERE id='".$uid."'");
if($alerte)
{
echo "Alerte setate cu succes
";
echo "";
echo "Setari
";
}else{
echo "Eroare in setarea alertelor
";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
$alerte = mysql_query("UPDATE lib3rtymrc_users SET pmmsg='".$pmmsg."' WHERE id='".$uid."'");
if($alerte)
{
echo "PM-uri setate cu succes
";
echo "";
echo "Setari
";
}else{
echo "Eroare in setarea Pm-urilor
";
}
echo "
";
echo "Prim";
echo "
";
//$uid = getuid_sid($sid);
if($npwd!=$cpwd)
{
echo "Parolele nu coincid
";
}else if($epwd!=$pwd[0]){
echo "Vechea parola este incorecta
";
}else if((strlen($npwd)<4) || (strlen($npwd)>15)){
echo "Parola trebuie sa contina intre 4 si 15 caractere
";
}else{
$pwd = md5($npwd);
$res = mysql_query("UPDATE lib3rtymrc_users SET pass='".$pwd."' WHERE id='".$uid."'");
if($res)
{
echo "Parola Schimbata cu succes
";
}else{
echo "Eroare in baza de date
";
}
}
echo "
Prim";
echo "
";
echo "Nu stiu cum ai ajuns aici dar nu ai ce vedea!
";
echo "";
echo "Prim";
echo "