SPIP - Contrib

SPIP - Contrib

[ar] [en] [es] [fr] [it]

68 visitors now

fontsizeup fontsizedown
Home page > English > Antispam Solutions > A form to write to the author. An anti-spam solution.

A form to write to the author. An anti-spam solution.

Tuesday 14 December 2004, by mortimer

All the versions of this article: [English] [français]

  • Digg
  • Del.icio.us
  • Facebook
  • Google
  • Technorati

In the basic SPIP template, author’s emails can be seen by anyone. This is good food for spammers.

This template adds a new page to write to the author through a form without disclosing their mail.

In place of the user mailer, we provide with this template a simple web form to write to the author.

template

here are the two files for this new page:

ecrire_auteur.html

ecrire_auteur.php

install them into your SPIP folder.

Linking from other templates

Now, we have to direct the user to this page when he clicks on the author name. Put this new code in any boucle providing an id_article (like the ARTICLE boucle).

<BOUCLE_auteurs(AUTEURS) {id_article} {par nom}>
                <li><A HREF="ecrire_auteur.php?id_article=#ID_ARTICLE">#NOM</a></li>
</BOUCLE_auteurs>

P.S.

  1. From version 1.7.2, the distribution file auteur-dist.html comes with this same functionality.
  2. This form will only work if the server where the site is provides the emailing functions.

Reply to this article

Back to top

Here they're talking

SPIP | Template | | Site Map | Follow-up of the site's activity RSS 2.0