I have some input variables in JS and must create a link path from them.
first_name = "Jxrg";
last_name = "Yllxrss";
name_id = "100003150639830";
Then the final path that shall be created from that 3 input variables is
j/u/[url removed, login to view]
And here are the rules:
1. The upper case letters from first and last name must be changed into lower case letters
2. First and last name must be checked if there are some special characters included and if so replaced. I need if for german special characters which I cannot display here. So just imagine that this special characters are 'x' and 'y'. 'x' shall be replaced with 'oe' and 'y' shall be replaced with 'ue'
3. The rest is easy. The path starts with the first letter of the first name, then follows a slash, then comes the first letter of the last name, then a slash again. After that first name, underscore, last name, underscore, name id, underscore and finally just add '[url removed, login to view]'