I am looking the method that Manually Installation of PHP, No Homebrew(Package Installation), Just .tar archive only. I've searched few days on Google, but I still can't find the proper method.
Looking the Method that MANUALLY INSTALL PHP on OSX Yosemite
162 Views Asked by ISOs At
2
There are 2 best solutions below
0
Harold
On
This should do the trick to compile it manually: http://php.net/manual/en/install.macosx.compile.php
Related Questions in PHP
- Two different numbers in an array which their sum equals to a given value
- how to fill out the table with next values in array with one button
- How to sort a multi-dimensional array by the second array in descending order?
- Looping over defined array elements in Fortran
- Array appending after each onclick and loop in javascript
- PHP : How can I check Array in array?
- store numpy array in mysql
- Java Assign a Value to an array cell
- Saving FileSystemInfo Array to File
- Notice: Undefined offset: 1, but there is such offset
Related Questions in APACHE
- Two different numbers in an array which their sum equals to a given value
- how to fill out the table with next values in array with one button
- How to sort a multi-dimensional array by the second array in descending order?
- Looping over defined array elements in Fortran
- Array appending after each onclick and loop in javascript
- PHP : How can I check Array in array?
- store numpy array in mysql
- Java Assign a Value to an array cell
- Saving FileSystemInfo Array to File
- Notice: Undefined offset: 1, but there is such offset
Related Questions in WEB-SERVICES
- Two different numbers in an array which their sum equals to a given value
- how to fill out the table with next values in array with one button
- How to sort a multi-dimensional array by the second array in descending order?
- Looping over defined array elements in Fortran
- Array appending after each onclick and loop in javascript
- PHP : How can I check Array in array?
- store numpy array in mysql
- Java Assign a Value to an array cell
- Saving FileSystemInfo Array to File
- Notice: Undefined offset: 1, but there is such offset
Related Questions in OSX-YOSEMITE
- Two different numbers in an array which their sum equals to a given value
- how to fill out the table with next values in array with one button
- How to sort a multi-dimensional array by the second array in descending order?
- Looping over defined array elements in Fortran
- Array appending after each onclick and loop in javascript
- PHP : How can I check Array in array?
- store numpy array in mysql
- Java Assign a Value to an array cell
- Saving FileSystemInfo Array to File
- Notice: Undefined offset: 1, but there is such offset
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Before thinking about installing PHP manually in your OS X, I would like to give you some updates regarding OS X Yosemite.
[1] Yosemite includes Apache 2.4, so you don't need to worry about Apache installation.
[2] Mac OS X runs atop UNIX. So most UNIX software installs easily on Mac OS X. Furthermore, Apache and PHP come packaged with OS X. To create a local web server, all you need to do is enable them and install MySQL.
Now here is step by step process to install PHP and Mysql -
First, open the Terminal app and switch to the root user to avoid permission issues while running these commands.
sudo su -
Enable Apache on Mac OS X by this command.
apachectl start
Now you can check localhost by accessing http://localhost . If it is working it will show it works!
Before enabling PHP for apache create a backup of the default Apache configuration which will be helpful for comparison against future versions of Mac OS X and then enable PHP for APACHE -
cd /etc/apache2/
cp httpd.conf httpd.conf.bak
Now edit the Apache configuration. Feel free to use TextEdit if you are not familiar with vi.
vi httpd.conf
Uncomment the following line (remove #):
LoadModule php5_module libexec/apache2/libphp5.so
Restart Apache:
apachectl restart
You can verify PHP is enabled by creating a phpinfo() page in your DocumentRoot.The default DocumentRoot for Mac OS X Yosemite is /Library /WebServer/Documents. You can verify this from your Apache configuration.
grep DocumentRoot httpd.conf
Now create the phpinfo() page in your DocumentRoot:
echo '<?php phpinfo();' > /Library/WebServer/Documents/phpinfo.php
Verify PHP by accessing http://localhost/phpinfo.php
Install Mysql on OS X :
Download the MySQL DMG for Mac OS X
Install MySQL
The README suggests creating aliases for mysql and mysqladmin. However there are other commands that are helpful such as mysqldump. Instead, I updated my path to include /usr/local/mysql/bin.
export PATH=/usr/local/mysql/bin:$PATH
Note: You will need to open a new Terminal window or run the command above for your path to update.
I also run mysql_secure_installation. While this isn’t necessary, it’s good practice.
Connect PHP and MySQL
You need to ensure PHP and MySQL can communicate with one another. There are several options to do so. I do the following:
cd /var
mkdir mysql
cd mysql
ln -s /tmp/mysql.sock mysql.sock
Additional Configuration (optional)
The default configuration for Apache 2.4 on OS X Yosemite seemed pretty lean. For example, common modules like mod_rewrite were disabled. You may consider enabling this now to avoid forgetting they are disabled in the future.
I edited my Apache Configration:
vi /etc/apache2/httpd.conf
I uncommented the following lines (remove #):
LoadModule deflate_module libexec/apache2/mod_deflate.so
LoadModule expires_module libexec/apache2/mod_expires.so
LoadModule rewrite_module libexec/apache2/mod_rewrite.so
So these were the steps to install PHP Manually .I hope it will be helpfull. :-)