© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2022
D. PowersPHP 8 Solutionshttps://doi.org/10.1007/978-1-4842-7141-4_16

16. Formatting Text and Dates

David Powers1  
(1)
London, UK
 

We have some unfinished business left over from the previous chapter. Figure 15-1 in Chapter 15 shows content from the blog table with just the first two sentences of each article displayed and a link to the rest of the article. However, I didn’t show you how it was done. There are several ways to extract a shorter piece of text from the beginning of a longer one. Some are rather crude and usually leave you with a broken word at the end. In this chapter, you’ll learn how to extract complete sentences.

The other unfinished business ...

Get PHP 8 Solutions: Dynamic Web Design and Development Made Easy 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.