© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2024
M. SimonAn Introduction to PHP https://doi.org/10.1007/979-8-8688-0177-8_4

4. Uploading Data and Files

Mark Simon1  
(1)
Ivanhoe VIC, VIC, Australia
 

In Chapter 3, we used a form to collect data to send on as an email. Forms can be used not only to send text data but also to upload a binary file, such as an image or a PDF file.

In this chapter, we’ll begin the process of maintaining an image library. This will involve setting up a form for data entry and the script which will process the data. The data will include text, as with the contact form, but also a binary file—in this case, an image file.

Processing the text data will be similar to processing the contact ...

Get An Introduction to PHP : Learn PHP 8 to Create Dynamic Websites now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.