In this tutorial we're going to dive into using Pantheon's Multidev feature. To demonstrate how this works we'll first create a new Multidev environment by cloning the existing Dev environment. Once switched over to this new branch in Git, we'll quickly edit some code and push that to our repo. We'll use Multidev to review the new code in our dashboard, and then merge that branch into the Dev master branch. With the full process complete, we can delete that branch, and the environment with it.
Additional resources
Pantheon Multidev Workflow (pantheon.io)
Pantheon is specifically designed to make managing multiple sites very easy. The Pantheon for Agencies service is perfect for agencies or organizations that manage many sites. Getting access to Pantheon for Agencies requires that you fill out a separate registration form, and once approved, you gain access to a whole new dashboard for managing your sites and teams. In this tutorial we'll take a tour of the features you get for managing your sites, including tags and filtering. We'll also learn how to manage the people on your teams, and how you can assign different permissions to team members based on which sites they have access to. We'll finish up by explaining what upstreams are and how that can be beneficial to your organization.
Additional resources
Pantheon for Agencies (pantheon.io)
Permissions and Change Management on Pantheon (pantheon.io)
Running a Custom Upstream on Pantheon (pantheon.io)
The Pantheon Stack
FreePantheon's hosting stack, which underlies the whole system is optimized for running fast, stable, and scalable Drupal sites. In this tutorial we'll peek behind the curtain to see how Pantheon does what it does. We'll be introduced to the application container technology they use and review what software is running on your Pantheon environments, and get an overview of how caching works there.
Additional resources
All About Application Containers (pantheon.io)
In this tutorial we'll provide an overview of how to make your Pantheon sites take the best advantage of the robust infrastructure Pantheon provides. We'll discuss the balance of high performance and availability, along with a comparison of different server architectures and why Pantheon has chosen to use application containers. In that comparison we'll point out the pros and cons, and then we'll go through a checklist of the tools and techniques for optimizing your site for this architecture.
Additional resources
Optimizing Your Pantheon Site (pantheon.io)
Prepare for Launch
FreeWith everything on your site ready to go, the final step to a successful project is to launch it! In this presentation we'll outline the steps you'll need to take to get your site out in public, using your domain name. The Live environment has a public URL and technically your site is "out there" but it is using a subdomain of Pantheon. To set up your own domain and really launch the site, you'll need to make sure you're ready to launch and sign up for the right plan. In addition to reviewing the different plans, with guidance on how to pick the right one, we'll walk through a Drupal launch checklist to avoid common mistakes.
Additional resources
Going Live on Pantheon (pantheon.io)
In this tutorial we'll review the Pantheon plan choices, and explain how to pick the right one for your project. Each site gets its own plan, so you need to choose this based on each site's individual needs. You can also quickly and easily choose a plan, and send that information to your client to have them pay for getting things set up. This makes it super easy to hand over the project to the person or organization who needs to be the owner. We'll go ahead and actually choose a plan and get ready to launch our site.
Additional resources
Going Live on Pantheon (pantheon.io)
Your finally ready to share your site with the world! In this tutorial we'll walk through the process of launching our Pantheon site. We'll review all of the settings to add our domain name to the Live environment and explain how it all works.
Additional resources
Going Live on Pantheon (pantheon.io)
In this tutorial, I'll introduce the API Blueprint specification and take a look at a few tools we can use to provide documentation and testing for our API.
The tools we'll look at include:
By the end of the tutorial you'll have a better understanding of the API Blueprint specification and be able to use Dredd and Aglio to ensure your API documentation and testing stay up-to-date.
Self-check question: Could you write a script that could be run after every commit that would keep your documentation up-to-date, and provide API test results?
Additional resources
Object-Oriented PHP Part 3
CourseIn this series, we’ll continue to build the spaceship app that we’ve started in Introduction to Object-Oriented PHP and Object-Oriented PHP Part 2. In this tutorial, I’ll show you how to use the extends
keyword in PHP so that you can use it to inherit properties and methods from another class
.
Additional resources
In this tutorial, I will show you how to override a method that you’ve inherited from another class. By having two classes we are starting to shape the different behaviors and properties of each, while still keeping most things in common and not duplicated.
In this tutorial, I will show you the difference between public, private, and protected methods or properties in PHP classes. By the end of this lesson you will learn how to make things private at first, protected once you need to access them in a subclass, and public when you need to use it outside of its class and subclass.
Additional resources
In this tutorial, I will show you how to get around the problem of calling a function that you have overridden in your class: how to call the parent class method.
Additional resources
In this tutorial, I will show you how we can build a better blueprint and hierarchical structure for our app’s classes through the use of abstract classes.
Additional resources
In this tutorial, I will show you the power of abstract classes and how you can enforce subclasses to define certain functions. In this way, you can share logic but for things that are really specific to subclasses, you can force them to define certain functions, but with the specific logic required.
Additional resources
In this tutorial, I will show you how to extend an abstract class and ensure that all the methods that are required by the abstract class are included in this new class.
Additional resources
In this tutorial, I will show you how to handle new requirements for data storage by creating two smaller abstract classes out of our original data storage class. By creating these new abstract classes, we can build more flexibility into our code.
Additional resources
Now that we have created new abstract classes, we need to load and utilize them in our code. In this tutorial, I will show you how we can refactor our code to make use of our new abstract data loading classes.
We have an abstract class with methods that we require, but there’s no logic in these abstract methods. This is a perfect opportunity to use interfaces. In this tutorial, I will show you how to create and implement Interfaces. I will also explain how interfaces are useful when you will be sharing your code. But even if you’re not creating interfaces to share, chances are, if you’re using open source code — and definitely in Drupal — you will need to know how to implement interfaces.
Additional resources
Let's Write Some PHP
FreeSo you want to become a PHP developer. And not just any ole' programmer, but someone who writes great code and can work on exciting projects. Well then, this series from our partners at KnpUniversity is for you! You'll learn how to develop with PHP from the very beginning, with a real project, and coding exercises throughout the lessons so you can practice immediately.
In this series, we'll learn PHP from scratch by building a real website. This means you'll learn the practices used by developers to build really cool things, and not just a bunch of theory. We're going to build a site that we're calling AirPupnMeow.com. Imagine a site like Airbnb.com, except where people rent cute pets instead of apartments. If you're looking for companionship without all that responsibility of walking your dog every morning and bringing a bag to pick up his... uh gifts, then this site would be for you! Ok, the idea might be kinda silly, but that hasn't stopped startups in the past!
In this first lesson we are going to dive right in and create our first PHP file, play around with variables, and also look at what happens when we make an error, and how to read the error message we get. If you want to follow along with the steps here, you will need access to a web sever where you can write PHP files. You can get set up quickly with a number of local development servers. We have lessons that cover material for different operating systems in our Development Environments topic page.
Throughout this first series of PHP for Beginners, you are going to learn to:
- Use functions, and variables
- Work with arrays, loops, and if statements
- Read and update files
- Handle JSON
- Set up your computer to run PHP
- Create your own functions
- Organize your project into multiple files
- Create a simple layout