Navigacija

Vartotojų tinkle

Prisijungusių svečių: 41
Prisijungusių narių: 0
Prisijungusių narių nėra

Registruoti nariai: 25,952
Naujausias narys: tomeem

Naujausi straipsniai

Paskutiniai nariai

tomeem 3 dienos
Reikalas 1 savaitė
weberiz 3 savaitės
mRokass 6 savaitės
kartoonas 7 savaitės
iaescortsmap 7 savaitės
ozzWANTED 8 savaitės
grunskiz10 savaitės
Bruksnys10 savaitės
illusion10 savaitės
ordo11 savaitės
Jurgaila12 savaitės
originalcs1612 savaitės
Rytis13 savaitės
halis14 savaitės
junkus17 savaitės
morlis17 savaitės
Majakas18 savaitės
andsoft19 savaitės
picolee9021 savaitės

Informacija:


OS: Unknown
Naršyklė: Nežinoma
IP: 18.217.220.114
Naujienų: 529
Straipsnių: 235
Temų: 52,584
Postų: 522,522
Postų pask. parą: 0
Shout'ų pask. parą: 0
P.S.C. pask. parą: 0
Nuorodų kataloge: 13

Lankomumo Statistika

Peržiūrų šiandien: 22

Iš viso peržiūrų: 22948724

Prisijungti

REGISTRUOTIS
Nario vardas

Slaptažodis



Pamiršai slaptažodį?
Paprašyk naujo

Aktyvuoti save

Šaukykla

Jei norite rašyti žinutes, turite prisijungti.

ozzWANTED
2024 Sau. 17 01:01:00
Desperatiškus komentarus šaukykloje su accountu po mėnesio prasibuvimo, ištryniau. Pasaulis ir taip juodas. Įjungiam šviesą, prašviesės. šypsosi

Majakas
2023 Gru. 10 19:12:39
Negaliu patikėti jog žinutės/pranešimai visi yra nuo 2008 m akinanti šypsen

Žmogus
2023 Rugs. 7 21:09:14
O gal BloodKiller pasijungs?

Apocal
2023 Rugs. 2 18:09:23
Nu davai nuveikiam kažką akinanti šypsen. Prisijungti kada visi čia akinanti šypsen.

Apocal
2023 Rugs. 2 00:09:18
Šiaip atėjau pažiūrėti ar dar lopas nesby yra ar koks ten buvo.

Šaukyklos archyvas

Apklausa

Ar esate patenkinti lietuviško vertimo kokybe?

Taip!

Taip, bet yra ką taisyti (parašysiu komentaruose)

Ne

Norėdamas balsuoti turite prisijungti.
Archyvas
Reklama 400x60
Members poll panel
Forumas | PHP-Fusion, WordPress, Shopify, PHP ir MySQL (PROGRAMAVIMAS) | Bendri PHP-F klausimai

Autorius: Haked Peržiūrų: 4263      Spausdinti temą
2008 Lie. 26 15:07:40          1 žinutė iš 14
Spausdinti pranešimą
kaip padaryti, kad svečiai galėtu balsuoti?

štai kodas:

<?php
/*---------------------------------------------------+
| PHP-Fusion 6 Content Management System
+----------------------------------------------------+
| Copyright © 2002 - 2006 Nick Jones
| http://www.php-fusion.co.uk/
+----------------------------------------------------+
| Released under the terms & conditions of v2 of the
| GNU General Public License. For details refer to
| the included gpl.txt file or visit http://gnu.org
+----------------------------------------------------*/
if (!defined("IN_FUSION")) { header("Location: ../../index.php"); exit; }
if (isset($poll_id) && !isNum($poll_id)) fallback("index.php");

openside_header($locale['100']);
if (isset($_POST['cast_vote'])) {
   $result = dbquery("SELECT * FROM ".$db_prefix."poll_votes WHERE vote_user='".$userdata['user_id']."' AND poll_id='$poll_id'");
   if (dbrows($result) == "0") {
      $result = dbquery("INSERT INTO ".$db_prefix."poll_votes (vote_user, vote_opt, poll_id) VALUES ('".$userdata['user_id']."', '$voteoption', '$poll_id')");
      header("Location: ".FUSION_SELF.(FUSION_QUERY ? "?".FUSION_QUERY : ""));
   }
}
$result = dbquery("SELECT * FROM ".$db_prefix."polls ORDER BY poll_started DESC LIMIT 1");
if (dbrows($result) != 0) {
   $data = dbarray($result);
   $poll_title = $data['poll_title'];
   for ($i=0; $i<=9; $i++) {
      if ($data["poll_opt_".$i]) $poll_option[$i] = $data["poll_opt_".$i];
   }
   if (iMEMBER) $result2 = dbquery("SELECT * FROM ".$db_prefix."poll_votes WHERE vote_user='".$userdata['user_id']."' AND poll_id='".$data['poll_id']."'");
   if ((!iMEMBER || !dbrows($result2)) && $data['poll_ended'] == 0) {
      $poll = ""; $i = 0; $num_opts = count($poll_option);
      while ($i < $num_opts) {
         $poll .= "<input type='radio' name='voteoption' value='$i'> $poll_option[$i]<br><br>\n";
         $i++;
      }
      echo "<form name='voteform' method='post' action='".FUSION_SELF.(FUSION_QUERY ? "?".FUSION_QUERY : "")."'>
<b><span style='color:#555'>$poll_title</span></b><br><br>
$poll<center><input type='hidden' name='poll_id' value='".$data['poll_id']."'>\n";
      if (iMEMBER) {
         echo "<input type='submit' name='cast_vote' value='".$locale['101']."' class='button_2'></center>\n";
      } else {
         echo $locale['102']."</center>\n";
      }
      echo "</form>\n";
   } else {
      $poll =  ""; $i = 0; $num_opts = count($poll_option);
      $poll_votes = dbcount("(vote_opt)", "poll_votes", "poll_id='".$data['poll_id']."'");
      while ($i < $num_opts) {
         $num_votes = dbcount("(vote_opt)", "poll_votes", "vote_opt='$i' AND poll_id='".$data['poll_id']."'");
         $opt_votes = ($poll_votes ? number_format(100 / $poll_votes * $num_votes) : 0);
         $poll .= "<div>".$poll_option[$i]."</div>
<div><img src='".THEME."images/pollbar.gif' alt='".$poll_option[$i]."' height='12' width='$opt_votes' class='poll'></div>
<div>".$opt_votes."% [".$num_votes."/".$poll_votes."]</div><br>\n";
         $i++;
      }
      echo "<b><span style='color:#555'>".$poll_title."</span></b><br><br>
$poll
<center>";
      $result = dbquery("SELECT * FROM ".$db_prefix."polls");
      if (dbrows($result) > 1) {
         echo "<img src='".THEME."images/bullet.gif' alt=''>
<a href='".INFUSIONS."member_poll_panel/polls_archive.php' class='side'>".$locale['108']."</a> <img src='".THEME."images/bulletb.gif' alt=''>\n";
      }
      echo "</center>\n";
   }
} else {
   echo "<center>".$locale['004']."</center>\n";
}
closeside_header();
?>



2008 Lie. 26 15:07:46          2 žinutė iš 14
Spausdinti pranešimą
Imk.


2008 Lie. 26 15:07:01          3 žinutė iš 14
Spausdinti pranešimą
if(iMEMBER) nieko nesako?

ex best admin!
2008 Lie. 26 15:07:46          4 žinutė iš 14
Spausdinti pranešimą
o ką keisti vietoj member?
2008 Lie. 26 15:07:11          5 žinutė iš 14
Spausdinti pranešimą
ramon tau jau pilna moda dave juokiasi

ex best admin!
2008 Lie. 26 15:07:25          6 žinutė iš 14
Spausdinti pranešimą
man reikia būtent to aš naudoju tokia tema shabby tai ten ta netinka man reikia šita suredaguoti
2008 Lie. 26 15:07:23          7 žinutė iš 14
Spausdinti pranešimą
Ten kur davė bus viskas taip pat, skirtumas, kad galės balsuoti ir svečiai.

Kiekvienam žmogui yra skirta dovana, tik ne kiekvienas sugeba ją atrasti.
2008 Lie. 26 15:07:25          8 žinutė iš 14
Spausdinti pranešimą
nu man išsikraipo kai ta įdedu ką reikia keisti, kad būtu svečiams tame if members
2008 Lie. 26 16:07:11          9 žinutė iš 14
Spausdinti pranešimą
GAl guest nežinojuokiasi


Redagavo Taskalas 2008 Lie. 26 16:07:32
2008 Lie. 26 16:07:26          10 žinutė iš 14
Spausdinti pranešimą
Gal panaudok IP_poll panel kurią davė ramon ir būsi laimingas.
2008 Lie. 26 18:07:59          11 žinutė iš 14
Spausdinti pranešimą
nu man neiseina ten tai temai yra special member poll

va mano theme.php

<?php
if (!defined("IN_FUSION")) { header("Location: ../../index.php"); exit; }
require_once INCLUDES."theme_functions_include.php";

// theme settings
$body_text = "#C0B5B3";
$body_bg = "#F7F7EF";
$theme_width = "715";
$theme_width_l = "220";
$theme_width_r = "220";

function render_header($header_content) {

global $theme_width,$settings,$db_prefix,$locale,$data,$userdata,$user_data,$poll_id,$voteoption,$poll_option,$itemsubject,$aidlink;

echo "<table align='center' cellspacing='0' cellpadding='0' width='$theme_width'>
<tr>
<td>
<table cellpadding='0' cellspacing='0' width='100%' class='navigation'>
<tr><td class='header'></td></tr>
</table>
<table cellpadding='0' cellspacing='0' width='100%' class='navigation'>
<tr>
<td align='center'>".showsublinks("","white")."</td>
</tr>
</table>\n";

echo "<table cellpadding='0' cellspacing='0' width='330'>\n<tr>
<td class='line'><marquee scrollamount='1' scrolldelay='50' onmouseover='this.stop()' onmouseout='this.start()'>".stripslashes($settings['description'])."</marquee</td>
</tr>
</table>\n";

echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>
<td class='sub'></td>
</tr>
</table>\n";

echo "<table cellpadding='0' cellspacing='0' width='$theme_width' class='paneles'>\n<tr>
<td align='left' width='120'>";
include THEME."user_info_panel.php";
echo "</td>
<td align='center' width='97'><br><br>";
echo ($userdata['user_avatar'] ? "<img src='".IMAGES."avatars/".$userdata['user_avatar']."' width='70' height='70'></center><br>\n" : "<center><a href='".BASEDIR."edit_profile.php'><img src='".THEME."images/avatar.gif' border='0' width='70' height='70'></a></center>\n")."";
echo "</td>
<td align='center' width='306'>";
include THEME."forum_threads_panel.php";
echo "</td>
<td align='center' width='195'>";
include THEME."members_poll_panel.php";
echo "</td>
</tr>
</table><br>\n";

echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n";

}

function render_footer($license=false) {

global $theme_width,$settings;

echo "</tr>\n</table>\n";
echo "<table align='center' cellpadding='0' cellspacing='0' width='$theme_width' class='footer'>
<tr>
<td width='92'><a href='news.php?readmore=".$info['news_id']."' style='color:#000;'>PHP-Fusion</a> </td>
<td width='530'> ".stripslashes($settings['footer'])."</td>
<td width='93'><img src='".THEME."images/made_by.png'>&nbsp;&nbsp;<a href='http://www.emotive.in/' target='_blank'><img src='".THEME."images/emotive.png' border='0'></a></td>
</tr>
</table>
</td>
</tr>
</table>\n";

}

function render_news($subject, $news, $info) {

global $aidlink,$item_type;
$res = "";

echo "<table align='center' cellpadding='0' cellspacing='0' width='485'>
<tr>
<td class='capmain'>$subject<br><span style='font-size : 10px;font-weight : normal;'>parašė: <a href='profile.php?lookup=".$info['user_id']."' style='color:#EBE2D1;'>".$info['user_name']."</a>, ".showdate("shortdate", $info['news_date'])."</span></td>
</tr>
<tr>
<td class='main-body'>$news</td>
</tr>
<tr>
<form name='editnews".$info['news_id']."' method='post' action='".ADMIN."news.php".$aidlink."&amp;news_id=".$info['news_id']."'>
<td align='right' class='news-footer'>komentarų: ".$info['news_comments']." - <a href='news.php?readmore=".$info['news_id']."' style='color:#E6DED1;'>žiūrėti</a> ";
    if (iADMIN && checkrights(N)) {
echo "- <input type='hidden' name='edit' value='edit'><a href='javascript:document.editnews".$info['news_id'].".submit();' style='color:#E6DED1;'>redaguoti</a>";
}
echo "</td>
</form>
</tr>
</table>\n";

}

function render_article($subject, $article, $info) {

global $aidlink,$item_type;
$res = "";
   
echo "<table align='center' cellpadding='0' cellspacing='0' width='485'>
<tr>
<td class='capmain'>$subject<br><span style='font-size : 10px;font-weight : normal;'>parašė: <a href='profile.php?lookup=".$info['user_id']."' style='color:#EBE2D1;'>".$info['user_name']."</a>, ".showdate("shortdate", $info['article_date'])."</span></td>
</tr>
<tr>
<td class='main-body'>
".($info['article_breaks'] == "y" ? nl2br($article) : $article)."
</td>
</tr>
<tr>
<form name='editarticle".$item_id."' method='post' action='".ADMIN."articles.php".$aidlink."&amp;article_id=".$item_id."'>
<td class='news-footer'>komentarų: ".$info['article_comments']." - <a href='print.php?type=A&amp;item_id=".$info['article_id']."' style='color:#E6DED1;'>spausdinti</a> ";
    if (iADMIN && checkrights(A)) {
echo "- <input type='hidden' name='edit' value='edit'><a href='javascript:document.editarticle".$info['articles_id'].".submit();' style='color:#E6DED1;'>redaguoti</a>";
}

echo "</td>
</form>
</tr>
</table>\n";

}

function opentable($title) {

echo "<table align='center' cellpadding='0' cellspacing='0' width='485'>
<tr>
<td class='capmain'>$title</td>
</tr>
<tr>
<td class='main-body'>\n";

}

function closetable() {

echo "</td>
</tr>
<td align='center' class='news-footer'></td>
</table>\n";

}

function openside($title) {
   
echo "<table align='center' cellpadding='0' cellspacing='0' width='220'>
<tr>
<td class='scapmain'>$title</td>
</tr>
<tr>
<td class='side-body'>\n";

}

function closeside() {

echo "</td>
</tr>
<tr><td><img src='".THEME."images/scapmain_bot.gif'></td></tr>
</table>\n";
tablebreak();

}

function openside_header($title) {
   
echo "<table align='center' cellpadding='0' cellspacing='0'>
<tr>
<td class='side-body-header'>\n";

}

function closeside_header() {

echo "</td>
</tr>
</table>\n";
tablebreak();

}

function opensidex($title,$state="on") {

$boxname = str_replace(" ", "", $title);
echo "<table align='center' cellpadding='0' cellspacing='0' width='220'>
<tr>
<td class='scapmain'>$title</td>
<td class='scapmain' align='right'>".panelbutton($state,$boxname)."</td>
</tr>
<tr>
<td colspan='2' class='side-body'>
<div id='box_$boxname'".($state=="off"?" style='display:none'":"").">\n";

}

function closesidex() {

echo "</div>
</td>
</tr>
<tr><td><img src='".THEME."images/scapmain_bot.gif'></td></tr>
</table>\n";
tablebreak();

}

function tablebreak() {

echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n<td height='5'></td>\n</tr>\n</table>\n";

}
?>




2008 Lie. 26 19:07:15          12 žinutė iš 14
Spausdinti pranešimą
Pire ko ta theme.php ir iš kur ištraukei special member poll?
2008 Lie. 26 20:07:15          13 žinutė iš 14
Spausdinti pranešimą
[b]MAnjack parašė:
Pire ko ta theme.php ir iš kur ištraukei special member poll?


shabby themei yra memberpoll po headeriu pritvirtintas, delto ir kisa cia theme.php nors siaip yra parasyta
include THEME."members_poll_panel.php";


tai ta panel tegu deda


Redagavo sydow 2008 Lie. 26 20:07:24
2008 Rugs. 5 12:09:29          14 žinutė iš 14
Spausdinti pranešimą
member pollsql cia jo? man sql neideda kazko...

Create database tables.
$inf_newtable_[1] = "ip_polls (
      poll_id smallint(5) unsigned NOT NULL auto_increment,
      poll_title varchar(200) NOT NULL default '',
      poll_opt_0 varchar(200) NOT NULL default '',
      poll_opt_1 varchar(200) NOT NULL default '',
      poll_opt_2 varchar(200) NOT NULL default '',
      poll_opt_3 varchar(200) NOT NULL default '',
      poll_opt_4 varchar(200) NOT NULL default '',
      poll_opt_5 varchar(200) NOT NULL default '',
      poll_opt_6 varchar(200) NOT NULL default '',
      poll_opt_7 varchar(200) NOT NULL default '',
      poll_opt_8 varchar(200) NOT NULL default '',
      poll_opt_9 varchar(200) NOT NULL default '',
      poll_votes_0 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_1 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_2 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_3 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_4 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_5 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_6 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_7 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_8 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_9 smallint(5) unsigned NOT NULL NULL default '0',
      poll_ips text NOT NULL default '',
      poll_started int(10) unsigned NOT NULL default '',
      poll_ended int(10) unsigned NOT NULL default '0',
      PRIMARY KEY (poll_id)
   ) TYPE=MyISAM;";





Per sql kaip teisynga forma turetu ardoditi kad pavyktu ja tiesiogiai idet?

Create tables
"ip_polls (
      poll_id smallint(5) unsigned NOT NULL auto_increment,
      poll_title varchar(200) NOT NULL default '',
      poll_opt_0 varchar(200) NOT NULL default '',
      poll_opt_1 varchar(200) NOT NULL default '',
      poll_opt_2 varchar(200) NOT NULL default '',
      poll_opt_3 varchar(200) NOT NULL default '',
      poll_opt_4 varchar(200) NOT NULL default '',
      poll_opt_5 varchar(200) NOT NULL default '',
      poll_opt_6 varchar(200) NOT NULL default '',
      poll_opt_7 varchar(200) NOT NULL default '',
      poll_opt_8 varchar(200) NOT NULL default '',
      poll_opt_9 varchar(200) NOT NULL default '',
      poll_votes_0 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_1 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_2 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_3 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_4 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_5 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_6 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_7 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_8 smallint(5) unsigned NOT NULL NULL default '0',
      poll_votes_9 smallint(5) unsigned NOT NULL NULL default '0',
      poll_ips text NOT NULL default '',
      poll_started int(10) unsigned NOT NULL default '',
      poll_ended int(10) unsigned NOT NULL default '0',
      PRIMARY KEY (poll_id)
   ) TYPE=MyISAM;";



Bet kažko nepavyksta...

http://Cyberwonderland.tk/
Smalsumas žudo?
Nesikankink!!
Redagavo Lietuvos_pilietis 2008 Rugs. 5 13:09:27
Peršokti į forumą: