I am building an app for a client and have been able to do almost everything. Funny enough, something that seems like it should be quite simple is turning into a bit of a headache.
In the app, users have profiles. Their profile name should be displayed as “First Name” “Last Name Initial” so for me it would be “John K”.
I’ve explored a bunch of different options from messing with display settings to creating fields in the database, but nothing seems to be working right.
If anyone has any insight of how I could accomplish this it would be greatly appreciated.
The idea is that after the user has submitted the first name and last name, you would uppercase the last name string, keep the first letter only, then save that to a new user text parameter like “last name initial”
Made a video of how you can do this with the Arbitrary Javascript component! ( This includes voice too! I’m so happy today because I got my mic that I now can make videos with voice ) : Loom | Free Screen & Video Recording Software | Loom
var first_name = "John";
var first_name_in_capital = first_name.charAt(0).toUpperCase() + first_name.slice(1);
var last_name = "krueger";
var last_name_in_capital = last_name.charAt(0).toUpperCase();
var Name = first_name_in_capital + "." + last_name_in_capital;
return Name;
Perfect job! This also solves my problems because I used AbracAdalo for string manipulation which makes the app super slow! Now I can do everything locally without an API call!