i have a domain pointing to my main, but hes using a frame (i cant change this, my host only provides this type of redirect and dont even allow me to redirect to a redirect.html)
<FRAME SRC="http://www.domain111.com/" NORESIZE>
how can i force this secondary domain to redirect to my main site, without frames?
so far i tried:
RewriteCond %{HTTP_HOST} ^www.domain222.com$[OR]
RewriteCond %{HTTP_HOST} ^domain222.com$
RewriteRule ^(.*)$ http://www.domain111.com/$1 [R=301,L]
also
if (preg_match("/domain2222.com/i", $_SERVER['HTTP_REFERER'])) {
header("HTTP/1.1 301 Moved Permanently");
header("Location: http://www.domain111.com/");
exit;
}
but thats a infinite loop since the redirect comes from that frame
what should i do? changing host is not a option
This is possible only with a Javascript-based frame buster.
A primitive version: