PHP

This section will attempt to show some articles and tutorials covering PHP solutions/problems.

  • .htaccess 301 redirect clearing get and post variables

    Just an issue I have come across recently on my website, so I thought I could share my problem and the resolution. Problem: Member's login was not working after I added the following .htaccess lines of code to redirect non-www address to ...
  • Apache : Setting up sub domains on localhost

    Intro Recently I've been trying to setup subdomains to run on my localhost. This will come in handy for testing html code before putting a site live. Note I'm running Apache 2.2.11 on Windows XP. The example of a subdomain is http://localh...
  • What you may not know about IF statements, ternary operators explained.

    Traditional IF statements can take up more lines than you would like to. Especially when its only a small condition. Ternary operators take three arguements condition, true, false. This can be contructed on one line as opposed to the trandi...
  • .htaccess 301 force redirect directory to a subdomain

    I recently came across a situation that required some attention with htaccess regex. This example I needed to send a folder on my server to a sub domain that had been created.Eg. http://www.my-site.com/subfolder/ -> http://subfolder.my-s...