Hi folks


I'm trying to protect a heap of email addresses on lots of pages from
spammers. The pages are static pages on another site, (reason, they have to
be), but as some of them are generated on my site using PHP/MYSQL I thought
that the best way would be to redirect mail links to a popup form on my site
that could grab the name and email address from the DB etc.  This I have
working fine.

But what I'd like to do is have the mailform coming up with no toolbar,
locationbar etc. After much browsing it looks like I can't change the window
attribs once it's opened. I don't want to have to change 100's of pages to
include a js on top to set these properties

My Solution:

So I thought that although it may be a long way round (although quicker than
changing heaps of pages) was to create a redirector popup page that calls
the Mailform with everything turned off then automatically shuts itself.

I know that maybe this is not strictly PHP/MYSQL related but I figured that
someone might have other ideas or might even have done this themselves.  My
some-what clumbsy code is below.


if (!isset($senditto)) {
        $MailTo = "[EMAIL PROTECTED]";
}else {
        $whoto = $senditto;
if (!isset($fwdsite)) {
        $sitename = "unlisted";
} else {
        $sitename = stripslashes($fwdsite);
if (!isset($cat)) {
        $lookupdb = "nocat";
} else {
        $lookupdb = stripslashes($cat);
if (!isset($nabout)) {
        $about = "nosubject";
} else {
        $about = stripslashes($nabout);
if (!isset($ctype)) {
        $ctype = "c1";

$whereto =

<SCRIPT language="JavaScript">
function openWindow(url) {
   popupWin = window.open(url,'MailRedirector',
var StayAlive = 15; // Number of seconds to keep window open
function KillMe(){
   setTimeout("self.close()",StayAlive * 1000);
<META http-equiv="Refresh" content="0; URL=<?php echo "$whereto"; ?>">
<title>Mailform redirector</title>

<BODY onload="openWindow(<?php echo "$whereto"; ?>);KillMe();self.focus()">
<font size=3>
<div align="center">Mail Form Redirection Page</div>

Any ideas anyone?



PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to