Table of Contents

UrlRule

Input validation rule that tests for a valid URL with a specific URL scheme.

Example

$form->addRule (new UrlRule ('fieldName', array ('http', 'https')));

This example checks that the value in the field “fieldName” is a URL and has a scheme of either “http” or “https”.

Additional Information