PHP Notice: Undefined index: HTTP_REFERER /ecrire/inc/surligne.php on line 73

eric <[email protected]>
Newsgroups gmane.comp.web.spip.devel
Message-ID <[email protected]>
Bonjour,

J'ai mis en service le surlignage.

Partiellement  - uniquement lorsque je crée un lien avec le paramètre
recherche: 

mes_options.php :

define('_SURLIGNE_RECHERCHE_REFERERS',true);
if (isset($_REQUEST['recherche'])) {
    $_GET['var_recherche'] = $_REQUEST['recherche'];
}


Supprimer les notices n'est pas compliqué :

/ecrire/inc/surligne.php

```
+ $ref = isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] :
NULL; 
- $ref = $_SERVER['HTTP_REFERER'];
	//avoid a js injection
```

Mais j'essaie de comprendre :

```
if ($surcharge_surligne || (preg_match($engine[0], $ref) &&
preg_match($engine[1], $ref))) {

			//good referrer found or var_recherche is not
null
```

Le script est placé si le paramétre "recherche" est dans l'url ou si le
referer est un moteur.

Est-ce une simple notice sans conséquences ?

Cordialement,

Eric

PS : j'essaie de voir pourquoi le referer n'est pas renvoyé.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.