Modernizing Legacy PHP apps with APIs
  • $59.98

    Regular Price

  • $49.95

    Bundle Price

Modernizing Legacy PHP apps with APIs
  • $59.98

    Regular Price

  • $49.95

    Bundle Price

Sold separately, these books have a price of $59.98 , get them now for $49.95

About the Bundle

Modernizing Legacy PHP apps with APIs

If you read the tech press, everyone knows they need an API but most aren't really sure what it is. They treat it as another checkbox like "Web 2.0" was a few years ago or a mobile app was most recently. In fact, there’s an entire “API-first” movement in development circles that most people don’t understand or even realize why. In this book, we'll start by discussing the what an API is, why you might need one, and follow up with the how to build one.

Of course, that's assuming your application is even ready for an API.

Unfortunately, your code base is a mess. It has been architected over several years by multiple different lead developers and it shows. There' are no consistent patterns or structure. The oldest core of the system is a collection of include files running several levels deep. More recently, someone bolted on some class-oriented libraries, and most recently someone decided to try a framework rewrite. All of it was done in different coding styles, with different naming conventions. The codebase is full of files that contain a mixed-up aggregation of PHP, HTML, SQL, JS, and CSS. And the "tests," such as they were, consisted of the QA team running over the site once or twice a week and filing bug reports.

But what if I told you it didn't have to be this way? What if I told you there was a specific series of small, incremental changes you could apply steadily over time to make your PHP code better, more modern, and ready for an API layer to make integrations easier. Wouldn't you like to have a plan like that written down for you, distilled into an easy-to-follow list of instructions?

  • $59.98

    Regular Price

  • $49.95

    Bundle Price

About the Books

A Practical Approach to API Design
  • 65

    Complete

  • 767

    Readers

  • 61

    Pages

  • 20,697

    Words

A Practical Approach to API Design

  • PDF

  • EPUB

  • MOBI


If you read the tech press, everyone knows they need an API but most aren't really sure what it is. They treat it as another checkbox like "Web 2.0" was a few years ago or a mobile app was most recently. In fact, there’s an entire “API-first” movement in development circles that most people don’t understand or even realize why. In this book, we'll start by discussing the what an API is, why you might need one, and follow up with the how to build one.

This book is incomplete. In accordance with the Lean Methodology, we wanted to get a Minimum Viable Product out there into people’s hands as quickly as possible to gauge interest, collect feedback, and make sure that the work we’re doing means something to someone. As a result, we hope this book becomes a conversation as we continue writing. When you find something interesting, let us know. If you think we’re wrong, say so. If you think we’re right, tell your friends. If you want us to teach your team more and deeper concepts, please let us know.

Towards that goal, here are the chapters currently on our drawing board:

  • API Design Patterns
    • Idempotency
    • SOLID Design Principles
    • Naming - Resources & Parameters
    • Transactions
    • Authorization - Tokens vs Credentials
    • Link Relations
    • Composites
    • Versioning
    • Pagination
    • Error Handling
    • Caching - Strategies & ETags
    • Hard vs Soft Deletes
  • Data Architecture
    • Hypermedia Specifications
    • Data stores and storage
  • API Product Management
    • Team Dynamics
    • Partitioning API Teams
    • Selecting your Infrastructure
    • Estimating Costs
    • Release Management
    • Automation
  • Community & Support
    • Documentation
    • SDKs
    • Third-party development portals
    • Evangelism

Read More

Modernizing Legacy Applications In PHP
  • 834

    Readers

  • 230

    Pages

  • 58,569

    Words

Modernizing Legacy Applications In PHP

  • PDF

  • EPUB

  • MOBI


"You will breeze through your code like the wind. It will be autoloaded, dependency-injected, unit-tested, layer-separated, and front-controlled."

Is your legacy PHP application composed of page scripts placed directly in the document root of the web server? Do your page scripts, along with any other classes and functions, combine the concerns of model, view, and controller into the same scope? Is the majority of the logical flow incorporated as include files and global functions rather than class methods? If so, you already know that the wide use of global variables means that making a change in one place leads to unexpected consequences somewhere else. These and other factors make it overly difficult and expensive for you to add features and fix bugs. Working with this legacy application feels like dragging your feet through mud.

But it doesn't have to be that way! This book will show you how to modernize your application by extracting and replacing its legacy artifacts. We will use a step-by-step approach, moving slowly and methodically, to improve your application from the ground up. Moreover, we will keep your application running the whole time. Each completed step in the process will keep your codebase fully operational with higher quality. When we are done, you will be able to breeze through your code like the wind. Your code will be autoloaded, dependency-injected, unit-tested, layer-separated, and front-controlled.

Please note that this book is about modernizing in terms of practice and technique, and not in terms of tools. We are not going to discuss the latest, hottest frameworks or libraries. With the exception of testing systems like PHPUnit, and one or two standalone third-party libraries, the book does not advocate adding third-party code to your existing legacy application. Most of the very limited code we do add to your application is specific to this book. We will be improving ourselves as programmers, as well as improving the quality of our legacy application.

If you feel overwhelmed by a legacy application, "Modernizing Legacy Applications in PHP" is the book for you. If you prefer a paper copy, you can purchase one at Lulu.com.

If you're still on the fence, the video "It Was Like That When I Got Here" (embedded above on this page) outlines the first few chapters for free, and you can read some reviews of the book on the feedback page. You can also read the 4.5-star review from SitePoint.

Be sure to follow the book on Twitter @mlaphp, and tell all your friends!

Read More

About the Authors

The Leanpub Unconditional, No Risk, 100% Happiness Guarantee

Within 45 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks. We process the refunds manually, so they may take a few days to show up.
See full terms