Wednesday, June 15, 2016

The PHP Application Environment

phpenv

The following is a short extract from our recent book, Jump Start PHP Environment, available for free to SitePoint Premium members. Print and ebook copies are sold in stores worldwide, or you can order them here. We hope you enjoy this extract and find it useful.

This chapter will focus on the application environment. We’ll also discuss *AMP bundles such as XAMPP and why they’re a poor choice; production /development parity; and performance and debugging.

If you’re familiar with all these terms, feel free to skip this chapter.

Application Environments

The application environment is the term used to describe the environment your application can find itself in during various stages of its life cycle: the production environment, the development environment, and the staging environment.

The word environment refers to the hardware and software around your application; that is, everything used to power it.

Production

We’ll start with the most straightforward of environments: the production environment.

When you deploy your application―in other words, upload it to a server and make it publicly accessible for the target audience―you’re putting it in production, or in use. The production environment is your application’s final destination, your code’s purpose.

In an application’s life cycle, the production environment is the live server―a server computer that's set up so that other people can connect to it and see your website. This live server will be configured to serve your application as efficiently as possible. All the extra files you used during development will be removed from the application via a process known as compiling or building, which is explained further on.

When in production, your site is considered to be live (or deployed) and will be accessible via its own domain; for example, http://mysite.com. When you launch your site (put it into production mode), you have cause for celebration, because this is the final step in your application’s development process.

It is the equivalent of a chef cooking a meal in a restaurant and having it delivered to the patrons who ordered it.

Development

In the development environment, your application is being actively developed. The development environment is the computer you as the developer are using to develop the app, including the computers of all your team members, regardless of whether they are near you or remote. It is important to note that despite covering both aspects, the development environment refers more to the state your app is in, rather than its physical location―the app is in the state of being developed.

In the development environment, you have various tools at your disposal―from IDEs (see Chapter 2) to unit testing libraries and standards fixers, compilers and builders, file watchers, and more―anything you need to achieve the job at hand.

If we compare our application to a smartphone, the assembly plant it’s being made in is the development environment. This environment contains all the necessary parts―the screen, the case, the battery, the various LEDs―and each part is individually tested before being used in the construction of a smartphone unit. This is called unit testing―ensuring each unit works.

For an example of unit testing in application development, see the section called “For Those Who Want More” at the end of this chapter.

To take the smartphone assembly analogy further, the battery being tested might require a separate charger attachment, or the screen may need to be tested using a robotic arm with synthetic fingers to ensure that the screen’s touch sensitivity works.

robot

All these add-ons are there during development only. When converting from the development environment to the production environment (also known as deploying), these add-ons are removed. For our application, this means the aforementioned compilation/building step: various CSS and JavaScript files are merged together and shrunk so as to decrease the size of the website, making it appear faster when people visit it; unit tests are ignored and left behind in the development environment; and various other optimizations occur (covered later in the chapter)―all with the intention of making the final product maximize its appeal and potential when declared ready.

Hosts and Virtual Hosts

When you develop on your own computer, it’s impossible to visit the URL http://mysite.com and expect to see your site; after all, your site is yet to go live―it’s not on the Internet. To get around this and see our site as if it were live, we fake the Internet by defining virtual hosts.

Continue reading %The PHP Application Environment%


by Bruno Skvorc via SitePoint

This Week's HTML5 and Browser Technology News (Issue 244)


Read this e-mail on the Web
HTML 5 Weekly
Issue 244 — June 15, 2016
Google
A look at the themes and trends for the popular Chrome DevTools going forward, including an improved ‘Device Mode’, source diffing, and live Sass editing.


Steve Faulkner
Originally, headings were meant to nest within sectioning elements, but in actual user agents, things haven’t worked out as originally intended.


jQuery Foundation
A slimmer, faster version of jQuery without all the old IE workarounds and taking advantage of modern browser APIs. There’s an upgrade guide and a script to help with migrations.


Frontend Masters  Sponsored
Create resolution-independent, scalable, complex animations for a myriad of use cases across the web with SVG.

Frontend Masters

Stuart Memo
A fun tutorial from browser-based musical mastermind Stuart Memo on tying up the Web Audio API and pointer location to recreate an early electronic instrument.


W3C
At WWDC, Apple announced its “Pay” system will become available on the Web, and Apple’s Edward O’Connor wonders if the existing Payment Request API could become compatible with it.


Juriy Zaytsev
Building on top of open source tools helped improve the quality of CSS at Facebook and set the stage for community-wide rules and guidelines.


Joseph Pecoraro
Web Inspector, as used in WebKit and Safari, now includes two new timelines for debugging a page’s memory usage.


Telerik Developer Network
Jared Faris discusses the most important new features in web standards, in particular JavaScript, that you should be watching carefully.


Jobs

  • Frontend Developer at X-Team (Remote)We're looking for a developer with extensive knowledge of HTML5, CSS3 and JavaScript. We are 100% remote and we provide the funding needed to help you achieve your goals and grow as a remote developer. X-Team
  • The Easiest Way to Find a JobHired lets you sit back while job offers come to you. When you complete your profile, instantly apply to 3,500+ companies on the platform who will contact you with job offers, including salary and equity up-front. Try it today. Hired.com

In brief

Curated by Peter Cooper and published by Cooper Press.
Want to post a job? E-mail us or use our self-serve system.

Unsubscribe : Change email address : Read this issue on the Web

Published by Cooper Press Ltd. Office 30, Lincoln Way, Louth, LN11 0LS, UK


by via HTML5 Weekly

Get Started With Mobile Game Development

At this week's E3 expo, the latest mobile games are sure to create a buzz. But what if you want to get started in this growing field yourself? How do you learn how to develop games for Android or iOS?

iOS Game Development

For iOS, a great way to get started is by taking our Game Development With Swift and SpriteKit course. In it, Derek Jensen walks you through the basics of building a simple game for the iPhone from scratch using SpriteKit. You'll learn to create scenes, introduce gravity, detect collisions, and much more.

If you want to learn more about Apple's Swift 2 programming language, check out Derek's comprehensive course, Up and Running With Swift 2. The course consists of 30 lessons and almost five hours of video instruction, covering everything from controlling flow to working with collections. It really is a solid foundation for creating iOS apps.

Android Game Development

For Android, a similar foundational course would be Getting Started With Android. In the course, Paul Trebilcox-Ruiz takes you step by step through the process of native Android development, from setup to creating a finished app.

Once you've got that under your belt, you can try Gaming With the Corona SDK. Corona is a high-performance SDK that exports as a native application for both Android and iOS from a single codebase. Rather than spending time looking at various APIs of Corona, this course instead takes a game-centric approach. You'll learn the fun parts of Corona, specifically for making your own game.

Start Learning With a Free Trial

You can take our full range of game development courses with a free 10-day trial of our monthly subscription. And over on Envato Market, you can find hundreds of mobile game app templates to give you a starting point for creating your own games.

Still looking for more resources? Have a look at these free game development tutorials:

  • Business
    How to Make Your Own Game
    Steven Lambert
  • How to Learn
    How to Learn the Phaser HTML5 Game Engine
    Richard Davey
  • From Scratch
    Danger Droids: Create a Platformer in GameSalad, Step by Step
    Jamie Cross
  • How to Learn
    How to Learn Pygame
    Aditya Keerthi
  • Shaders
    A Beginner's Guide to Coding Graphics Shaders
    Omar Shehata



by Andrew Blackman via Envato Tuts+ Code

Create a 'Conversation' Banner With Revolving Text in WordPress: Part 1

This Week in Mobile Web Development (#112)

Read this on the Web

Mobile Web Weekly June 15, 2016   #112
Peter Cooper recommends
Apple Pay Is Coming to The Mobile Web — Apple announced at its WWDC keynote that it will be expanding its popular Apple Pay system to mobile web browsers.
Engadget
Holly Schinsky recommends
Google Preparing Big Optimizations For Chrome 53, 47% Improvement On Motion Mark By WebKit — Chrome 53 will be out in September and promises large improvements across the board due to all the optimizations it contains.
Phil Oakley
Brian Rinaldi recommends
Our Web Obesity Epidemic — Sites are getting too big for a mobile world, and progressive web apps and AMP (both from Google) offer some potential solutions, with constraints.
Dion Almaer
Sponsored
Work on a Better Stack — On Hired, engineers typically get 5+ job offers in 1 week. Find that new opportunity you've been craving and get access to 3,500+ companies instantly.
Hired.com

Brian Rinaldi recommends
Page Speed Will Soon Affect Mobile Rankings — At the Search Marketing Summit, Google said that it is planning to use mobile page speed as a key metric for the ranking of mobile pages in the future.
PureContent
Holly Schinsky recommends
How to Create An Instagram-Like App with Ionic 2
Janez ÄŚadeĹľ's blog
Peter Cooper recommends
How Mobile Is Overtaking Desktop for Global Media Consumption, in 5 Charts — Mobile internet use is continuing strong growth past normal computers, while use of all other traditional media is shrinking, new research shows.
Jemm Brackebush
Brian Rinaldi recommends
Progressive Web Apps – Let’s Not Repeat The Errors From The Beginning of Responsive Web Design — Don’t concentrate on device-specific solutions.
Michael Scharnagl
Chris Brandrick recommends
The Mobile App Comparison Chart: Hybrid Vs. Native Vs. Mobile Web — A comparison chart looking at all the developer differences and feature sets of differing mobile web options.
Joe Stangarone
Holly Schinsky recommends
Time Travel in React Redux apps using the Redux DevTools — How to integrate the Redux DevTools in your hybrid React apps to use for debugging and time travel.
Onsen UI
Brian Rinaldi recommends
Most Online Ads Suck — The data from Mary Meeker’s Internet Trends Report shows that we need to make better ads and target them for mobile.
Steve Ellis
Brian Rinaldi recommends
Progressive Web Apps Isn’t A Google-Only Thing — Progressive Web Apps isn’t a technology, but a terminology which describes rich websites.
Arthur Stolyar
Sponsored
Try RASON™ – And Start Using Advance Analytics in Your Web/Mobile Apps — Solve powerful optimization & simulation models in your app easily with RASON®. Use a high-level modeling language embedded in JSON, & a simple, Azure-backed REST API.
RASON.com by Frontline Systems Inc

Holly Schinsky recommends
The Coolest New Features of iOS 10 — Apple’s latest iOS 10 for mobile devices is the company’s biggest release ever, offering new features like image recognition in Photos, a revamped Music app and a new home automation app called Home.
Justin Yu
Holly Schinsky recommends
TPDP Episode #6: PouchDB and its Usefulness in Development — If you’re looking to manage and synchronize data in your hybrid apps, learn how PouchDB to see how it can make the task significantly easier.
Nic Raboy / Nolan Lawson
Holly Schinsky recommends
New App Store Review Guidelines — Apple announced it has updated their app store review guidelines to be better organized and provide more context.
Apple Developer
Brian Rinaldi recommends
Install Xcodeproj For NativeScript iOS Development on Mac OS — Nic Raboy shows how to install the Xcodeproj tool to manage Xcode projects from Ruby, so you can do NativeScript iOS development.
The Polyglot Developer
Holly Schinsky recommends
vue-framework7 — Framework7 components built with Vue.js; reactive components for modern web interfaces.
vue-framework7
Job listing
Web Developer at William Hill, Gibraltar — Are you are a Web Developer with excellent JavaScript coding skills? Our ideal candidate would be someone who enjoys JavaScript and has an interest to work cross-functions, pro-active throughout, with a focus on delivery.
William Hill

Curated by Brian Rinaldi and Holly Schinsky for Cooper Press.
Cooper Press is located at Office 30, Fairfield Enterprise Centre, Louth, LN11 0LS, UK
Update your email address
or stop receiving MWW here


by via Mobile Web Weekly

Studioyonis

opl-small

Minimal One Pager for Studioyonis featuring full screen imagery that is browsable using your keyboard arrows or by dragging your cursor. Vertical browsing reveals more on the project and horizontally switches between projects.

by Rob Hope via One Page Love

26 Tips to Improve Your Pinterest Marketing

ag-26-pinterest-tips-600

Could your Pinterest marketing use a jumpstart? Are you curious about what’s working for other businesses? Tweaking techniques that have been successful for others can help you drive traffic, connect with your target audience, and increase sales. In this article, you’ll discover 26 tips to improve your Pinterest marketing. #1: Share Pin It for Later Links [...]

This post 26 Tips to Improve Your Pinterest Marketing first appeared on .
- Your Guide to the Social Media Jungle


by Ana Gotter via