How To Introduce The Base Class For File Downloads In Php Export


show more Introducing the Base class for file downloads provides you with in-depth training on Developer. Taught by David Powers as part of the Exporting Data to Files with PHP show less
please wait ...

Introducing the Base class for file downloads

We saw earlier in this chapter, that it takes only a few lines of code to export a data base result to a text file, or to a CSV file. Because so little code is involved, it might seem overkill to use custom classes instead. But even if you Copy and Paste all of this code into another file, you'll probably want to make some changes to it. For example, this code on line 12. It capitalizes the first letter of each column name in the database result. What if you want it to be all uppercase, or what if you don't want to include it at all? You might also want the idea of each database row to create links in your webpage.

But you don't want that information to be included in the download file. That's where custom classes come in handy. The class definitions are in the SRC folder, that I've created at the top level of my testing site. You can find a copy of this folder in the exercise files for this video. Let's jut open it. It contains another folder called foundationphp. That's my d...

Introducing the Base class for file downloads
Video duration: 4m 37s 3h 42m Intermediate

Viewers:

Introducing the Base class for file downloads provides you with in-depth training on Developer. Taught by David Powers as part of the Exporting Data to Files with PHP

Subject:
Developer
Software:
PHP
Author:
please wait ...