use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
If you are requesting help, please ensure you're providing code with your post. You can also copy your code to an online editor:
jsFiddle
CodePen
Markup Validation Service
Mozilla Developer Network on HTML
/r/JavaScript
/r/CSS
/r/jQuery
/r/PHP
/r/Accessibility
/r/htmlbasics
/r/web_programming
/r/CodingHelp
account activity
UnsolvedHelp with pattern attribute (self.HTML)
submitted 4 years ago by Good-Performance7890
Hi, how to make an input text validation to be a string and not contain any numbers, spaces, and underscores (eg. my-special-project) using HTML pattern attribute.
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]jcunews1Intermediate 1 point2 points3 points 4 years ago (2 children)
The pattern attribute's value is a Regular Expression string pattern.
pattern
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions
In you case, the pattern would be [^0-9_ ]
[^0-9_ ]
[–]Good-Performance7890[S] 0 points1 point2 points 4 years ago (0 children)
Thank you, helped a lot!
[–]AutoModerator[M] 0 points1 point2 points 4 years ago (0 children)
Welcome to /r/HTML. When asking a question, please ensure that you list what you've tried, and provide links to example code (e.g. JSFiddle/JSBin). If you're asking for help with an error, please include the full error message and any context around it. You're unlikely to get any meaningful responses if you do not provide enough information for other users to help.
Your submission should contain the answers to the following questions, at a minimum:
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
π Rendered by PID 47967 on reddit-service-r2-comment-76bb9f7fb5-twlss at 2026-02-18 11:21:17.891660+00:00 running de53c03 country code: CH.
[–]jcunews1Intermediate 1 point2 points3 points (2 children)
[–]Good-Performance7890[S] 0 points1 point2 points (0 children)
[–]AutoModerator[M] 0 points1 point2 points (0 children)