I’m having html page content as a string and trying to check if it matches regexp of ^.+$. And it returns false. Can’t get why it does so.
Code is fairly simple:
content.matches(regexp)
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
By default, the
.does not match\rand\n. To let.also match them, enable DOT-ALL (thesflag):