r/PHPhelp • u/Tricky_Box_7642 • Dec 14 '25
Solved Regular expression for length
is there a way i can use a regex to check if a notes box has only 1000 characters? such as
!preg_match("/^{1000}$/", $notesBox)
yes i know this doesn't work, what can i do to make one that does? (i would like all characters available)
7
Upvotes
View all comments
Show parent comment
2
u/ysth Dec 16 '25
or grapheme_strlen