Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- namespace Classes;
- class OrderForm {
- private $action = '';
- private $method = 'post';
- private $fields = null;
- private $errors = [];
- public function __construct() {
- $this->fields = (new OrderFields())->get();
- lex_print($this->fields);
- }
- public function getField($key) {
- return $this->fields[$key];
- }
- public function getAction() {
- return $this->action;
- }
- public function getMethod() {
- return $this->method;
- }
- public function getFields() {
- return $this->fields;
- }
- public function getErrors() {
- return $this->errors;
- }
- public function hasErrors() {
- return !empty($this->errors);
- }
- public function onSuccess() {
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement