Je ne comprends vraiment pas pourquoi tu mets toute cette partie dans la boucle alors que @@NOM_LETTRE@@ et @@DESCRIPTION@@ étaient en dehors :
<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd’><html>
<head><title>Les nouveautés depuis le (#DATE|affdate)</title></head>
<body>#SET{date,oui}]
<h1>@@NOM_LETTRE@@</h1>
<div>@@DESCRIPTION@@</div>
Quel était le problème ?
Et sinon, attention à ta variable nommée "date", c'est déjà une variable d'environnement, cela pourrait avoir des effets secondaires imprévisibles...
Le 6 nov. 2009 à 09:55, pierre.fiches@free.fr a écrit :
Author: pierre.fiches@free.fr
Date: Fri Nov 6 09:55:26 2009
New Revision: 32700Log:
sujet automatique plus valide, remplacement de eregiModified:
_plugins_/clevermail/2_0/clevermail_nouveautes_html.html
_plugins_/clevermail/2_0/inc/clevermail_post_create.phpModified: _plugins_/clevermail/2_0/clevermail_nouveautes_html.html
--- _plugins_/clevermail/2_0/clevermail_nouveautes_html.html (original)
+++ _plugins_/clevermail/2_0/clevermail_nouveautes_html.html Fri Nov 6 09:55:26 2009
@@ -1,9 +1,11 @@
#CACHE{0}
#HTTP_HEADER{Content-type: text/html; charset=#CHARSET}
-<B_test_contenu>
+<B_test_contenu>#SET{date,''}
<BOUCLE_test_contenu(AUTEURS){0,1}{tous}><BOUCLE_articles(ARTICLES){age_relatif<=0}{par date}{inverse}{0,20}>
[(#COMPTEUR_BOUCLE|=={1}|oui)
-[<title>(#INCLURE{fond=inclure/sujet1,sujet=Les nouveautés depuis le #DATE|affdate})</title>]
+[<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd’><html>
+<head><title>Les nouveautés depuis le (#DATE|affdate)</title></head>
+<body>#SET{date,oui}]
<h1>@@NOM_LETTRE@@</h1><div>@@DESCRIPTION@@</div>
@@ -15,4 +17,5 @@
</BOUCLE_articles></BOUCLE_test_contenu><p>Cliquez sur le lien suivant pour vous désinscrire : <a href="@@URL_DESINSCRIPTION@@">@@URL_DESINSCRIPTION@@</a></p>
+[(#GET{date}|oui)</body></html>]
</B_test_contenu>
\ No newline at end of fileModified: _plugins_/clevermail/2_0/inc/clevermail_post_create.php
--- _plugins_/clevermail/2_0/inc/clevermail_post_create.php (original)
+++ _plugins_/clevermail/2_0/inc/clevermail_post_create.php Fri Nov 6 09:55:26 2009
@@ -12,7 +12,8 @@
$url_text = $list['lst_url_text'].(strpos($list['lst_url_html'], '?') !== false ? '&' : '?').'date='.date("Y-m-d",$last_create);
$post['pst_text'] = recuperer_page($url_text);
if (trim($post['pst_html']) != '' && trim($post['pst_text']) != '') {
- if (eregi("<title>(.*)</title>", $post['pst_html'], $regs)) {
+ //if (eregi("<title>(.*)</title>", $post['pst_html'], $regs)) {
+ if (preg_match(",<title>(.*)</title>,", $post['pst_html'], $regs)) {
$post['pst_subject'] = trim($regs[1]);
} else {
$post['pst_subject'] = 'Aucun sujet';_______________________________________________
Spip-zone-commit@rezo.net - http://listes.rezo.net/mailman/listinfo/spip-zone-commit
-Nicolas
--
Nicolas HOIZEY
Blog : http://www.gasteroprod.com/
Photos : http://flic.kr/nicolas-hoizey/