106
Mods & Plugins (Releases & Support) / Re: [MOD] Votes saved in DB
« on: February 12, 2006, 05:29:41 PM »
I have made a plugin so you can view whitch member had voted in witch file.
My programming and my englisch are not good i know.
You can change a lot on this file. (it's a start for me )
This is the code
I enybody has a better code
My programming and my englisch are not good i know.
You can change a lot on this file. (it's a start for me )
This is the code
Code: [Select]
<?php // PLUGIN_TITLE: voted
$nozip = 1;
define('IN_CP', 1);
$root_path = "./../../";
define('ROOT_PATH', $root_path);
require(ROOT_PATH.'admin/admin_global.php');
show_admin_header();
function display_results() {
global $site_db;
$sql = 'SELECT * FROM `4images_voted` LIMIT 0, 30 ';
$result = $site_db->query($sql);
while($row = $site_db->fetch_array($result)){
$user_id = $row["user_id"];
$postcard_date = date("D d M, Y g:i a", $row["postcard_date"]);
$image_id = $row["image_id"];
$image_name = $row["image_name"];
$image_thumb_file = $row["image_thumb_file"];
$cat_id = $row["cat_id"];
$postcard_headline = $row["postcard_headline"];
$postcard_message = $row["postcard_message"];
$postcard_sender_name = $row["postcard_sender_name"];
$postcard_sender_email = $row["postcard_sender_email"];
$postcard_recipient_name = $row["vote"];
$postcard_recipient_email = $row["postcard_recipient_email"];
$cat_id = $row['cat_id'];
$pict_id = get_media_code($row['image_media_file'], $image_id, $cat_id, $row['image_name']);
$image_media_file = get_media_code($row['image_media_file'], $image_id, $cat_id, $row['image_name']);
$template = TEMPLATE_PATH;
echo "
<font color=\"#000000\" size=\"1\"></td>
</tr>
</tbody>
</table></td>
</tr>
</tbody>
</table>
<table border=\"1\">
<tr>
<td height=\"15\" width=\"119\" align=\"center\" bgcolor=\"#E5E5E5\">
<p align=\"center\"><b>Gebruiker</b></td>
<td height=\"15\" width=\"148\" align=\"center\" bgcolor=\"#E5E5E5\"><b>
Cijfer</b></td>
<td height=\"15\" width=\"286\" align=\"center\" bgcolor=\"#E5E5E5\"><b>
Wallpaper</b></td>
</tr>
<tr>
<td height=\"21\" width=\"119\" align=\"center\" bgcolor=\"#F5F5F5\">
<font color=\"#000000\" size=\"2\" face=\"Tahoma\" >$user_id</td>
<td height=\"21\" width=\"148\" align=\"center\" bgcolor=\"#F5F5F5\">
<font face=\"Tahoma\"> <font color=\"#000000\" size=\"2\" >
$postcard_recipient_name</font><font size=\"2\"> </font> <font color=\"#000000\" size=\"1\" >
<a href=\"mailto:$postcard_recipient_email\">
<font color=\"#000000\" size=\"2\">$postcard_recipient_email</a></font></td>
<td height=\"21\" width=\"286\" align=\"center\" bgcolor=\"#F5F5F5\">
<font color=\"#555555\" size=\"2\" face=\"Tahoma\" >
(<a href=\"../../details.php?image_id=$image_id\" target=\"_blank\">ID: $image_id</a>)
</font></td>
</tr>
</table>\n";
END; }
}
display_results();
show_admin_footer();
?>
Yes i change a other plugin to get this.I enybody has a better code