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…

Continue reading »

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 =…

Continue reading »

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…

Continue reading »

Add Tomcat Manager GUI to Tomcat Server

After installing the Tomcat server, you need a GUI of Manager to manage the Tomcat Server. First, go to this directory C:\xampp\tomcat\conf\, open the file tomcat-users.xml in your favorite text editor (I’m using Notepad++). Add the following lines inside the parent element <tomcat-users> <role rolename=”manager”/> <user username=”tomcatadmin” password=”s3cret” roles=”manager”/> After adding the XML element above, your tomcat-users.xml will look like this. <?xml version=’1.0′ encoding=’utf-8′?> <tomcat-users> <role rolename=”manager”/> <role rolename=”admin”/> <user username=”xampp” password=”xampp” roles=”admin,manager”/> <role rolename=”manager”/> <user username=”tomcatadmin” password=”s3cret” roles=”manager”/> </tomcat-users> Now go to the Xampp…

Continue reading »

Setup Multiple Servers on 1 computer

For a lot of you who have only one computer but you want to install multiple servers such as Apache 2.0, Apache 2.2, Xampp, NuSphere, and GlassFish for Tomcat users. If you follow my steps below here, you wouldn’t go wrong and you’ll have multiple servers to write your applications in multiple languages. Step 1: Install all servers in your C:\ drive Step 2: Define each server with each different port. For example: Apache 2.0, you configure Port 80. Apache 2.2, you configure Port 81…

Continue reading »