Log in

View Full Version : How do I call a usergroup field in a php file?


007
05-02-2004, 10:54 PM
Hey does anybody know what I am doing wrong here? I have added some fields to my usergroup table and I need to call these numbers in a php file.

So I have done this:

$a = $bbuserinfo['usergroupid']['fieldname'];


I am pretty sure this is wrong, but how would I do this? I need to use the variable $a in an equation. I think VB3 has a different way of usergroup permissions though. What am I doing wrong?

Thanks!

~006

007
05-03-2004, 03:05 AM
Ok I was stupid in my last post. I got it now.

NEW question though. I have the query to call the column, but it's an integer field and the query doesn't seem to load it as an INT. It is loading it as "Resource id #20" (Don't ask me what this means.) It also loaded as "Array" when outputted. The problem is that I am taking this number that is the result of the query and I am using it in an equation. It needs to be a number. How do I make this work?

(And sorry if this is in the wrong forum. I guess it probably belongs in the SQL/PHP forum)

007
05-03-2004, 11:45 PM
Anyone know? I know it's a simple line of code, I just don't know what it is. How do I specify the result of a query to be an integer?