PDA

View Full Version : AJAX userinfo, variables.


wipedout
09-13-2009, 10:34 AM
Okay, ill start off before the you people start calling me a noob since i obviously dont know what im talking about, ive modified my MEMBERINFO tab to to get profile info from $calmprofile, the info from that template is put into a div, code :


<div class="alt2 smallfont block_row" id="profilewrapper" >
$calmprofile
</div>


Im wondering if i can EASILY make a button that changes the $calmprofile to say $calmsecond.

hoping for a quick answer here since i dont know much about AJAX

James Birkett
09-13-2009, 11:50 AM
So you'd like a button that replaces the $calmprofile variable with a $calmsecond variable?

You could just use if statement(s) maybe, or put the styling INSIDE the variable, then use an onclick?

I've not tried this, so I could be totally wrong.

Also, the main aim of this site is to help, so we're not going to insult you or your intelligence.

wipedout
09-13-2009, 11:54 AM
Yes i want to make a button that changes the variable, as in changing the content within my DIV.

Lynne
09-13-2009, 03:05 PM
So, this variable you have in there is actually a profile field? So, it is something like fieldx and you want a button to change the value of fieldx?

Is this your own tab that you've added? If so, you can just put the code inside of there.

wipedout
09-14-2009, 12:43 AM
Yea its a fieldx inside of the divs aswell yes, but i dont wanna change the variable i wanna display different information, i dont use tabs as ive changed it, www.thefurryden.net/calmcacil is how stuff looks atm, i wanna make a button changing the main "window" change to display different info.