MemHT Portal is a Free PHP CMS and Blog
It permit the creation and the management online of websites with few and easy steps.
It's completelly customizable, expandable and suitable for all needs.
Moderators: Moderators
Forum RSS feedReply
SQL problem while changing online block
AuthorText
Zion
Junior Member
Avatar

Posts: 27
Contributes: 29

Gender: _MALE_
Online: No
Date: 01/08/2008 03:53
SQL problem while changing online block
#post10758
Hi guys,
I'm trying to edit the "who is online" block that it will show gender instead of country.
I added this line on line 42 after $country:
code

$gender = intval($dblink->query("SELECT gender,FROM memht_utenti WHERE user='$ouser'"));
 

and it returns 0, even if the field is 1.
Any suggestions?
(First time for me with Databases, so take it easy).
Thanks.
Zion.
Delete Edit Quote
 
paulo89
Moderator
Developer

Avatar

Posts: 1300
Contributes: 537

Gender: _MALE_
Online: No

Version: 3.8.1
Country: Portugal
Languages: Portuguese, Portuguese and little english ^^
Date: 01/08/2008 08:47
Re: SQL problem while changing online block
#post10765
Hi

Somethink like this:

code

                $test = $dblink->get_row("SELECT gender FROM memht_utenti WHERE user='$ouser'");
                $gender = intval($test['gender']);
 
Delete Edit Quote
 
Zion
Junior Member
Avatar

Posts: 27
Contributes: 29

Gender: _MALE_
Online: No
Date: 02/08/2008 03:47
Re: SQL problem while changing online block
#post10774
Thanks,
The problem was fixed, and it works fine now.
Zion.
Delete Edit Quote
 
Reply
Tags Cloud
Advertising
News Archive
Language
Help MemHT Portal
Navigator
Users Block
Hi Guest
IP: 38.103.63.59

Username
Password
New files
MemHT Wiki
Friends
MemHT Portal is a free software released under the GNU/GPL License by Miltenovik Manojlo