diff --git a/core/lib/Thelia/Form/CustomerCreation.php b/core/lib/Thelia/Form/CustomerCreation.php index a925d3d56..80efb74da 100644 --- a/core/lib/Thelia/Form/CustomerCreation.php +++ b/core/lib/Thelia/Form/CustomerCreation.php @@ -37,26 +37,34 @@ class CustomerCreation extends BaseForm ->add("firstname", "text", array( "constraints" => array( new Constraints\NotBlank() - ) + ), + "label" => "firstname" )) ->add("lastname", "text", array( "constraints" => array( new Constraints\NotBlank() - ) + ), + "label" => "lastname" )) ->add("email", "email", array( "constraints" => array( new Constraints\NotBlank(), new Constraints\Email() - ) + ), + "label" => "email" )) ->add("address1", "text", array( "constraints" => array( new Constraints\NotBlank() - ) + ), + "label" => "address" + )) + ->add("address2", "text", array( + "label" => "Address Line 2" + )) + ->add("address3", "text", array( + "label" => "Address Line 3" )) - ->add("address2", "text") - ->add("address3", "text") ->add("zipcode", "text", array( "constraints" => array( new Constraints\NotBlank() diff --git a/templates/smarty-sample/connexion.html b/templates/smarty-sample/connexion.html new file mode 100644 index 000000000..69c4b516c --- /dev/null +++ b/templates/smarty-sample/connexion.html @@ -0,0 +1,27 @@ +{include file="includes/header.html"} + +{form name="thelia.customer.creation"} +
+ + {form_field_hidden form=$form} + {form_field form=$form.firstname} + {form_error form=$form.firstname} + {$message} + {/form_error} + + + {/form_field} + + {form_field form=$form.lastname} + {form_error form=$form.lastname} + {$message} + {/form_error} + + + {/form_field} + + +
+{/form} + +{include file="includes/footer.html"} \ No newline at end of file diff --git a/templates/smarty-sample/index.html b/templates/smarty-sample/index.html index 28f78f06c..e04fbf097 100755 --- a/templates/smarty-sample/index.html +++ b/templates/smarty-sample/index.html @@ -7,41 +7,8 @@ An image from asset directory :
{intl l='An internationalized string'}
-{form name="thelia.customer.creation"} -
- {form_field_hidden form=$form} - {form_field form=$form.email} - {form_error form=$form.email} - {$message} - {/form_error} - {intl l="{$label}"} : - {/form_field} - {form_field form=$form.name} - {intl l='name'} : - {/form_field} - {form_field form=$form.age} - {intl l='age'} : - {/form_field} - -
-{/form} - -
- -{form name="thelia.admin_login"} -
- {form_field_hidden form=$form} - {form_field form=$form.username} - username : - {/form_field} - - {form_field form=$form.password} - password : - {/form_field} -
-{/form}
jQuery data: