New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update obfuscate.md #365

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
2 participants
@iDGS
Contributor

iDGS commented Sep 24, 2018

Per convo from Discord:
iDGSToday at 11:26 AM
After I converted to using email addresses as usernames, I'm now updating mailto: links, and within them I can't seem to get this to work: …{{ obfuscate }}{{ username }}{{ /obfuscate }}…. Instead of what I want (the email address), I'm getting {{ username }} as the text inside the email link. However, if I take out the obfuscate bookends, around {{ username }} it works just fine. I get the email address within the mailto: link, just like I wanted. I tried single braces, like so, …{{ obfuscate }}{ username }{{ /obfuscate }}… but no joy. Should I just forget about using obfuscate? Or...?(edited)
NVM. The trick was to use the modifier, as in {{ username | obfuscate }} and not the enclosing tags. :face_palm:
NEW MESSAGES
CullenToday at 11:43 AM
god to know, thanks for posting the solution. @iDGS

Update obfuscate.md
Per convo from Discord: 
iDGSToday at 11:26 AM
After I converted to using email addresses as usernames, I'm now updating mailto: links, and within them I can't seem to get this to work: …{{ obfuscate }}{{ username }}{{ /obfuscate }}….  Instead of what I want (the email address), I'm getting {{ username }} as the text inside the email link. However, if  I take out the obfuscate bookends, around {{ username }} it works just fine. I get the email address within the mailto: link, just like I wanted. I tried single braces, like so, …{{ obfuscate }}{ username }{{ /obfuscate }}… but no joy. Should I just forget about using obfuscate?  Or...?(edited)
NVM. The trick was to use the modifier, as in {{ username | obfuscate }} and not the enclosing tags. :face_palm:
NEW MESSAGES
CullenToday at 11:43 AM
god to know, thanks for posting the solution. @iDGS
@jasonvarga

This comment has been minimized.

Member

jasonvarga commented Oct 9, 2018

I'm considering this behavior a bug, which will be fixed in the next Statamic release.
The obfuscate tag doesn't parse what's between the tag pair, so it was literally obfuscating {{ username }} instead of the actual username. Next release you can continue to use the tag pair.

@jasonvarga jasonvarga closed this Oct 9, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment