The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Variables

Go down

Variables

Post by kaizen_zyr on Sun 21 Nov - 14:43

Guys can you help me with the variables of ff:

username:

Primary Photo/ Avatar:

NO PM changes to NEW PM with the corresponding numbers of new pm:

Friends and Foes Online with corresponding numbers of online friends and foes:



Thnx in advance....
avatar
kaizen_zyr
Forumember

Male Posts : 36
Reputation : 0
Language : English

Back to top Go down

Re: Variables

Post by Plancker on Sun 21 Nov - 21:26

{ USERNAME }
{ postrow.displayed.POSTER_AVATAR } or { AVATAR_IMG }
{ INBOX }
{ L_FRIENDS_AND_FOES } or { FRIENDSFOES }

(Remove the spaces)
i think these are correct did not test them

Plancker
Forumember

Posts : 226
Reputation : 11
Language : Dutch, English

Back to top Go down

Re: Variables

Post by Saxaca on Sun 21 Nov - 21:28

avatar
Saxaca
Forumember

Male Posts : 539
Reputation : 26
Language : Markup.

Back to top Go down

Re: Variables

Post by Plancker on Sun 21 Nov - 21:34

PS: The "using php in posts.." are not written by me.. it just popped up
that's because forumotion blocks them on help forum

Plancker
Forumember

Posts : 226
Reputation : 11
Language : Dutch, English

Back to top Go down

Re: Variables

Post by Saxaca on Sun 21 Nov - 21:39

Yeah, i noticed that now later, what a stupid cencor Razz
Whatever, i edited my post.. Just cutted it all out Wink
avatar
Saxaca
Forumember

Male Posts : 539
Reputation : 26
Language : Markup.

Back to top Go down

Re: Variables

Post by kaizen_zyr on Wed 24 Nov - 16:10

@Plancker wrote:{ USERNAME }
{ postrow.displayed.POSTER_AVATAR } or { AVATAR_IMG }
{ INBOX }
{ L_FRIENDS_AND_FOES } or { FRIENDSFOES }

(Remove the spaces)
i think these are correct did not test them

it ddnt work in my profile...or maybe i used it in a wrong way.. may there should be a script for this and not just you write the { USERNAME } because it dont appear...or maybe this code is broken?....

anyways i followed your steps and erasing the spaces in the code...

thnx anyways....
avatar
kaizen_zyr
Forumember

Male Posts : 36
Reputation : 0
Language : English

Back to top Go down

Re: Variables

Post by Plancker on Wed 24 Nov - 18:04

sorry if they are wrong that was just a guess

but the link http://help.forumotion.com/popup_help.forum?l=miscvars&i=site_desc shows every variable you can use

Plancker
Forumember

Posts : 226
Reputation : 11
Language : Dutch, English

Back to top Go down

Re: Variables

Post by Saxaca on Wed 24 Nov - 18:09

@kaizen_zyr wrote:
it ddnt work in my profile...or maybe i used it in a wrong way.. may there should be a script for this and not just you write the { USERNAME } because it dont appear...or maybe this code is broken?....

anyways i followed your steps and erasing the spaces in the code...

thnx anyways....

I don't think variables work in profiles.
avatar
Saxaca
Forumember

Male Posts : 539
Reputation : 26
Language : Markup.

Back to top Go down

Re: Variables

Post by Plancker on Wed 24 Nov - 18:22

they work in signature

Plancker
Forumember

Posts : 226
Reputation : 11
Language : Dutch, English

Back to top Go down

Re: Variables

Post by kaizen_zyr on Thu 25 Nov - 5:10

how about in templates?.... because i wanted to use this codes in my sliding panel.... its a template,.. can someone give me a JS on how the variables works in a template?....
avatar
kaizen_zyr
Forumember

Male Posts : 36
Reputation : 0
Language : English

Back to top Go down

Re: Variables

Post by Darren1 on Thu 25 Nov - 10:56

Hi,

I'm slightly puzzled on how you have been answered.
The following are TEMPLATE codes (they are NOT Variables, just codes to bring a users' profile information


{postrow.displayed.POSTER_AVATAR} or {AVATAR_IMG}
{INBOX}
{L_FRIENDS_AND_FOES} or {FRIENDSFOES

These will NOT work anywhere else but in the templates

If you want variables that will work on the board, and you can type in, and display certain things, then this list will aid you.
Please note that you CAN NOT add any more.
There is no code for the user avatar.
=> http://help.forumotion.com/tricks-tips-f32/list-of-variables-t48637.htm


I can help you, can you tell me what you want to do with these codes Wink
avatar
Darren1
Helper
Helper

Male Posts : 11853
Reputation : 563
Language : English

Back to top Go down

Re: Variables

Post by takunda on Fri 26 Nov - 1:12

Hey Darren

Maybe you can help me. I have a skysa bar on my website. It works okay but not perfect because i think i have some wrong variables somewhere. The friends online doesnt work at all maybe you can help me. Here is what is required


<script type="text/javascript">
var _SKYAUTH = {
loginUrl:'REPLACE WITH FULL LOGIN URL',
memberNick:'REPLACE WITH CONTEXT CODE TO GET MEMBER USER NAME',
memberId:'REPLACE WITH CONTEXT CODE TO GET MEMBER ID',
profileUrl:'REPLACE WITH MEMBER PROFILE URL',
photoUrl:'REPLACE WITH MEMBER PHOTO URL'
};
</script>


Below are variables i am currently using


<script type="text/javascript">
var _SKYAUTH = {
loginUrl:'ucp.php?mode=['L_AUTO_LOGIN'],
memberNick:'ucp.php?mode=[L_USERNAME]',
memberId:'$user->data=[USER_ID]',
profileUrl:"memberlist.php?mode=viewprofile&u=$user->data['L_PROFILE']",
profileUrl:profile_view_body.tpl=['PROFILE_IMG'],
photoUrl:['AVATAR_IMG'],
friendsonline:['L_FRIENDS_AND_FOES'];
</script>

avatar
takunda
New Member

Posts : 14
Reputation : 0
Language : English

Back to top Go down

Re: Variables

Post by Darren1 on Fri 26 Nov - 2:05

Hey, Takunda

skysa bars, alike Mebo bars aren't really programmed for any forums, they just made a script and say "hey this works, lets call it perfect even though there's obvious bugs".

First I need to know if your adding this via the templates?
I can tell you right away why it isn't working; and thats becausen youve got php in it; forumotion doesn't support php.

Use {L_FRIENDSFOES} rather than [L_FRIENDS_AND_FOES]
Ensure you use these brackets {} otherwise you should just see the text and no real function hahahaha
avatar
Darren1
Helper
Helper

Male Posts : 11853
Reputation : 563
Language : English

Back to top Go down

Re: Variables

Post by takunda on Fri 26 Nov - 2:14

Ok Cheers Darren so how would you edit the code if you were to use it?


Can you help me arrange the variables?
avatar
takunda
New Member

Posts : 14
Reputation : 0
Language : English

Back to top Go down

Re: Variables

Post by Darren1 on Fri 26 Nov - 2:19

Is that the entire code?

<script type="text/javascript">
var _SKYAUTH = {
loginUrl:'ucp.php?mode={'L_AUTO_LOGIN'},
memberNick:'ucp.php?mode={L_USERNAME}',
memberId:'$user->data={USER_ID}',
profileUrl:"memberlist.php?mode=viewprofile&u=$user->data{'L_PROFILE'}",
profileUrl:profile_view_body.tpl={'PROFILE_IMG'},
photoUrl:{'AVATAR_IMG'},
friendsonline:{L_FRIENDSFOES}
</script>

I'm usuless at php, so I can't really do anym,ore then what I just did, which was, well, changing [] to {}

Is the issue just the freidns online, or does the rest not work as well?
avatar
Darren1
Helper
Helper

Male Posts : 11853
Reputation : 563
Language : English

Back to top Go down

Re: Variables

Post by takunda on Sat 27 Nov - 2:29

Yah thats the funny thing the bar works well with that code. The private chats works fine...Maybe a few bugs. The friends online doesnt work. Also i wanted it to auto login members.
avatar
takunda
New Member

Posts : 14
Reputation : 0
Language : English

Back to top Go down

Re: Variables

Post by Darren1 on Sun 28 Nov - 5:33

I doubt we can do anything about the auto-login, because we dont have DB access, to put it into the root folder.

Wit the friends online, it would come up with all users online, that you have't blocked, wouldn't it? (Ive never done anything with this so its a learning curb for me too haha)
Try using these friend codes
{FRIENDSFOES}
{L_FRIENDS_AND_FOES}

But we've tried them already im pretty sure, so I'm stumped haha.
You'll have to wait till one of our more knowledgeable coders pop on in Wink
avatar
Darren1
Helper
Helper

Male Posts : 11853
Reputation : 563
Language : English

Back to top Go down

Re: Variables

Post by kaizen_zyr on Thu 2 Dec - 14:00

@darren: i would like to use it in my sliding panel,... try to visit my page

http://pcf-criminology.forumotions.net

above is the sliding panel,.. and the variables you gave is not working in here,.. someone told me that it needs a javascript for it to work in a template,...

hope you can fix my problem... Sad
avatar
kaizen_zyr
Forumember

Male Posts : 36
Reputation : 0
Language : English

Back to top Go down

Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum