{"id":21508789,"url":"https://github.com/memcrab/validator","last_synced_at":"2025-06-18T03:07:27.776Z","repository":{"id":62527004,"uuid":"388805786","full_name":"Memcrab/Validator","owner":"Memcrab","description":"PHP Validator Based on  Another Validator","archived":false,"fork":false,"pushed_at":"2021-09-24T15:02:16.000Z","size":20,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-06-18T03:07:21.826Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Memcrab.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-07-23T13:10:55.000Z","updated_at":"2021-09-24T15:02:19.000Z","dependencies_parsed_at":"2022-11-02T15:45:43.302Z","dependency_job_id":null,"html_url":"https://github.com/Memcrab/Validator","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/Memcrab/Validator","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Memcrab%2FValidator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Memcrab%2FValidator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Memcrab%2FValidator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Memcrab%2FValidator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Memcrab","download_url":"https://codeload.github.com/Memcrab/Validator/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Memcrab%2FValidator/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260477919,"owners_count":23015064,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-23T21:11:36.305Z","updated_at":"2025-06-18T03:07:22.764Z","avatar_url":"https://github.com/Memcrab.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"PHP Validator as Composer Library\n==========================\n\nInstall\n--------\n```composer require memcrab/validator```\n\nDependencies\n--------\n```\n- psr/log: \"^1.0\"\n- respect/validation: \"^2.1\"\n```\n\nUsage\n--------\n```php\nuse Memcrab\\Validator\\Validator;\nuse Respect\\Validation\\Validator as v;\n\nclass Auth extends Validator\n{\n\n    public function authorization()\n    {\n        $this\n            -\u003eaddBodyRule('email', v::email(), 'Email not valid', 400101)\n            -\u003eaddBodyRule('password', v::length(8, 100), 'Password should be more than 8 symbols', 400102);\n    }\n}\n```\n```php\n\u003c?php declare (strict_types = 1);\nrequire_once __DIR__ . \"/vendor/autoload.php\";\n\nuse Memcrab\\Validator\\Validator;\nuse Memcrab\\Validator\\ValidatorException;\n\ntry {\n  \n  // ... getting request GET($getParramethers) and POST($postParramethers)  ...\n  \n  $Validator = new Auth($getParramethers, $postParramethers);\n  $Validator-\u003eauthorization();\n  $Validator-\u003evalidate();\n  \n} catch (ValidatorException $error) {\n  // handle validation error\n}\n\n```\n\n---\n**MIT Licensed**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmemcrab%2Fvalidator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmemcrab%2Fvalidator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmemcrab%2Fvalidator/lists"}