
Originally Posted by
sananebak
no i think ,
Pokemon types, the advantages of each?type of pokemon, pokemon type superiority. Look carefully. No types of pokemon.
I want to be sure. What does this database?
annval = attack
verdediger = defender
krachtiger = powerful
here, you got it by your self, i was wrong, i think its how the damage calculating when you battle with x type against y type.
new admin function - sending suprise + message to all players
including only premium days, silver and gold, add what you want by your own :)
PHP Code:
<?
include("includes/security.php");
//Admin controle
if($gebruiker['admin'] < 1) header('location: index.php?page=home');
//Send
if(isset($_POST['send'])){
$bericht = $_POST['tekst'];
$onderwerp = $_POST['onderwerp'];
$pdays = $_POST['pdays'];
$psilver = $_POST['psilver'];
$pgold = $_POST['pgold'];
if(empty($bericht)) {
echo '<div class="red"><img src="http://forum.ragezone.com/images/icons/red.png"> No text entered.</div>';
}
if(empty($onderwerp)) {
echo '<div class="red"><img src="http://forum.ragezone.com/images/icons/red.png"> No topic entered.</div>';
}
elseif(!preg_match('/[A-Za-z0-9_]+$/',$onderwerp)) {
echo '<div class="red"><img src="http://forum.ragezone.com/images/icons/red.png"> The topic may not contain those characters.</div>';
}
else{
$speler = mysql_query("SELECT `user_id` FROM `gebruikers`");
mysql_query("UPDATE `gebruikers` SET `premiumaccount`=`premiumaccount`+'".$pdays."', `silver`=`silver`+'".$psilver."', `gold`=`gold`+'".$pgold."'");
while($spelers = mysql_fetch_array($speler)){
$datum = date('Y-m-d H:i:s');
mysql_query("INSERT INTO `berichten` (`datum`, `ontvanger_id`, `afzender_id`, `bericht`, `onderwerp`, `gelezen`)
VALUES ('".$datum."', '".$spelers['user_id']."', '1', '".$bericht."', '".$onderwerp."', 'nee')");
}
echo '<div class="green"><img src="http://forum.ragezone.com/images/icons/green.png"> Suprise was sent successfully!</div>';
}
}
?>
<form method="post">
<center>
<img src="http://icons.iconarchive.com/icons/enhancedlabs/the-real-christmas-05/128/Gift-Box-icon.png"><br />
<h2>Give suprise for everybody!</h2>
<table width="100" border="0">
<tr>
<td id="radio">Click Here</td>
<td><input type="radio" name="ontvanger" id="radio" value="allemaal" onChange=this.form.submit();></td>
</tr>
</table>
</center>
</form>
<?
//Radio
if(isset($_POST['ontvanger'])){
echo '<form method="post">
<table width="600" border="0">
<tr>
<td width="110">Message Topic:</td>
<td width="490"><input type="text" name="onderwerp" class="text_long" value="Your Topic"></td>
</tr>
<tr>
<td width="110">Silver:</td>
<td width="490"><input type="text" name="psilver" class="text_long" value="0"></td>
</tr>
<tr>
<td width="110">Gold:</td>
<td width="490"><input type="text" name="pgold" class="text_long" value="0"></td>
</tr>
<tr>
<td width="110">Premium Days:</td>
<td width="490"><input type="text" name="pdays" class="text_long" value="0"></td>
</tr>
<tr>
<td colspan="2"><textarea class="text_area" rows="15" name="tekst">'.$_POST['tekst'].'</textarea></td>
</tr>
<tr>
<td colspan="2"><input type="hidden" value="'.$_POST['ontvanger'].'" name="ontvanger">
<input type="submit" value="Send Msg & Suprise" name="send" class="button"></td>
</tr>
</table>
</form>';
}
?>