News:

Join the Facebook Fan Page.

Main Menu

$context array

Started by Fuzzy_Fur, February 25, 2006, 04:04:18 PM

Previous topic - Next topic

Fuzzy_Fur

Is there anyplace to see a full listing of all the options that are loaded into the context array?

Bassicly I want to be able to get an array of all the information of the logged in member, as well as be able to get an array of another member to compare two values.

Does anyone have a method that could work in this situation?

Thanks everyone!!

Fuzzy_Fur

Notice i did a var_dump for $context to see the sub arrays.. so that ones taken care of..


Fuzzy_Fur

#3
Quote from: Thunderace on February 25, 2006, 04:10:59 PM
Try typing ..

print_r($context);

in a strategic place in index.template.php

thanks!

but how can I get the $context and $options array for another member while logged in as another member..

for instance I have a custom profile option in the $options array (not in the db) called 'fur_species' if I'm logged in as me (fuzzy) I can output my 'fur_species' by using $options['fur_species']. now if I want to check the $options['fur_species'] value for a member with the username (bob) id=5, how can i access his $options and $context array's?

so the final output would be:

Fuzzy 'the lion' slaps Bob 'the cat'


Edit: btw.. im trying to avoid making an array from the db, if i have to then I will.. but the harded question is the $options array isn't stored in the database.. so how can i access, print, and edit the values of another member while not logged in as that member.

Dannii

Other member details won't be there unless you put them there. The $context array only has information for the context. It always has your own information and several other cruicial info, but most things are determined by what you're doing.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

kegobeer

Can you explain where this "Fuzzy 'the lion'" stuff would go?  If we know how and where you plan on using it, we would have a better idea on how to help.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

Advertisement: