File tree Expand file tree Collapse file tree 4 files changed +15
-6
lines changed
templates/forms/fields/email Expand file tree Collapse file tree 4 files changed +15
-6
lines changed Original file line number Diff line number Diff line change 1+ # v1.3.1
2+ ## 07/27/2016
3+
4+ 1 . [ ] ( #improved )
5+ * Added support for multiple emails in ` email ` field (add ` multiple: true ` to enable)
6+ 1 . [ ] ( #bugfix )
7+ * Fixed backward incompatibility with forms submission and data retrieval [ getgrav/grav #933 ] ( https://github.com/getgrav/grav/issues/933 )
8+
19# v1.3.0
210## 07/14/2016
311
Original file line number Diff line number Diff line change 11name : Form
2- version : 1.3.0
2+ version : 1.3.1
33description : Enables the forms handling
44icon : check-square
55author :
Original file line number Diff line number Diff line change @@ -233,6 +233,11 @@ public function post()
233233 $ data = $ this ->values ->get ('data ' );
234234 $ files = (array )$ _FILES ;
235235
236+ // Add post data to form dataset
237+ if (!$ data ) {
238+ $ data = $ this ->values ->toArray ();
239+ }
240+
236241 if (method_exists ('Grav\Common\Utils ' , 'getNonce ' )) {
237242 if (!$ this ->values ->get ('form-nonce ' ) || !Utils::verifyNonce ($ this ->values ->get ('form-nonce ' ), 'form ' )) {
238243 $ event = new Event (['form ' => $ this ,
@@ -259,11 +264,6 @@ public function post()
259264 $ i ++;
260265 }
261266
262- // Add post data to form dataset
263- if (!$ data ) {
264- $ data = $ this ->values ->toArray ();
265- }
266-
267267 $ this ->data ->merge ($ data );
268268 $ this ->data ->merge ($ files );
269269 }
Original file line number Diff line number Diff line change 22
33{% block input_attributes %}
44 type="email"
5+ {% if field .multiple in [' on' , ' true' , 1 ] %}multiple="multiple"{% endif %}
56 {{ parent () }}
67{% endblock %}
You can’t perform that action at this time.
0 commit comments