Commit 0641b184 authored by tbrehm's avatar tbrehm

Improved URL regex.

parent 61c77268
......@@ -112,7 +112,7 @@ $form["tabs"]['domain'] = array (
'datatype' => 'VARCHAR',
'formtype' => 'TEXT',
'validators' => array ( 0 => array ( 'type' => 'REGEX',
'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.\-\,]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
'errmsg'=> 'redirect_error_regex'),
),
'default' => '',
......
......@@ -224,7 +224,7 @@ $form["tabs"]['redirect'] = array (
'redirect_path' => array (
'datatype' => 'VARCHAR',
'validators' => array ( 0 => array ( 'type' => 'REGEX',
'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.\,\-]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
'errmsg'=> 'redirect_error_regex'),
),
'formtype' => 'TEXT',
......
......@@ -112,7 +112,7 @@ $form["tabs"]['domain'] = array (
'datatype' => 'VARCHAR',
'formtype' => 'TEXT',
'validators' => array ( 0 => array ( 'type' => 'REGEX',
'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.\-\,]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
'errmsg'=> 'redirect_error_regex'),
),
'default' => '',
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment