• Complain

Mark Robert Henderson - Instant CakePHP Starter

Here you can read online Mark Robert Henderson - Instant CakePHP Starter full text of the book (entire story) in english for free. Download pdf and epub, get meaning, cover and reviews about this ebook. year: 2013, publisher: Packt Publishing, genre: Computer. Description of the work, (preface) as well as reviews are available. Best literature library LitArk.com created for fans of good reading and offers a wide selection of genres:

Romance novel Science fiction Adventure Detective Science History Home and family Prose Art Politics Computer Non-fiction Religion Business Children Humor

Choose a favorite category and find really read worthwhile books. Enjoy immersion in the world of imagination, feel the emotions of the characters or learn something new for yourself, make an fascinating discovery.

Mark Robert Henderson Instant CakePHP Starter
  • Book:
    Instant CakePHP Starter
  • Author:
  • Publisher:
    Packt Publishing
  • Genre:
  • Year:
    2013
  • Rating:
    3 / 5
  • Favourites:
    Add to favourites
  • Your mark:
    • 60
    • 1
    • 2
    • 3
    • 4
    • 5

Instant CakePHP Starter: summary, description and annotation

We offer to read an annotation, description, summary or preface (depends on what the author of the book "Instant CakePHP Starter" wrote himself). If you haven't found the necessary information about the book — write in the comments, we will try to find it.

Learn something new in an Instant! A short, fast, focused guide delivering immediate results.
Focus on an iterative practical approach to learn the myriad features of CakePHP
Learn about Models, Views, and Controllers as well as scaffolding, themes, behaviors, and routing
Scaffold and generate your application code using the command-line bake tool almost exclusively

Mark Robert Henderson: author's other books


Who wrote Instant CakePHP Starter? Find out the surname, the name of the author of the book and a list of all author's works by series.

Instant CakePHP Starter — read online for free the complete book (whole text) full work

Below is the text of the book, divided by pages. System saving the place of the last page read, allows you to conveniently read the book "Instant CakePHP Starter" online for free, without having to search again every time where you left off. Put a bookmark, and you can go to the page where you finished reading at any time.

Light

Font size:

Reset

Interval:

Bookmark:

Make
Chapter 1. Instant CakePHP Starter

Welcome to Instant CakePHP Starter . This book is designed to get a CakePHP app "out the door" in a fast, efficient, and agile manner. We're literally going to go from installation to production deployment in just a few pages.

Strap in!

This book contains the following sections:

So, what is CakePHP? is a technological look at Cake and the MVC architecture.

Installation will soon have you running a Cake app in a production environment. Don't worry; it's not as scary as it sounds.

Quickstart building a web application uses an iterative approach where we will easily craft our application's core functionality using some fundamental features of Cake, and send our updates to the production server.

Top 6 features you need to know about gets us playing with the full power of our stack, and Cake can become what it was born to be!

People and places you should get to know lets you determine your own level of involvement! This section facilitates this with a peek into the CakePHP community: blogs, Twitter feeds, documentation, and more. In short, it covers the entire CakePHP-centric Internet.

So, what is CakePHP?

CakePHP is like the little buddy that lives on your shoulder and helps you out while you're developing a site. It helps you do it quickly, and organizes your code in a way that allows you and other developers to quickly understand what's going on.

CakePHP the short story

Here's the definition of CakePHP we'll be using for the purposes of this book:

CakePHP is a Model-View-Controller framework implemented in the PHP programming language. Its aim is to take the repetitive tasks out of your way, provide structure to your code by focusing on convention instead of configuration, and to "harden" your application with an important layer of security.

Why CakePHP making the short story long

This story is about you, either now or some time in the past. You have some experience of writing HTML/CSS code and maybe a bit of JavaScript. You've marked up some static web pages and now you want to delve into the world of web application development.

You set forth with an idea for an app, and some time later you've pieced it all together. To your delight, it does exactly what you wanted it to donothing more, nothing less. You release it to the public and, harnessing the momentum and exhilaration, you decide to take a break from e-mails so you can start working on your next project.

As you begin to write your next app, you find yourself saying "Wait a minute, I already wrote a login system..." but when you look at your login code you find that it's so specific to your previous application that you can barely reuse any of it. Writing that system was fun then, but it is tedious now. Now you just want to get to the meat of your app and not worry about any of this!

Having had the wind sucked out of your sails, you decide to get back to your e-mail. Your heart sinks furtherbug reports have started coming in; not just small formatting bugs but "big" bugs involving security. Nobody told you to sanitize your input! And what is a cross-site scripting attack?

You don't have time for this. You want to work on your next app, not spend time fixing this one! You decide to bring another developer on to help, but your code base is so specific to both you and the application that you spend as much time answering his questions and explaining the choices that you made in the code as you would have spent just fixing it yourself.

Finally, the bugs all get fixed, but because there was no testing framework or official definition of the functionality, the bug "fixes" broke other parts of the site, and caused more bugs!

You're not sure what happened, or how this all could have been avoided.

Getting the point?

CakePHP to the rescue!

The benefit of using a framework like CakePHP is that a lot of this work is already done, and a lot of these problems already solved. There are many frameworks like CakePHP, but CakePHP's focus on rapid development and simplicity puts it in a class of it's own. Also, a strong community is important around any technology, and I can say without hesitation or irony that CakePHP's community is unmatched.

Out of the box, Cake provides:

  • User session management (via cookies or sessions)
  • Request handling (via GET and POST)
  • E-mail support
  • A well-tested security layer that includes CSRF protection and data sanitation
  • Multiple caching mechanisms
  • Integrated CRUD (Create, Retrieve, Update, Delete) for your datastore
  • Model validation (required fields, valid e-mail, and so on)
  • Data sanitation
  • Code generation (both PHP and HTML)
  • A unit testing framework complete with code coverage support for both your app and the core itself
  • A standard coding convention, project structure, and suggested code standard
  • A robust view-helper library that handles AJAX, pagination, forms generation, static file inclusion, and more

In addition to that, there is an active community built around the framework to which you can always go for support and inspiration. Check out http://community.cakephp.org.

Model-View-Controller what is that all about?

An entire book could be written on this subject alone, so we'll only broach the subject here.

Model-View-Controller is what is known as a design pattern, and is based around separating components of code based on their responsibilities. Models refer to the data layer, views refer to the presentation layer, and controllers contain your application or business logic.

This concept was invented (among many, many other things) in the 70's at Xerox Parc when they were building the first GUIs. It is one of the (if not the) oldest pattern in GUI programming.

For more information about the MVC design pattern, please see the section titled Top 6 features you need to know about .

Installation

This section is divided into our three main areas of concern: our development environment, our application, and our deployment environment.

We are going to intentionally obfuscate the development environment in these examples, because everybody's development environment is going to be different. Yes, there are typically two or three main environments (PC, Mac, Linux), but everybody's own style and conventions are different. Also, CakePHP is designed to run on any platform, so Windows should be running it just as well as any *nix-based system such as Linux or Mac.

Tip

Downloading the example code

You can download the example code files for all Packt books you have purchased from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.

Step 1 preparing the development environment

Before we begin, let's ensure that a few things are in place: an HTTP server, a database layer, the PHP scripting language, and source control.

As far as our operating system goes, we are going to stay as agnostic as possible. The file paths are Windows-based because we used Windows to write and create the examples in this book, but Unix file paths are perfectly acceptable as well. Do not panic.

The HTTP server (Apache)

The web server software should be set up and running. You should be able to visit http://localhost or http://127.0.0.1/ in your web browser and see an Apache test page.

Next page
Light

Font size:

Reset

Interval:

Bookmark:

Make

Similar books «Instant CakePHP Starter»

Look at similar books to Instant CakePHP Starter. We have selected literature similar in name and meaning in the hope of providing readers with more options to find new, interesting, not yet read works.


Reviews about «Instant CakePHP Starter»

Discussion, reviews of the book Instant CakePHP Starter and just readers' own opinions. Leave your comments, write what you think about the work, its meaning or the main characters. Specify what exactly you liked and what you didn't like, and why you think so.