- Go to home directory of wamp (For Example: c://wamp/www
- Download composer (If not installed)
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" php -r "if (hash_file('SHA384', 'composer-setup.php') === '544e09ee996cdf60ece3804abc52599c22b1f40f4323403c44d44fdfdd586475ca9813a858088ffbc1f233e9b180f061') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" php composer-setup.php php -r "unlink('composer-setup.php');";
-
Download the Zend Framework2
php composer.phar create-project zendframework/skeleton-application zf2
It will take few mins to download the zend framework. -
Copy the composer.phar to zf2 folder
cp composer.phar zf2
-
Go to zf2 directory
cd zf2
-
Virtual Host setup
Add following code in Apache setupDocumentRoot "D:\wamp\www\zf2\public" ServerName zf2.loc Options FollowSymLinks MultiViews AllowOverride All Order allow,deny Allow from all
We are Web Technology Experts Team who provide you Important information on Web Development, Interview Questions and Answers, live project problem and their solution and online free tutorials.
Friday 5 January 2018
How to install Zend Framework2 in Wamp Server window7?
Wednesday 20 December 2017
Encapsulation in PHP (OOP)
Question: What is Encapsulation?
The wrapping up of "Data member" and "Member functions" into a single unit (called class) is known as encapsulation.
Question: Describe the Encapsulation?
Encapsulation means hiding the internal details of an object.
OR
Encapsulation is a technique used to protect the information in an object from the other object.
Question: Give Example of the Encapsulation?
class Arithmetic { private $first = 10; private $second = 50; function add() { return $this->first + $this->second; } function multiply() { return $this->first * $this->second; } } //Create the object $obj = new Arithmetic( ); //Add Two number echo $obj->add(); //60 //multiply Two number echo $obj->multiply(); //500
Subscribe to:
Posts
(
Atom
)