.htaccess – Redirect subdomain to folder

Add this to your .htaccess in your web root / directory RewriteEngine on RewriteBase / RewriteCond %{HTTP_HOST} ^m\.daltonempire\.nl$ [NC] RewriteCond %{REQUEST_URI} !^/m(/|$) [NC] RewriteCond %{REQUEST_FILENAME} !-d # not a dir RewriteCond %{REQUEST_FILENAME} !-f # not a file RewriteRule ^(.*)$ m/$1 [L] The %{REQUEST_FILENAME} conditions would let you access /exists.php and not rewrite it to /m/exists.php. … Read more

AJAX, Subdomains, and SSL

With plain-http AJAX: You are talking about doing cross-domain XMLHttpRequest, which is not permitted by browsers. There’s a W3C proposal pending to implement this in a secure way in the future (partially implemented by IE8, IIRC), but it’s definitely not possible at present. There are, however, workarounds for doing it securely: Subspace (which uses iframes … Read more