Quick Start to Symfony-classic tutorial _ php instance

Source: Internet
Author: User
This article mainly introduces the ten-minute tutorial on Symfony, detailed the basic operation skills such as Symfony installation configuration, project initialization, Bundle creation, design entity, constraint addition, addition, deletion, modification, and query, for more information, see Symfony, a powerful PHP-based Web development framework. Here we will spend ten minutes to create a simple program for adding, deleting, modifying, and querying, anyone unfamiliar with Symfony can complete their first Symfony program through this tutorial.

If you need all the source code of this sample program, you can access it or obtain the source code in the following way:

$ Git clone https://github.com/saharabear/symfony-sample.git

Project Initialization

First, you need to install the PHP environment on your computer and install git. this is the basic content, and there are a lot of tutorials on the network. I will not introduce them here, but I should note that PHP starts from 5.4, the test server has been built in, and Symfony embraces this built-in PHP server. You only need to use $ php app/console server in the command line: run can start a PHP program based on the Symfony framework for testing. Therefore, you do not need to use the xampp complex integration environment, install PHP directly and make sure that you can execute the php Command under the command line.

Then, we need to create a new directory named symfony-sample. Symfony uses a program named composer to manage the dependencies of various class libraries. Therefore, if composer is installed on your machine, you can skip this step. If not, you can use the following command to install the latest version of composer.

$ Cd symfony-sample $ curl-sS https://getcomposer.org/installer | php

If you want to know

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.