Hellos,
I wish to paste / type special characters in a code which is not working
"%0A%0A"
"\n"
Everything else is being types / pasted
Hellos,
I wish to paste / type special characters in a code which is not working
"%0A%0A"
"\n"
Everything else is being types / pasted
Only context makes it possible for others to understand, help, and use their own time productively.
HI ,
Thanks for the revert. My apologies for missing the context.
I'm making a simple Whatsapp Button allowing me(the user) to send a Whatsapp using KM to a phone number of my choice Mobile Number which is passed to KM as a variable Mobile. The following text is opened in Safari via Open in Browser action
" %0A%0A" below I used to format text in better way
hxxps://wa.me/91"&%Variable%Mobile%& "?text=Dear%20 Prashant" &"%0A%0A" &URLEncode("Sending you Work List Today:")
&"%0A%0A"&URLEncode("Hope you finished the Work Allocated To You)
&"%0A%0A"&URLEncode("DO NOT REPLY");
Have you tried a Filter action in these modes:
?
Filter with Percent Encode and Filter with Percent Decode.kmmacros (4.6 KB)
How are you getting those characters?
If you are entering them in a Text Field, then turn off processing tokens, otherwise %0A%
and \n
will be processed by Keyboard Maestro on entry in the field.
HI Peter , You mean Setting Below with Process Test Tokens Only ? This is failing
Yes.
“This is failing” is insufficient information to debug your problem.
HI Peter,
Thanks for your detailed reply. This makes it very clear. It simply didn't strike me that I could split my variable into multiple parts.
Thank you @ComplexPoint your suggestion of Percent Encoding works brilliantly too
You cannot both have Keyboard Maestro process “%Variable%Mobile%” and yet not process “%0A%”. They are both tokens.
There are a number of ways you can resolve this.
There are lots of other ways, but whatever way you choose you have to handle the percent character appropriately, processing them or quoting them by doubling them or stopping them from being processed.
I somehow edited my reply and messed up a perfectly good thread
Thank you @peternlewis and @ComplexPoint