PDA

View Full Version : styleid variable?


jchamber2010
06-11-2009, 08:27 PM
I would like to know the variable to display the style id of the user, so that i can put it in (for example) the postbit, and display the style id.

If there is no variable that does this, could you tell me a way that i might be able to do this?

Lynne
06-11-2009, 08:37 PM
You can try $post[styleid]

jchamber2010
06-11-2009, 10:01 PM
thank you, that worked

Dismounted
06-12-2009, 07:09 AM
Note that the "styleid" value only reflects the correct setting if it was set from the User CP. If the user changes the style from the style drop-down in the footer, it only adds a cookie to the user's session.

jchamber2010
06-12-2009, 03:32 PM
i've already fixed that problem with a script that i have created. Thanks tho.

Another question I have is how would I display this variable in the profile
$profile[styleid]
$prepared[styleid]

do not work.

Thanks again.

Dismounted
06-13-2009, 05:48 AM
Another question I have is how would I display this variable in the profile
$profile[styleid]
$prepared[styleid]

do not work.
Try $userinfo[styleid].

jchamber2010
06-13-2009, 04:52 PM
ok sorry to be a pain, but how do you get the default styleid and name?

Lynne
06-13-2009, 05:17 PM
ok sorry to be a pain, but how do you get the default styleid and name?
You would have to make sure the styleid is in the query for the user information on the profile.php page. Did it show up when you used the variable Hanson posted? As for the style name, you will have to do a JOIN statement in that same query in order to get the style name.

You'll need to look at the profile.php page to see how the user info is grabbed and used.

jchamber2010
06-13-2009, 05:22 PM
that variable did work, thanks.