Questions tagged [php]

PHP is a server-side scripting language used to build dynamic web pages.

Filter by
Sorted by
Tagged with
4
votes
5answers
11k views

Web Sharing Apache Localhost - Access permissions

I want to install phpMyAdmin on the native Apache webserver that is bundled with Mac OS X 10.6. I turned on Web Sharing in System Preferences. Yet, me fear is that my computer is granting access to ...
0
votes
0answers
27 views

launchd running php script fails under Catalina on exec diskutil

I have a php script that worked perfectly under Mojave from the terminal and as a launchd job. After changing to Catalina, the php script continues fine from the terminal, but the launchd job fails on ...
0
votes
0answers
10 views

Moving from MPM prefork to MPM event, without homebrew

I'm trying to move PHP to use the event model rather than prefork, using the default built-in Apache install on macOS Catalina. Everything works, except PHP (the default provided v 7.3). It seems that ...
6
votes
6answers
8k views

XAMPP VM and text editors

I recently installed XAMPP for OS X (XAMPP VM PHP 7.2.1) which now virtualizes the entire box for obvious benefits of higher security. Although I admire the new concept and see its benefits, I cannot ...
0
votes
1answer
103 views

mcrypt for PHP 7.4 on Catalina

First of all, I was born and raised using a PC so I'm kind of new to Mac. I was hoping if someone can help me out. I'm using Catalina and trying to get the PHP extension mcrypt installed. I've been ...
1
vote
2answers
4k views

OpenSSL 0.9.8zg used by PHP does not support TLSv1.2 or TLSv1.1

As part of the installation a PHP 5.4 cartridge from openshift.com on my Mac with OS X 10.10.5 in the Terminal I noticed a message about it loading OpenSSL 0.9.8 for compatibilty with PHP. Later, ...
1
vote
1answer
19 views

Laravel new [project] not working despite PHP, Composer, everything working

I'm trying to install laravel, but keep getting the "The Zip PHP extension is not installed. Please install it and try again." warning. Here's the thing: I've installed php7.3, entering 'composer' ...
1
vote
1answer
28 views

Installed Apache 2.4 (httpd) using Home Brew, can I get it to use macOS' php7?

I'm running macOS 10.15 (Catalina) and have installed the latest Apache (2.4.43) using brew, basically following these steps. Seems to be working fine, but now I want to enable PHP 7 in Apache as ...
1
vote
1answer
43 views

Extensions are disabled in `php.ini` and they still show up on `phpinfo.php`… why?

So, I finally decide it to switch from windows to Mac after 20 years, and I love it! I have so many questions... I've installed apache, php, mysql, imagemagick using homebrew and I have a couple of ...
0
votes
0answers
26 views

How to change the version of PHP used in the web browser on the OS X Server?

I am running OS X 10.12.6 on a Mac mini as a server that includes a WordPress site in addition to several web apps that utilize PHP, but version 5.6 is the one installed. I have been doing ...
2
votes
1answer
487 views

PHP not running after upgrading to Catalina

I've followed all the tutorials, updated httpd.conf and other files. Apache works fine but PHP does not seem enabled. Pointing to php_info.php => <?php phpinfo() ?> I formerly ran High Sierra ...
1
vote
1answer
78 views

502 Proxy error when trying to use Homebrew php72 with Server.app websites

I'm having a puzzling issue with a website on macOS server (server.app 5.6, High Sierra 10.13). All works fine when the url length is below 70 characters. 70 and up and I'm getting a Proxy error. The ...
0
votes
0answers
87 views

Change PHP on MacOS Server, High Sierra

I am using MacOS Server 5.6.1 running on a Mac Mini with High Sierra (10.13.6. It works completely fine and I've been hosting few Wordpress websites on it without any major troubles for couple of ...
0
votes
1answer
660 views

Unable to edit config.inc.php in the phpmyadmin configuration

I'm trying to edit a file on my mac. The file is config.inc.php of XAMPP located in /opt/lampp/phpmyadmin. Permission of the folder and file: Phpmyadmin -> drwxr-xr-x 12 root wheel 4096 Config.inc....
4
votes
2answers
565 views

Developer not identified error when logging in Oracle Instantclient on Catalina

I have the Oracle Instantclient installed (PHP needs it for the oci extension to work), the install directory is /opt/instantclient_19_3 and every time I log in after a reboot I get the following ...
12
votes
4answers
67k views

How to remove preinstalled Apache and PHP from Mac OS Sierra

I have been trying to figure out how to completely remove preinstalled Apache and PHP from my macbook pro ... The reason is that I am using the homebrew version of both Apache and PHP. The current ...
2
votes
0answers
106 views

Mac Terminal Slow after upgrading to PHP7.3

I had my Mid 2013 macbook air running Mojave (10.14.5) with PHP 7.1.23 updated to PHP 7.3 from https://php-osx.liip.ch/ using the command curl -s https://php-osx.liip.ch/install.sh | bash -s 7.3 . ...
0
votes
1answer
233 views

How do I fix macOS Mojave httpd syntax error in a localhost setup?

System details: OS Host: Mac OS Mojave PHP: 7.1.23 I am trying to set up my local server on a new Mac. I have been following the following instructions on https://discussions.apple.com/docs/DOC-...
0
votes
1answer
98 views

Upgrade PHP, not install additional PHP

My new work has just given me a MacBook Pro running macOS Sierra 10.12.6 to use as a development machine. It has PHP 5.6 installed and when I ran curl -s http://php-osx.liip.ch/install.sh | bash -s 7....
2
votes
1answer
47 views

PHP won't include files properly since updating to Mojave

On our office Mac, we have a local Apache server running through the software AMPPS. Prior to updating to Mojave, everything was working correctly. Now, after updating, there is an issue with using ...
0
votes
1answer
2k views

Stuck in upgrading PHP version on localhost Mojave

I'm trying to get PHP7.2 working on localhost, but phpinfo() keeps saying 7.1.19 is in place while ~php -v tells me PHP7.2.18 is in place. I run ~php -v it says: PHP 7.2.18 (cli) (built: May 2 ...
0
votes
0answers
1k views

Mcrypt Extension for Mojave's PHP 7.1 not using brew

I'm using macOS Mojave (10.14.3) and it already has apache2 and php 7.1 which are setup. I want mcrypt installed but all the info on the internet including this uses brew. I didn't install php using ...
7
votes
3answers
20k views

PHP not working after upgrading to OS Mojave

When i try to open localhost it gives me 403 error message like this "You don't have permission to access / on this server." I have tried changing the permission but nothing happens. It worked fine ...
1
vote
1answer
182 views

Tracing PHP process killed on Mac does not work

I'm running a simple PHP process that uses a tiny bit of memory and CPU. The max memory limit is 2G and the script is run from console. The memory used never exceeds 200 MB. CPU use fluctuates ...
11
votes
1answer
18k views

How can I determine the compile-time options of PHP?

I'm trying to customize my php install, but I'm not that familiar with compiling programs from scratch. How can I tell determine what compile-time options were used for php? Specifically, I'm trying ...
0
votes
0answers
912 views

PHP and Apache not working after upgrading to Mojave

I have a very similar question as this PHP not working after upgrading to OS Mojave so it's not a duplicate as I get a different error I had Apache and PHP working absolutely fine running on High ...
1
vote
1answer
108 views

launchd is not passing arguments to my PHP script

I'm having a weird problem. I use launchd to run a bunch of shell scripts that update content on my site. It was working fine when it was just calling scripts normally. But now I made the script a ...
1
vote
1answer
753 views

Issues installing Mcrypt PHP module

I am trying to install Mcrypt PHP module but encountering some issues: Version of PHP installed: 7.1.16 macOS version: macOS High Sierra 10.13.6 Is the following command that I am running correct? ...
0
votes
3answers
314 views

Give local PHP Full Disk Access in Mojave

I have a PHP webpage running on the local apache installation. The page uses shell_exec to access the messages/chat.db via sqlite3. shell_exec("sudo -u ben sqlite3 ~/Library/messages/chat.db \"...
1
vote
0answers
398 views

Installing and using CodeIgniter on macOS?

I followed this tutorial online and I'm currently running macOS High Sierra. I tried a simple rest API using PHP and now I'm trying to implement it using CodeIgniter3.x framework. The one I created ...
0
votes
1answer
3k views

localhost/phpmyadmin - 404 error on macOS High Sierra

I'm setting up a PHP project on my machine's loalhost. This part is working fine, and it's loading the index.php correctly when visiting http://localhost. However, visiting http://localhost/phpmyadmin ...
0
votes
1answer
693 views

PHP incredibly slow since upgrading macOS to 10.14 Mojave?

Since I upgraded my Mac to Mojave 10.14, I noticed PHP is incredibly slow. When I do this from the terminal: php -v It takes about 4-5 seconds before showing the version number, which is: PHP 7.1....
15
votes
2answers
20k views

How to install composer via homebrew

I'm really new to MacOS so maybe this is simple question. I'm using High Sierra with default PHP 7.1 installed, I've also installed PHP 7.2 running: curl -s http://php-osx.liip.ch/install.sh | bash -...
1
vote
0answers
136 views

How to set PHP alias for all users

This is probably easy, but I don't know how to set it for all users. So, when I run: which php it shows /usr/local/php5-7.2.0-20171215-181251/bin/php However I've just installed PHP using brew on ...
1
vote
1answer
445 views

System Integrity Protection (SIP) creating problem for oci_connect(): OCIEnvNlsCreate()

After I upgraded my OS to El Capitan (which comes with SIP), I am getting error in oci_connect() Warning: oci_connect(): OCIEnvNlsCreate() failed. There is something wrong with your system - please ...
4
votes
1answer
25k views

How to properly and for once reinstall PHP/Apache

So I'm struggeling with this since a long time and I'd like to find a proper solution. I have php5.4.. install and I want to upgrade to Php 7. No matter how hard I'm trying to do it I can't seems to ...
13
votes
7answers
39k views

How can I increase command line memory_limit for PHP with MAMP PRO?

I've edited every single php.ini on my Mac (at least all the ones found by "locate") and still can't seem to increase the memory_limit directive for PHP. I'm using MAMP PRO and running PHP scripts in ...
0
votes
2answers
2k views

Can't install php56-mcrypt with homebrew

I use Homebrew on my testing server on OS X. I have php56, autoconf, and mcrypt installed through homebrew. I was successful doing this on a different Mac but I am not having any luck this time. ...
1
vote
1answer
513 views

Current PHP version is 7.2.2 but localhost is running php56

I recently upgraded PHP through Homebrew. When using terminal command PHP -i I'm getting PHP Version => 7.2.2 as expected. However, when running phpinfo(); on localhost I get PHP Version 5.6.30 ...
0
votes
1answer
857 views

OSX 10.9.5 upgrade causes apache/php downgrade

Today I installed the OSX 10.9.5 upgrade and it appears to have downgraded my Apache and PHP version. Is there an easy way to reverse this unwanted downgrade? Or do I have to reinstall apache via ...
0
votes
2answers
340 views

iTerm2: Notice about PHP7.1

Every time I open a new iTerm2 window is shown the following warning: Warning: Use php@7.1 instead of deprecated homebrew/php/php71 Anyone can help me out please? I've uninstalled PHP, and ...
0
votes
1answer
2k views

403 forbidden on Apache vHost

I'm using Mac OS X 10.6.8 and I'm trying to configure a vHost. I configured it and it gave me a 403 Forbidden, and I'm having trouble giving _www permission to read/write in ~/Document/workspace/dev ...
1
vote
1answer
3k views

brew changes from php71 to php@7.1 on installation

I am trying to install php71 with the command brew install php71 but instead php@7.1 is installed. When trying to install redis with brew install php71-redis it's installing but not working with that ...
0
votes
1answer
67 views

Built-in Apache and Php is viable?

Does anybody has experience with using built-in Apache/PHP in a High Sierra? Does it have any drawbacks if compare to homebrew apache/php? I plan to use it with Laravel or GravCMS. Any thoughts?
0
votes
1answer
3k views

PHP not locating mcrypt while using MAMP

I'm using MAMP on a MAC. And in the php info page on MAMP, it says that mcrypt is enabled. However, when I run "php -m" on the terminal, I can't find mcrypt between the php modules. Any advice??
0
votes
1answer
1k views

Solve /Users/myusername/Sites/foo ~/bar localhost/~myusername High Sierra Apache server connection Internal Server Error

Battle of VirtualHost /Users/myusername/Sites/foo ~/bar Internal Server Error goin on for days now tryin to attach localhost/~myusername to Apache/2.4.28 http server on macOS 10.13.3 High Sierra ...
2
votes
0answers
72 views

PHP mail not sending (possible macOS Server or Firewall issue?)

This is a relatively complex problem and LONG description, so bear with me. Please ask questions in the comments if you think I can clarify something. I am hosting multiple websites on a single ...
0
votes
1answer
68 views

Use screencapture with PHP exec

I can't get screencapture to work work when triggered with exec() command. $output = exec("/usr/sbin/screencapture -R 0,0,450,150 hehe.png"." 2>&1"); echo $output; // in /System/Library/...
2
votes
1answer
214 views

Terminal could not find command “$ php -v”

I recently try to install ionCube loader and when I tried to check my PHP version via Terminal, it gave me an -bash: $: command not found. How can I fixed that?
4
votes
1answer
8k views

After MacOS High Sierra install, localhost fails and apache has syntax errors

After upgrading to MacOS High Sierra, I haven't been able to access my localhost. I tried restarting Apache, but it still didn't work. So I did apachectl configtest and got this error message: ...