官术网_书友最值得收藏!

Forms

Unless your site has three pages and five paragraphs of text, the likelihood that you will need to capture user input via some type of form is very high. Also, if you've been coding PHP applications you know how forms have always been a pain from the point of view of securely and efficiently rendering and processing the submitted data. As soon as you use a PHP framework such as Symfony or Laravel, you will note that an API is in place to take much of that load off your shoulders.

The same goes with Drupal 8 and its powerful Form API. Historically, it has been a great abstraction over having to output your own form elements and deal with posted values. It allows you to define your own form definition in OOP and handle validation and submission in a logical way. Its rendering and processing is taken care of by Drupal securely, so you don't have to worry about any of that. In Drupal 8, theming form elements has become much easier than in previous versions.

In this book, we will encounter some forms and see how they actually work in practice.

主站蜘蛛池模板: 繁昌县| 加查县| 南阳市| 张家界市| 叶城县| 井陉县| 马山县| 丰台区| 乌拉特前旗| 水城县| 勐海县| 蚌埠市| 朝阳市| 临汾市| 皋兰县| 四平市| 温宿县| 保山市| 古田县| 会宁县| 宁明县| 富阳市| 石楼县| 陆河县| 清徐县| 南华县| 昌宁县| 岳西县| 江孜县| 天镇县| 孝昌县| 宜兰县| 乌兰浩特市| 双峰县| 彭州市| 综艺| 赤峰市| 磐石市| 射阳县| 海盐县| 绩溪县|