Using Drupal 7 with latest MAMP

in

After I updated my MacOS to 10.11.6 (El Capitan), older MAMP seemed stop working. So, I updated MAMP to the latest version, which is Version 4.1.

For the most part, it's working fine, but I noticed that one older Drupal 7 implementation stopped working. It caused White Screen of Death (WSOD). Upon investigation by adding the following code in index.php, I see that webform module is failing.

Specify php path (version) for Drush

in

I have set up drush on a shared hosting server, but one day, it suddenly stopped working. When I type drush, there's no output (just get the command prompt back).

It turns out that the default php version on the hosting server was 5.2, and for whatever reason, it doesn't contain Phar module now (not sure if it did, or something else had changed).

Running Postfix on Mac (El Capitan) with Gmail 2 step authentication

in

When testing Drupal on a local machine, it is handy to set up Postfix so that email capability can be tested.

Here's the steps, mostly from http://benjaminrojas.net/configuring-postfix-to-send-mail-from-mac-os-x-... , but modified to work with Gmail 2 step authentication.

0. Delete failed email

Drupal 8 Installation Memo

1. Download and configure the site as Drupal 7 (hostname, VirtualHost, Directory).
2. For MAMP, configure the preference to choose PHP 5.4 (or above), and disable cache.
3. Go to the site root folder from a browser.
4. Follow the instruction. A new database will be created.

Subversion 1.7 on a shared hosting (InMotionHosting and GoDaddy Linux hosting with cPanel)

I have managed to install svn on a shared hosting successfully (on InMotionHosting's business hosting plan and GoDaddy Linux hosting with cPanel). I needed the subversion (client only) with https protocol support.

Increase phpMyAdmin's upload limit

When restoring MySQL db, using phpMyAdmin is handy. But the file size for upload is limited to 8MB. Here's how to increase the limit.

1. Locate php.ini
http://localhost/phpinfo.php shows where's the php.ini.

2. Edit php.ini
upload_max_filesize
post_max_size
(optionally) memory_limit

3. Restart Apache
sudo apachectl restart

MAMP on Yosemite

After upgrading Lion on my MacBook Air to Yosemite, Apache failed to start. The solution is to rename (probably I could have deleted, but to be safe) the following file.

/Applications/MAMP/Library/bin/envvars

At first, just renaming seemed not working, but after a reboot, MAMP starts both MySQL and Apache no problem. Not sure why (or if) I needed to restart, though.

Compass on Yosemite

After upgrading Lion on my MacBook Air to Yosemite, I started to see the following error when running compass.

$ compass
-bash: /usr/bin/compass: /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby: bad interpreter: No such file or directory
?>

Using GD library PNG support on Mac OSX Yosemite

in

When I upgraded to my main machine to Yosemite, I've encountered a case that some images on Drupal installation doesn't generate image-style images. The status page shows that the GD library was not complied with PNG support.

The solution is to install the latest php. I followed the following page, basically to install php55 using home brew.

Installing Drush on Bluehost/Fastdomain

in

Installing Drush on the shared hosting server, such as Bluehost, is tricky. Here's what I did for Bluehost.

1. Install Composer
curl -sS https://getcomposer.org/installer | php

In my case, this created composer.phar on the home (current) directory. Moved it to ~/bin.

2. Check if composer runs

Syndicate content