Support / KnowledgeBase

 
Search the KnowledgeBase Search
feedCurrently Browsing: PHP and Coding
Launch

Working with a hacked or compromised server Applies to: (gs) Difficulty: Medium Time Needed: 20 Tools Required: SFTP Applies to: All (dv) Difficulty: Medium Time Needed: 20 Tools Required: SFTP NOTE: Remember that it is your responsibility to maintain the security of any scripts or applications you choose to install and use on y ... Applies To: (gs), All (dv)

Launch

How do I redirect my site using a .htaccess file? Applies to: All Service Types Difficulty: Medium Time Needed: 10 Tools Required: FTP, plain text editor Overview This document will explain how to create a .htaccess file to redirect your site or site content. This will not redirect any emails for your domains. READ ME FIRST As a conf ... Applies To: All Service Types

Launch

How can I specify the PHP version on the (gs) Grid-Service? Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access, plain text editor, FTP client Overview At this time, the (gs) Grid-Service offers two versions of PHP, in the form of "PHP-Stable" (5.3.23) and "PHP-Latest" (5.4.13). These builds of PHP include the ... Applies To: (gs)

Launch

Installing PECL extensions Applies to: (gs) Difficulty: Medium Time Needed: 20 Tools Required: SSH, vi knowledge Applies to: (dv) Difficulty: Medium Time Needed: 20 Tools Required: SSH, vi knowledge Overview PECL is a repository for PHP Extensions, providing a directory of all known extensions and hosting facili ... Applies To: (gs), All (dv)

Launch

How do I enable CloudFlare? Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Applies to: (ve) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Overview CloudFlar ... Applies To: (dv) 4.0, (gs), (ve)

Launch

Using Cron Applies to: (dv) 4.0 Difficulty: Easy Time Needed: 10 Tools Required: Plesk administrator access Applies to: (dv) 3.5 Difficulty: Easy Time Needed: 10 Tools Required: Plesk administrator access Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Ove ... Applies To: (dv) 3.5, (dv) 4.0, (gs)

Launch

Using Environment Variables in PHP Service Type: (gs) Grid-Service Difficulty: Medium Time Needed: 10 Tools Required: None Environment variable definition PHP environment variables allow your scripts to glean certain types of data dynamically from the server. This supports script flexibility in a potentially changing ser ... Applies To: (gs)

Launch

Using .htaccess files Applies to: (gs) Difficulty: Medium Time Needed: 20 Tools Required: FTP, plain text editor Applies to: All (dv) Difficulty: Medium Time Needed: 20 Tools Required: FTP, plain text editor Introduction The .htaccess file is a powerful tool for modifying your Apache configuration on a per ... Applies To: (gs), All (dv)

Launch

How do I redirect my site using a META Tag? Applies to: All Service Types Difficulty: Medium Time Needed: 10 Tools Required: FTP or SSH, plain text editor Overview This document will explain how to create a META Tag to redirect your site or site content. This will not redirect any emails for your domains, however. READ ME FIRST ... Applies To: All Service Types

Launch

MIME Types Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: SSH Use and configure MIME types Various mime types are pre-configured for use on our (gs) Grid-Service & (dv) Dedicated-Virtual Servers. If you would like to add a custom mime-type for use on your website, you can do ... Applies To: (dv) 3.5, (dv) 4.0, (gs)

Launch

Generate API key Applies to: API, All Service Types Difficulty: Easy Time: 5 Tools needed: AccountCenter access An API key is required when you wish to develop applications to help manage and monitor your (mt) Media Temple hosting services. Generate your API key Sign into your AccountCenter. From the ... Applies To: API

Launch

Using .htaccess rewrite rules Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: Plain text editor, FTP Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: Plain text editor, FTP Applies to: (ve) Difficulty: Easy Time Needed: 10 Tools Required: Plain text editor, FTP Overview The ... Applies To: (gs), (ve), All (dv)

Launch

How do I set the path for open_basedir? Applies to: (gs) Difficulty: Medium Time Needed: 10 Tools Required: Plain text editor, FTP client or AccountCenter access Applies to: (dv) 4.0 Difficulty: Medium Time Needed: 10 Tools Required: SSH, root access, vi knowledge Applies to: (dv) 3.5 Difficulty: Medium Time Needed: 10 Tools Re ... Applies To: (dv) 3.5, (dv) 4.0, (gs)

Launch

How can I use PEAR on my (mt) Media Temple server? Applies to: (gs) Difficulty: Medium Time Needed: 20 Tools Required: SSH Applies to: (dv) Difficulty: Medium Time Needed: 10 Tools Required: SSH Overview PEAR is short for PHP Extension and Application Repository and is pronounced just like the fruit. The purpose of PEAR is to provide: ... Applies To: (gs), All (dv)

Launch

Why is allow_url_fopen disabled on the (gs) Grid-Service? Applies to: (gs) Difficulty: Medium Time Needed: 10 Tools Required: FTP, plain text editor or SSH access, vi knowledge Overview The PHP parameter allow_url_fopen has been disabled in our PHP environment for the (gs) Grid-Service. If enabled, allow_url_fopen allows PHP's file functio ... Applies To: (gs)

Launch

How can I edit the php.ini file? Applies to: (gs) Grid-Service Difficulty: Medium Time Needed: 20 Tools Required: AccountCenter access, SSH enabled, FTP client, plain text editor Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: SSH, root access Overview The php.ini file is the default configurat ... Applies To: (gs), All (dv)

Launch

Why does my alternate domain display a blank page? Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Symptoms You have already pointed your domain to (mt) Media Temple and uploaded your content to /domains/gs-example.com/html/. However, when you visit the domain in your browser, it shows a completely ... Applies To: (gs)

Launch

Common SSH Commands Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: SSH Applies to: (gs) Difficulty: Medium Time Needed: 20 Tools Required: SSH Overview This article is an introduction to finding your way around your server in SSH. It takes a Day 1 approach to SSH. Hit Enter or Re ... Applies To: (gs), All (dv)

Launch

Password protecting directories Applies to: (gs) Difficulty: Easy Time Needed: 20 Tools Required: AccountCenter access or SSH, FTP client Applies to: (dv) 4.0 Difficulty: Easy Time Needed: 10 Tools Required: Plesk administrator access or SSH, FTP client Applies to: (dv) 3.5 Difficulty: Easy Time Needed: 10 Tools Requi ... Applies To: (dv) 3.5, (dv) 4.0, (gs)

Launch

How can I enable Zend on the (gs) Grid-Service? Applies to: (gs) Difficulty: Hard Time Needed: 20 Tools Required: SSH access or FTP and AccountCenter access Overview Zend Guard Loader is a free runtime application that enables PHP to run the scripts encoded by Zend Guard. Zend is a trademark of Zend Technologies Ltd. NOTE: If your sc ... Applies To: (gs)

Launch

Increase PHP security with PHPSecInfo Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: FTP client Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: FTP client Overview PHPSecInfo provides the security equivalent of the phpinfo() function. It is not a replacement for secure development ... Applies To: (gs), All (dv)

Launch

How do I install Drupal using the 1-Click Applications tool? Applies to: (gs) Difficulty: Easy Time Needed: 20 Tools Required: AccountCenter access Overview Drupal is a free and open source content management system (CMS) written in PHP and distributed under the GNU General Public License. This article will show you how to install Drupal using th ... Applies To: (gs)

Launch

Is ImageMagick installed on the (gs) Grid-Service? Applies to: (gs) Difficulty: Medium Time Needed: 10 Tools Required: SSH Overview ImageMagick is a software suite to create, edit, and compose bitmap images. It can read, convert, and write images in a variety of formats. The functionality of ImageMagick is typically utilized from the co ... Applies To: (gs)

Launch

Prevent hotlinking with a .htaccess file Applies to: (gs) Difficulty: Medium Time Needed: 15 Tools Required: FTP client, plain text editor Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: FTP client, plain text editor Overview Hotlinking refers to linking directly to non-html objects on other servers, s ... Applies To: (gs), All (dv)

Launch

How can I create a phpinfo.php page? Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: FTP, plain text editor Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: FTP, plain text editor Overview You can use a phpinfo() page to view the current PHP information for your server. This file o ... Applies To: (gs), All (dv)

Launch

Understanding basic vi (visual editor) Applies to: (gs) Difficulty: Medium-Hard Time Needed: 20 Tools Required: SSH enabled, SSH client Applies to: All (dv) Difficulty: Medium Time Needed: 10 Tools Required: SSH, root or sudo access Overview vi (visual editor) is included with all (mt) Media Temple services. vi is a full ... Applies To: (gs), All (dv)

Launch

Troubleshooting common issues with cron jobs Applies to: (gs) Difficulty: Medium Time Needed: 15 Tools Required: SSH, vi knowledge Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: SSH, vi knowledge Overview Cron jobs are commands that your service runs at a specified interval and, as such, can be difficult ... Applies To: (gs), All (dv)

Launch

PHP Safe Mode, problems and work-arounds Service Type: (gs) Grid-Service Difficulty: Medium Time Needed: 20 Tools Required: SSH, vi knowledge Service Type: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: SSH, vi knowledge Overview This article is about PHP Safe Mode, security, and Safe Mode workarounds. Default s ... Applies To: (gs), All (dv)

Launch

Block a specific IP address from accessing your website Applies to: (gs) Difficulty: Medium Time Needed: 15 Tools Required: FTP client, plain text editor Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: FTP client, plain text editor Overview If you have annoying visitors, site scrapers, or spammers, you may find it us ... Applies To: (gs), All (dv)

Launch

Making directories browsable, solving 403 errors Applies to: (gs) Difficulty: Medium Time: 10 Tools needed: FTP, plain text editor or SSH, vi knowledge Applies to: (dv) 4.0 Difficulty: Medium Time: 10 Tools needed: FTP, plain text editor or SSH, vi knowledge Applies to: (dv) 3.5 Difficulty: Medium Time: 10 Tools needed: FTP, plain tex ... Applies To: (gs), All (dv)

Launch

Creating custom error pages Applies to: (gs) Difficulty: Medium Time: 20 Tools needed: FTP Applies to: All (dv) Difficulty: Medium Time: 20 Tools needed: FTP Overview This article explains how to set up custom error documents for your server. Instead of a plain 404 Not Found or 500 Internal Server Error page, yo ... Applies To: (gs), All (dv)

Launch

Basic troubleshooting & tips for CloudFlare Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Applies to: (ve) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Overview CloudFl ... Applies To: (gs), (ve), All (dv)

Launch

Installing Perl modules on the (gs) Grid-Service Applies to: (gs) Difficulty: Medium Time Needed: 20 Tools Required: SSH, vi knowledge Overview The following article will show you how to install Perl modules on the (gs) Grid-Service. You can find many Perl modules by visiting http://search.cpan.org. NOTE: Whenever you see ##### please ... Applies To: (gs)

Launch

(gs) Is mod_gzip installed on the Grid? Applies to: (gs) Difficulty: Medium Time Needed: 10 Tools Required: FTP, plain text editor or SSH access, vi knowledge Overview Since the (gs) runs the newer Apache 2, mod_gzip has been replaced by the more flexible and configurable mod_deflate. Essentially, this means that if you are s ... Applies To: (gs)

Launch

Cron jobs for (gs) Grid-Service TIP: This page has moved. Please see: Using Cron. Applies To: (gs)

Launch

Prevent search engines from indexing your websites Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: FTP client, plain text editor Applies to: All (dv) Difficulty: Easy Time Needed: 10 Tools Required: FTP client, plain text editor Overview Web Robots, also known as Web Wanderers, Crawlers, or Spiders, are programs tha ... Applies To: (gs), All (dv)

Launch

Why am I experiencing session errors? Applies to: (gs) Difficulty: Medium Time Needed: 10 Tools Required: SSH, vi knowledge or FTP, plain text editor Symptoms Randomly being logged out of your PHP application. Sessions are not saving when transitioning from HTTP to HTTPS protocols. If a PHP session needs to begin in HTTP a ... Applies To: (gs)

Launch

(gs) AMFPHP incompatibilty with PHP 5.2 Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: None Overview AMFPHP is a free open-source PHP implementation of the Action Message Format(AMF). AMFPHP was, at one point, incompatible with PHP 5.2 and later versions. However, it now appears that this issue has been res ... Applies To: (gs)

Launch

Which PHP modules are included with your version of PHP? Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: None Overview The (gs) Grid-Service has PHP pre-installed and available for your use. Current version Visit the link below to view a phpinfo page for the latest version of PHP5 running on the Grid. PHP5 - phpinfo() NOT ... Applies To: (gs)

Launch

(gs) Using SetHandler to process other extensions as PHP Applies to: (gs) Difficulty: Medium Time Needed: 10 Tools Required: FTP, plain text editor or SSH, vi knowledge Overview There might be times when you want your webpages to appear like they are html but are actually being processed as PHP. This article briefly describes three ways to ac ... Applies To: (gs)

Launch

How do I use symlinks to redirect my site? Applies to: (gs) Grid-Service Difficulty: Medium Time Needed: 20 Tools Required: SSH Overview This article will show you how to make the content displaying for example.com appear when visiting alt-example.com. A symlink, short for symbolic link, is one of the best ways to do this. Befo ... Applies To: (gs)

Launch

Using server side includes (SSI) Applies to: (gs) Difficulty: Medium Time: 20 Tools needed: FTP, plain text editor Applies to: (dv) Difficulty: Medium Time: 20 Tools needed: FTP, plain text editor Overview This article explains how to use SSI (Server Side Includes) in your web pages from the designated files. SSI is ... Applies To: (gs), All (dv)

Launch

What is a domain warning for 1-Click installations? Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access and DNS control Overview On occasion, you may run across a Domain Warning message when using the 1-Click tool. This article provides steps to correct this. If you received the error in Figure 1, you c ... Applies To: (gs)

Launch

How do I disable the CloudFlare service? Applies to: All Service Types Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Overview The CloudFlare service can easily be disabled for any domain, at any time, in your AccountCenter. Instructions Log into your AccountCenter. On the Overview page, scroll down to ... Applies To: (dv) 4.0, (gs), (ve)

Launch

How do I add a subdomain to CloudFlare? Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: AccountCenter access Overview You can easily add a subdomain to your CloudFlare service. This article will show you how! A subdomain is a domain that is part of a top-level domain. For example, example.com is a top-level ... Applies To: (gs)

Launch

Why am I getting a 500 Internal Server Error message? Applies to: All Service Types Difficulty: Medium Time Needed: 20 Tools Required: Plain text editor, FTP client Overview 500 Internal Server Error is a generic error message, given when no more specific message is suitable. There are a number of causes for a 500 Internal Server Error to ... Applies To: All Service Types

Launch

How do I enable .phps file to be color highlighted? Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: SSH, vi knowledge Overview Due to the way PHP is configured on our (gs) platform, there is a work around to get a .phps file displaying colorized. Instructions You will need to add the following to your .htaccess and creat ... Applies To: (gs)

Launch

CGI and PHP resource limits Applies to: (gs) Difficulty: Easy Time Needed: 10 Tools Required: None Overview On the (gs) Grid-Service platform, the following limits are in place for all PHP and CGI processes on your website(s): 120 seconds of CPU time 100MB of RAM usage 36 processes per node Any attempt to exceed ... Applies To: (gs)