I've been working on a web app in which users can comment and reply to comments, this uses a tagging system. The users are being tagged by their name which can contain more words so I've decided to mark the takes like this:
&&John Doe&&
So a comment might look like this:
&&John Doe&&, are you sure that &&Alice Johnson&& is gone?
I'm trying to write a regex to match use in a string.replace() javascript function, so the regex must match every single tag in the string.
So far I have:
^&&.+{2, 64}&&$
This isn't working so I'm sure something is wrong, in case you didn't understand what I meant, the regex from above is supposed to match strings like this:
&&anythingbetween2and64charslong&&.
Thanks in advance!
&inside a name or escaping mechnisms? Otherwise just go by&&.{2,64}?&&