Blog

Emitting Responses with Diactoros

When writing middleware-based applications, at some point you will need to emit your response. PSR-7 defines the various interfaces related to HTTP messages, but does not define how they will be used. Diactoros defines several utility classes for these pur ... (continue)

Logging PHP applications

Every PHP application generates errors, warnings, and notices and throws exceptions. If we do not log this information, we lose a way to identify and solve problems at runtime. Moreover, we may need to log specific actions such as a user login and logout ... (continue)

Specialized Response Implementations in Diactoros

When writing PSR-7 middleware, at some point you'll need to return a response. Maybe you'll be returning an empty response, indicating something along the lines of successful deletion of a resource. Maybe you need to return some HTML, or JSON, or just plai ... (continue)

Protecting passwords with Argon2 in PHP 7.2

PHP 7.2 will be released later this year (2017). This version contains some interesting additions, including two new security features: support of the Argon2 password hash algorithm, and the ext/sodium extension wrapping the libsodium library. With these n ... (continue)

REST Representations for Expressive

We've been working towards our various Apigility on Expressive goals, and have recently published two new components: zend-problem-details zend-expressive-hal These components provide response representations for APIs built with PSR-7 middleware. Spe ... (continue)

Apigility on Expressive Update for 2017-07-13

We've been working on the Apigility on Expressive initiative for a couple months now, and have a bit of progress to report. First, if you're unfamiliar with the initiative, please head over and read the RFC. In this post, we'll discuss what's done and read ... (continue)

Convert objects to arrays and back with zend-hydrator

APIs are all the rage these days, and a tremendous number of them are being written in PHP. When APIs were first gaining popularity, this seemed like a match made in heaven: query the database, pass the results to json_encode(), and voilĂ ! API payload! In ... (continue)

Validate data using zend-inputfilter

In our previous two posts, we covered zend-filter and zend-validator. With these two components, you now have the tools necessary to ensure any given user input is valid, fulfilling the first half of the "filter input, escape output" mantra. Howe ... (continue)

Validate input using zend-validator

In our previous post, we covered zend-filter, The filters in zend-filter are generally used to pre-filter or normalize incoming data. This is all well and good, but we still don't know if the data is valid. That's where zend-validator comes in. Installatio ... (continue)

Filter input using zend-filter

When securing your website, the mantra is "Filter input, escape output." We previously covered escaping output with our post on zend-escaper. We're now going to turn to filtering input. Filtering input is rather complex, and spans a number of pra ... (continue)

Share

Subscribe

Subscribe to this blog via RSS.

Copyright

© 2006-2017 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.

Contacts