LDSTechForumProjects

LDS PHP Framework

Introduction

For most high-traffic and widely used applications, the Church has standardized on Java and utilizes the LDS Java Stack. However, as more applications are developed to handle smaller audiences, the need for a light-weight and rapid-application-development environment has emerged. The purpose of this document is to define one such environment, built using PHP. This article defines the software stack, framework architecture, APIs, and classes for the framework.

Naming

It's not clear the "Framework" is the best description for this, but it's good enough to start with.

Goals

The main premise of an LDS, PHP framework is to put together a base set of code that can easily be copied (and synced, as improvements are added), as a starting point for new projects/sites. In practice, this would mean that a new site can start with the core base of code (from Subversion, most likely) rapidly--say 5 minutes.

One goal may be to have this contained in one, main sub-directory, allowing for the entire, core code base to be included in a new site as a Subversion external.

Features

Things that should be provided out-of-the-box:

  • Clean-URL support (URL routing);
  • Page, template, and library separation, with on-demand loading for each;
  • Database functions (mostly focused on MySQL, but others can be supported as well);
  • LDS Account functions (authenticate users);
  • An easy way to add JavaScript to the bottom of pages (where it should be; CSS early, JS late); and
  • A simple way to minify & compress JavaScript and CSS, with correct headers for browser caching.

Testing

There is a test site for the phpstack:

https://tech-dev.lds.org/phpstack/

Which is configured to point at staging data.

This page was last modified on 31 March 2016, at 13:59.

Note: Content found in this wiki may not always reflect official Church information. See Terms of Use.