Apache Variables
After installing Apache and PHP server, you can check the Apache variables by using a php page to echo them on the browser. If you need to modify the Apache config to adapt your server environment and to meet your needs, you can always change the .conf file and restart your Apache server. Use the Apache variables below to check your server: DOCUMENT_ROOT Document root HTTP_ACCEPT Accept header of an HTTP request HTTP_ACCEPT_ENCODING Accepted encoding (deflate or gzip) HTTP_ACCEPT_LANGUAGE Accept-Language from HTTP header HTTP_CONNECTION Connection…
Apache + PHP installation error: The specified module could not be found.\r\n in Unknown on line 0
Common Apache error: “PHP Warning: PHP Startup: Unable to load dynamic library ‘C:\\php5\\ext\\php_pdo_mysql” in the Apache log file (C:\Program Files\Apache Group\Apache2\logs\error.log). I just installed Apache and Tomcat servers on my new laptop in order to run php and java at the same time; however I ran into an issue with MySQL database connection when I execute a php page. There’re a few things that you can try to make your server work properly. First: check php.ini file to make sure that you have extension_dir =…
Comparison of PHP json libraries
Today I start a project of building an Android Application that allows lenders to search for a certified and trained appraisers within their preferred area. To build a simple app, you can use REST to return data. You will need Json extension on the PHP server to have the task done. If you would like to know how to install JSON on your PHP server (only PHP version below 5.2), go to http://www.php.net/manual/en/json.installation.php. Most of the hosting servers nowadays have PHP version 5.2 that comes…
How to cut down page-not-found error records in your Watchdog table?
Some of you who own Drupal website may notice that now and then people are trying to hack your server with tons of call to phpMyAdmin/scripts/. I’ve checked all IP addresses that are used to visit my site, I found those in Watchdog table in DB. Those IP addresses are from all over the world such as China, Russia, Canada, USA, Ukraine, … you name it. This is very annoying when the watchdog table is loaded with not-found-page errors instead of system errors that you’re…
Why does your website get hacked?
I have seen so many websites got hacked from the Admin User Interface. Most files on the server have been overwritten with embedded codes such as <iframe> or Javascript or something else. Why? If hacker gain the access to admin of your website, they can do everything. They can view your configuration file. They’ll know all credentials that have been set up to run your website including DB access, SMTP mail server, FTP access. So to prevent this happens, you have to rename a few…