So were coding our own forums for a game system we made an we have the users level setup but now I need to make it do user groups. See the groups are defined by numbers:
0 - banned
1 - registered
2 - donator
3 - mod
4 - admin
5 - owner
I have this setup to define ranks
$rankstring = "<b><font color='#336699'>";
$row=update_lastVisit($_SESSION["user"][0]);
$x = 1;
while ( $whosonline = mysql_fetch_array( $res ) ) {
if ( $x != 1 ) {
echo ", ";
}
echo "<a href="member.php?id=$whosonline[id]">$rankstring$whosonline[name]</b></font></a></strike>";
$x++;
}
I need to know how to make it MySql read the row for the level and if there in that group then make their name that color. Like for admins something like
if user level is 5 then $rankstring = "html code for admin color";
and have that set ONLY admins as that color and not the other groups. How would I do it like that? The row that the usergroups are read from is 5 if that helps. Can someone help quickly?
division gives infinity anser
int main(){ int z=0; int i=1/z; cout<<i;}It doesn't throw any error in Visual Studio 2008. .......What setting one has to change so that it will show runtime error in VS 2008.....
Bluetooth RSSI & VIsta
Okie I got 4 Bluetooth adapters, a DBT-120 by Dlink, A Zonet Microsoft Bluetooth which is what I used with 32Feet and another TOS Bluetooth Adapter, and I got a 1000HE by Asus which has Broadcom
error reporting
hey everyoneI have a production server in which I want error reporting but only on some pagesI haveini_set('display_errors', 1);ini_set('log_errors', 1);ini_set('error_log',
parse error
Parse error: syntax error, unexpected '[', expecting ')' in /Users/admin/Sites/phptest/array.php on line 5 Code: <?phpfunction shippingPrice($zone,$weight){ $ground = array(2 => array
Form submissing with PHP and JQuery/Ajax
I have searched everywhere, but cannot find a solution for this... I have worked all day trying to get my form to work with jquery. It works to a point.So, I have my Form open up in a Jquery Modal
CHMOD script
Hi,I need a script to read all files in a folder and set to 777.Can anyone help out please?
Sending an SMS Message with ASP.NET
Often times it may be a requirement for your web application to send an SMS message. Such examples would be reminders, password resetting, and spam.Q: Can I have some code to send an SMS message?A:
PHP Redirecting
Hello everyone. Is there a way to redirect people to pages within a statement in PHP? Since there is output before this redirect i cant use the header function.Thnx for your time
What makes a script your own?
If someone finds a login script online, and changes some variable names around and some other minor adjustments. Is that considered there own script? What would define a script as being yours? I
Else statement screws up all css
Does anyone know what goes wrong in the process with this php code?This code seems to be causing it: <?PHP } else { echo " <div