File "UrlRule.php"

Full Path: /home/warrior1/public_html/languages/wp-content-20241001222009/plugins/file-manager/vendor/bitapps/wp-validator/src/Rules/UrlRule.php
File size: 355 bytes
MIME-type: text/x-php
Charset: utf-8

<?php
namespace BitApps\WPValidator\Rules;

use BitApps\WPValidator\Rule;

class UrlRule extends Rule
{
    private $message = "The :attribute format is invalid";

    public function validate($value)
    {
        return filter_var($value, FILTER_VALIDATE_URL) !== false;
    }

    public function message()
    {
        return $this->message;
    }
}