Skip to:
^ and $ should match the start and end of the entire string, not just the region being searched.
^
$
^
and$
should match the start and end of the entire string, not just the region being searched.