Gossamer Forum
Home : Products : Links 2.0 : Customization :

Send mail to linkowners

Quote Reply
Send mail to linkowners
Hi thing I have seen this, but cannot find it anymore...

I want to add an item to every link, that avisitor can send a mail to a linkowner, without knowing the exact mail-adress for example with a form?

Is it possible? - Has anyone tried out that?

Chris

Quote Reply
Re: Send mail to linkowners In reply to
Yeah that can be done. If I get time I'll have a look at doing it.


Good Luck!

Glenn

http://mir.spaceports.com/~glennu/
Quote Reply
Re: Send mail to linkowners In reply to
Hi Glennu,

I would love to get this script too if you get the chance to make it. Thanks for helping all of us who don't have your programming skills.

Adrian

Quote Reply
Re: Send mail to linkowners In reply to
Hi gennu,

I have tried out something, but it doesn't work, but I doesn't have a clue of perl !!! But I think, tis way must go ...

He is my chiffre.cgi, There is also a chiffre
(it's made out of feedback.cgi and modify-mod)


sub main {
# --------------------------------------------------------
my %in = &parse_form();
#local (%in) = &parse_form;
#my %in = &parse_form();
if ($in{'mail_id'}) {
&site_html_chiffre_mail;
return;
}
# We are processing the form.
if ($in{'Submit'}) {
&send_chiffre;
}
}


sub send_chiffre {
my %in = &parse_form();
# Make sure the email address at least looks like an email address.
my $email = $in{'email'};
my $name = $in{'name'};
my $comment = $in{'comment'};
($email =~ /.+@.+\..+/) or &site_html_feedback_error ("The email address: '$email' doesn't look like a real email address.") and return;
($name =~ /[A-Za-z]+/) or &site_html_feedback_error ("Please enter your name.") and return;
($comment =~ /[A-Za-z]+/) or &site_html_feedback_error ("Please enter your comments.") and return;
#### my $to = $db_admin_email;
my $to = $mail_id{'Contact Email'}
my $from = $in{'email'};
my $subject = "Feedback to your link !!!";
my $msg = qq|
To $db_admin_email, you got feed back to your link:
Name: $in{'name'}
Email: $in{'email'}
URL: $in{'URL'}
I got this site from: $in{'heard'}
Rating given: $in{'rate'}
Nachricht: $in{'comment'}

from
$in{'name'};
|;
# Then mail it away!
require "$db_lib_path/Mailer.pm";
my $mailer = new Mailer ( { smtp => $db_smtp_server,
sendmail => $db_mail_path,
from => $from,
subject => $subject,
to => $to,
msg => $msg,
log => $db_mailer_log
} ) or return;
$mailer->send or return;
print &site_html_feedback_mail;
}

Quote Reply
Re: Send mail to linkowners In reply to
Sorry I haven't replied in ages, I've been really busy at the moment. Anyway I'll have some spare time this week so I'll have a go at figuring something out.

Yeah the code you've got from feedback.cgi and modify.cgi is something along the lines of what could be used. What fields did you want in the email form?

Ie. their name, email address, comment and IP address

I'll also have a look at logging the info into a text file if you think that would be useful.


Good Luck!

Glenn


http://mir.spaceports.com/~glennu/
Quote Reply
Re: Send mail to linkowners In reply to
Hi,

sounds great! I think, the fields arn't the problem, maybe -as you havewritten:
name, email address, comment and IP address(?), Subject

If it's possible it my be fine to lock the contacts in a txt-file so, that we can read the mailadresses and IP to identify someone who spams with that funktion
(maybe in the links-db in a field like contacts, eq like hits)

Best wishes Chris ...


Quote Reply
Re: Send mail to linkowners In reply to
Sorry it probably sounded as if I wanted the IP address as a field for the user to put in!!! I just meant to log it instead.

Yeah there's a few other options that could be done:

One idea would be to send it to the link owner but also send a copy to admin including the IP number. If you think that a person is abusing the system you could put their IP into a banned IP file.

Or logging the IP's as suggested before.

I think, however that the logging of IP's something similar to rate.cgi is worth doing instead. Cause then the old ones will be deleted each time you build the directory (ie means you won't need to check the size of the log files) Also probably worth doing cause many peoples IP's change anyway each time they log on so having a load of old ones isn't much good.

Good Luck!

Glenn


http://mir.spaceports.com/~glennu/
Quote Reply
Re: Send mail to linkowners In reply to
I habe solved the problems and there is a new mod you can use at:

http://guxme.de/privat/gossamer/

I will post it soon.

Chris

Quote Reply
Re: Send mail to linkowners In reply to
I've also found a solution to emailing link owners (sorry about the length of time it's taken, have been busy with other things!), also it can be altered so that visitors can recommend the link to their friends. If anyone needs it let me know and I'll post it on my site.

Good Luck!

Glenn


http://mir.spaceports.com/~glennu/
Quote Reply
Re: Send mail to linkowners In reply to
Yes, I'm interested. Post it!

John

Quote Reply
Re: Send mail to linkowners In reply to
Yep no problem. I've posted one on my site, but I've also got one to write to a logfile. I'll upload that to my site tonight.

Good Luck!

Glenn


http://mir.spaceports.com/~glennu/