I am confused where is data in LOGGED_IN_USER coming from.
For example I have a simple hero text that I modified to include Hello {LOGGED_IN_USER:NAME} and that works. It shows "Hello Mark. But in my users “table” in softr under users page I have entry for Mark that is “Mark Johnson”, and I don’t have a NAME field in my air table.
And when I try to do {LOGGED_IN_USER:FULL_NAME} where FULL_NAME is a field in my air table, it doesn’t work. I see “Hello {LOGGED_IN_USER:FULL_NAME}”
{LOGGED_IN_USER:xxxxx} is the method to get the logged-in user information to be pulled in your app.
The ‘NAME’ from {LOGGED_IN_USER:NAME} comes from what Softr stores once a user is considered as registered in the app.
Basically it’s the information that you can find here (see image below) and that Softr lets you access to (NAME & EMAIL => MAGIC LINK, CREATED DATE, USER GROUPS - for now - and LAST SEEN DATE may not be accessible).
Now, what if you want to access your fields from your users table in Airtable? The format is a bit different. For example, you want to take the FULL_NAME value. FULL_NAME being a field (case sensitive) in your airtable users table.
=> {LOGGED_IN_USER:FIELD:FULL_NAME}. Here I added FIELD: to get the users table in Airtable, not the users table in Softr.
Here is a screenshot from the page where I have a “placeholder” set:
And when I open this page in preview mode I see this:
The last name is missing. Only John is pulled.
When I modify the placeholder to be {LOGGED_IN_USER:FIELD:full_name} where full_name is a filed in my airtable.
Nothing is rendered on the page. I see exactly the same place holder like this:
Correct - not the code you wrote. I was just showing that even the block of code you wrote does’t execute. Your block of code has this statement console.log('Block loaded');
that is not logged in the console window.
and the text i have in the <span> like this Here: <span class="d-none">{LOGGED_IN_USER:FIELD:full_name}</span> is not replaces.
So this window.addEventListener for some reason is not working.
You are trying to use <span class="d-none">{LOGGED_IN_USER:FIELD:full_name}</span> inside a heading or inside a subtitle, right? I mean the static heading or the static subtitle of the dynamic block (The option Title and Subtitle of any dynamic block).
So it should work. I can’t debug without any further information, meaning going inside your app to check everything. Or maybe if you could record a video where you would show everyhting in the Softr studio (code + the list block).
Few basic things but we never know: In the preview mode, be sure you are as a logged-in user. Be sure also that you didn’t change the name of the users table in Airtable (it would disconnect everything).
Be sure your dynamic block is named ‘my-test-list’ (Sometimes Softr doesn’t take it in count when it is changed, it’s a small bug).
Also, you may have published your app once.
Be sure you wrote this in the subtitle:
Creative Content for <span class="d-none">{LOGGED_IN_USER:FIELD:full_name}</span>
In other words, double check everything.
In the meantime you should reach out to the customer service within the chat in the Softr studio (The question mark button at the bottom right of the studio)
Here is a video showing code in the header, the span inside the subtitle of the list as well as what the page looks like in the preview mode. Thank you for your time looking into this - https://youtu.be/5V8fWXYtIqU