BLUE
PHP 7.4.33
Path:
/var/www/multi-event-cfp.bitkit.dk/httpdocs/app/Rules
Run
Logout
Edit File
Size: 1.09 KB
Close
/var/www/multi-event-cfp.bitkit.dk/httpdocs/app/Rules/SessionDateRule.php
Text
Base64
<?php namespace App\Rules; use Illuminate\Contracts\Validation\Rule; use Illuminate\Support\Facades\Validator; class SessionDateRule implements Rule { /** * Create a new rule instance. * * @return void */ public function __construct() { // } /** * Determine if the validation rule passes. * * @param string $attribute * @param mixed $value * @return bool */ public function passes($attribute, $value) { $validator1 = Validator::make([ $attribute => $value ], [ $attribute => 'date_format:Y-m-d H:i' ]); $validator2 = Validator::make([ $attribute => $value ], [ $attribute => 'date_format:Y-m-d H:i:s' ]); if ($validator1->fails() && $validator2->fails()) return false; return true; } /** * Get the validation error message. * * @return string */ public function message() { return 'The :attribute does not match the format Y-m-d H:i or Y-m-d H:i:s'; } }
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 5
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
AbstractDataRule.php
1.44 KB
lrw-r--r--
2024-02-09 12:37:30
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
DateRule.php
1004 B
lrw-r--r--
2024-02-09 12:37:30
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
EventFormSettingsRule.php
3.01 KB
lrw-rw-r--
2024-04-25 04:56:45
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
PresentationDataRule.php
838 B
lrw-r--r--
2024-02-09 12:37:30
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
SessionDateRule.php
1.09 KB
lrw-r--r--
2024-02-09 12:37:30
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).