This repository has been archived by the owner on Aug 17, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathvalidation.php
221 lines (202 loc) · 11 KB
/
validation.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
<?php
return array(
/*
|--------------------------------------------------------------------------
| Validation Language Lines
|--------------------------------------------------------------------------
|
| The following language lines contain the default error messages used by
| the validator class. Some of these rules have multiple versions such
| as the size rules. Feel free to tweak each of these messages here.
|
*/
"accepted" => "The :attribute must be accepted.",
"active_url" => "The :attribute is not a valid URL.",
"after" => "The :attribute must be a date after :date.",
"alpha" => "The :attribute may only contain letters.",
"alpha_dash" => "The :attribute may only contain letters, numbers, dashes and underscores.",
"alpha_num" => "The :attribute may only contain letters and numbers.",
"array" => "The :attribute must be an array.",
"before" => "The :attribute must be a date before :date.",
"between" => array(
"numeric" => "The :attribute must be between :min and :max.",
"file" => "The :attribute must be between :min and :max kilobytes.",
"string" => "The :attribute must be between :min and :max characters.",
"array" => "The :attribute must have between :min and :max items.",
),
"boolean" => "The :attribute field must be true or false.",
"confirmed" => "The :attribute confirmation does not match.",
"date" => "The :attribute is not a valid date.",
"date_format" => "The :attribute does not match the format :format.",
"different" => "The :attribute and :other must be different.",
"digits" => "The :attribute must be :digits digits.",
"digits_between" => "The :attribute must be between :min and :max digits.",
"email" => "The :attribute must be a valid email address.",
"exists" => "The selected :attribute is invalid.",
"image" => "The :attribute must be an image.",
"in" => "The selected :attribute is invalid.",
"integer" => "The :attribute must be an integer.",
"ip" => "The :attribute must be a valid IP address.",
"max" => array(
"numeric" => "The :attribute may not be greater than :max.",
"file" => "The :attribute may not be greater than :max kilobytes.",
"string" => "The :attribute may not be greater than :max characters.",
"array" => "The :attribute may not have more than :max items.",
),
"mimes" => "The :attribute must be a file of type: :values.",
"min" => array(
"numeric" => "The :attribute must be at least :min.",
"file" => "The :attribute must be at least :min kilobytes.",
"string" => "The :attribute must be at least :min characters.",
"array" => "The :attribute must have at least :min items.",
),
"not_in" => "The selected :attribute is invalid.",
"numeric" => "The :attribute must be a number.",
"regex" => "The :attribute format is invalid.",
"required" => "The :attribute field is required.",
"required_if" => "The :attribute field is required when :other is :value.",
"required_with" => "The :attribute field is required when :values is present.",
"required_with_all" => "The :attribute field is required when :values is present.",
"required_without" => "The :attribute field is required when :values is not present.",
"required_without_all" => "The :attribute field is required when none of :values are present.",
"same" => "The :attribute and :other must match.",
"size" => array(
"numeric" => "The :attribute must be :size.",
"file" => "The :attribute must be :size kilobytes.",
"string" => "The :attribute must be :size characters.",
"array" => "The :attribute must contain :size items.",
),
"unique" => "The :attribute has already been taken.",
"url" => "The :attribute format is invalid.",
"template_exists" => "The selected :attribute is invalid.",
"is_valid_captcha" => "The captcha code entered was invalid or incorrect, please try again.",
"user_password_strength" => "The :attribute must contain: :user_password_strength.",
"operator_password_strength" => "The :attribute must contain: :operator_password_strength.",
/*
* 2.1.0
*/
"logo" => "The logo must point to a valid image file (direct URL or relative file path to base directory).",
/*
* 2.1.1
*/
"old_password" => "The :attribute field is invalid.",
/*
* 2.2.0
*/
"required_with_translation" => "The :translation translation for the :attribute field is required when :values is present.",
"max_translation" => "The :translation translation for the :attribute field may not be greater than :max characters.",
"unique_translation" => "The :translation translation for the :attribute field has already been taken.",
/*
* 2.3.0
*/
"required_translation" => "The :translation translation for the :attribute field is required.",
"customfield_not_cyclic" => "The field cannot depend on one of its children.",
/*
* 2.3.1
*/
"is_slug" => "The slug field can only contain alphanumeric characters, please percent encode any special characters.",
"article_slug_unique" => "The slug has already been taken.",
"captcha_required" => "The captcha is required.",
"ticket_number_format" => "The ticket number format is invalid.",
/*
* 2.4.0
*/
"after_or_equal" => "The :attribute must be a date after or equal to :date.",
"before_or_equal" => "The :attribute must be a date before or equal to :date.",
"dimensions" => "The :attribute has invalid image dimensions.",
"distinct" => "The :attribute field has a duplicate value.",
"file" => "The :attribute must be a file.",
"filled" => "The :attribute field must have a value.",
"gt" => array(
"numeric" => "The :attribute must be greater than :value.",
"file" => "The :attribute must be greater than :value kilobytes.",
"string" => "The :attribute must be greater than :value characters.",
"array" => "The :attribute must have more than :value items.",
),
"gte" => array(
"numeric" => "The :attribute must be greater than or equal :value.",
"file" => "The :attribute must be greater than or equal :value kilobytes.",
"string" => "The :attribute must be greater than or equal :value characters.",
"array" => "The :attribute must have :value items or more.",
),
"in_array" => "The :attribute field does not exist in :other.",
"ipv4" => "The :attribute must be a valid IPv4 address.",
"ipv6" => "The :attribute must be a valid IPv6 address.",
"json" => "The :attribute must be a valid JSON string.",
"lt" => array(
"numeric" => "The :attribute must be less than :value.",
"file" => "The :attribute must be less than :value kilobytes.",
"string" => "The :attribute must be less than :value characters.",
"array" => "The :attribute must have less than :value items.",
),
"lte" => array(
"numeric" => "The :attribute must be less than or equal :value.",
"file" => "The :attribute must be less than or equal :value kilobytes.",
"string" => "The :attribute must be less than or equal :value characters.",
"array" => "The :attribute must not have more than :value items.",
),
"mimetypes" => "The :attribute must be a file of type: :values.",
"not_regex" => "The :attribute format is invalid.",
"present" => "The :attribute field must be present.",
"required_unless" => "The :attribute field is required unless :other is in :values.",
"string" => "The :attribute must be a string.",
"timezone" => "The :attribute must be a valid zone.",
"uploaded" => "The :attribute failed to upload.",
/*
* 2.5.0
*/
"domain" => "One or more of the domain names are not valid.",
/*
* 2.5.1
*/
"valid_twig" => "The :attribute is invalid. Please use the 'Preview' button for error details.",
/*
* 3.0.0
*/
"embed_image" => "The :attribute must be a file of type: jpeg, png, or gif.",
"starts_with" => "The :attribute must start with one of the following: :values.",
/*
* 3.4.0
*/
"password" => "The password is incorrect.",
/*
* 3.5.0
*/
'phone' => "The supplied phone number is invalid.",
/*
|--------------------------------------------------------------------------
| Custom Validation Language Lines
|--------------------------------------------------------------------------
|
| Here you may specify custom validation messages for attributes using the
| convention "attribute.rule" to name the lines. This makes it quick to
| specify a specific custom language line for a given attribute rule.
|
*/
"custom" => array(
"roles.*" => array(
"exists" => "The selected role is invalid.",
),
"category.*.type" => array(
"required" => "One or more self-service types must be selected.",
),
"category.*.categories" => array(
"required" => "One or more categories are required when a self-service type has been selected.",
"exists" => "One or more of the selected categories is invalid.",
),
"brand.*" => array(
"exists" => "The selected brand is invalid.",
),
),
/*
|--------------------------------------------------------------------------
| Custom Validation Attributes
|--------------------------------------------------------------------------
|
| The following language lines are used to swap attribute place-holders
| with something more reader friendly such as Email Address instead
| of "email". This simply helps us make messages a little cleaner.
|
*/
"attributes" => array(),
);