Variable names Hitskin_logo Hitskin.com

This is a Hitskin.com skin preview
Install the skinReturn to the skin page

The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.
+2
tikky
skouliki
6 posters

    Variable names

    avatar
    Guest
    Guest


    In progress Variable names

    Post by Guest December 1st 2022, 7:58 am

    Hellouz,

    Let's say I need variable names and values for:
    1. User avatar
    2. Username
    3. Latest post (his)
    4. Latest topic (his)
    5. Registration date
    6. Data for (birthday, gender, hobbies)

    Now, this one is most important. How to get value of newly added field from profile? It's a text value.

    All of these variables must be accessed from jQery script on all pages. If not possible on all, only front one then.

    Thanks in advance. <3
    skouliki
    skouliki
    Manager
    Manager


    Female Posts : 15311
    Reputation : 1705
    Language : English,Greek
    Location : Greece

    In progress Re: Variable names

    Post by skouliki December 1st 2022, 11:34 am


    phutu02 likes this post

    avatar
    Guest
    Guest


    In progress Re: Variable names

    Post by Guest December 1st 2022, 11:49 am

    Okay, didn't read this so far.
    What about other variables? Such as user avatar? Or, special field in profile settings of user? How can I access that value? Given list miss many variables I asked for. But still, it's a good list Very Happy
    skouliki
    skouliki
    Manager
    Manager


    Female Posts : 15311
    Reputation : 1705
    Language : English,Greek
    Location : Greece

    In progress Re: Variable names

    Post by skouliki December 1st 2022, 3:15 pm

    Each version has different elements

    avatar
    Guest
    Guest


    In progress Re: Variable names

    Post by Guest December 1st 2022, 3:27 pm

    So let's say I want to use them on AwesomeBB. How can I access on Home page to variables for avatar, username, age, last topic, last post and access new field I made in CP? The last one is most important for me.
    tikky
    tikky
    Forumember


    Posts : 922
    Reputation : 159
    Language : 🇵🇹

    In progress Re: Variable names

    Post by tikky December 1st 2022, 3:51 pm

    skouliki, TonnyKamper and Razor12345 like this post

    Draxion
    Draxion
    Helper
    Helper


    Male Posts : 2518
    Reputation : 321
    Language : English
    Location : USA

    In progress Re: Variable names

    Post by Draxion December 3rd 2022, 6:07 pm

    Doing this is possible using a script and Ajax to obtain the data from the specific domain, like for example their profile and the specific profile field.
    avatar
    Guest
    Guest


    In progress Re: Variable names

    Post by Guest December 3rd 2022, 7:03 pm

    Draxion wrote:Doing this is possible using a script and Ajax to obtain the data from the specific domain, like for example their profile and the specific profile field.
    Do you have some example of it?
    brandon_g
    brandon_g
    Manager
    Manager


    Male Posts : 10113
    Reputation : 923
    Language : English
    Location : USA

    In progress Re: Variable names

    Post by brandon_g December 4th 2022, 8:09 pm

    Hello,

    Have you tried looking through the forum templates to see if the variable names that you need can be found there? Since those contain the html code that is being rendered by the browser, the variables used should be in the templates so the browser knows what to request from the server.

    -Brandon



    Variable names Brando10
    Remember to mark your topic Variable names Solved15 when a solution is found.
    General Rules | Tips & Tricks | FAQ | Forgot Founder Password?

    Variable names Scre1476
    Team Leader
    Review Section Rules | Request A Review | Sticker Points
    avatar
    Guest
    Guest


    In progress Re: Variable names

    Post by Guest December 4th 2022, 8:13 pm

    brandon_g wrote:Hello,

    Have you tried looking through the forum templates to see if the variable names that you need can be found there? Since those contain the html code that is being rendered by the browser, the variables used should be in the templates so the browser knows what to request from the server.

    -Brandon
    Yes, but you cant take the variable name from one template and just use it in another. That's why I ask is there a way to achieve that.
    SirLaplace
    SirLaplace
    Forumember


    Male Posts : 50
    Reputation : 4
    Language : Turkish, English

    In progress Re: Variable names

    Post by SirLaplace December 9th 2022, 1:02 pm


    I'm extremely interested in this problem as well. I've tried it myself but I can't make it work as it seems, maybe it's about forum versions? Do you think it should also work like this in ModernBB as well or does it need any modification?

    The reason I'm looking for this solution is so that I can separate and use specific CSS designing for some specific profile fields than rest.
    tikky
    tikky
    Forumember


    Posts : 922
    Reputation : 159
    Language : 🇵🇹

    In progress Re: Variable names

    Post by tikky December 9th 2022, 11:20 pm

    Do you think it should also work like this in ModernBB as well or does it need any modification?
    Works on any version the code is universal Very good
    SirLaplace
    SirLaplace
    Forumember


    Male Posts : 50
    Reputation : 4
    Language : Turkish, English

    In progress Re: Variable names

    Post by SirLaplace December 10th 2022, 3:53 pm

    pedxz wrote:
    Do you think it should also work like this in ModernBB as well or does it need any modification?
    Works on any version the code is universal Very good

    Ah okay, I finally managed to work the code in a different forum, I must be doing something wrong in my main forum. I'll tweak around and figure it out.

    But this code is taking the value from the account that is logged in. I can use it to do things in main page or navbar or widgets etc. Is there a way to make it so that it takes the value from whoever have sent the post so that I can use this variable in the postprofile section? Currently when I place the variable in the postprofile section, under the avatar, it gives the same value to each post, taking it from the logged in user.
    Ape
    Ape
    Administrator
    Administrator


    Male Posts : 19324
    Reputation : 2005
    Language : fluent in dork / mumbojumbo & English haha

    In progress Re: Variable names

    Post by Ape December 11th 2022, 8:44 pm

    Hi @zachwinch Please make your own topic about this as this is not your topic / post.



    Variable names Left1212Variable names Center11Variable names Right112
    Variable names Ape_b110
    Variable names Ape1010
    SirLaplace
    SirLaplace
    Forumember


    Male Posts : 50
    Reputation : 4
    Language : Turkish, English

    In progress Re: Variable names

    Post by SirLaplace December 11th 2022, 9:05 pm

    Ape wrote:Hi @zachwinch Please make your own topic about this as this is not your topic / post.

    Ah, I'm sorry, at first I thought topic was exactly the same thing I'm looking for and thought would be wrong to open the same thing but now I'm not exactly sure anyway. I'll move it to a separate topic. Thanks for the clarification. bounce

    Ape likes this post