Hi, I have the following bit of code in my htaccess that will allow a users ID to only be alphanumeric and include underscores and hyphens:
RewriteRule ^([A-Za-z0-9_-]+)$ profile.php?ID=$1 [QSA,L]
I've recently imported over 1000 usernames from a social networking platform that allowed usernames to contain special characters, but this new platform I've migrated the usernames into won't.
How could I edit this regex to include the following special characters:
[ ] = , ? & @ ~ { } + ' . * ! ™ ` (and spaces).
Any help would be much appreciated.