[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

RE: CRON/php



Dans l'url, je changerais le & en ? 

? annonce le query string
& sépare les paramètres du query string

https://localhost/sauvegarde.php?verification=true 

Je suppose que tu as déjà testé l'url dans un browser ?
Cela permettrait de dissocier les problèmes crontab des problèmes php

Normalement, php4-cli n'est pas nécessaire si tu exécutes le script via Apache avec mod_php activé

A+
Alec

-----Original Message-----
From: Patrick DUBAU [mailto:patrick.dubau@alsace.iufm.fr]
Sent: Thursday, May 18, 2006 11:09 AM
To: debian-user-french@lists.debian.org
Subject: Re: CRON/php


G DEBIAN a écrit :
> Bonjour,
>
> je souhaiterais modifier crontab pour que celui ci execute un lien en 
> php...
> j'ai essaye : " 0,32,40 * * * * wget -O /dev/null 
> https://localhost/sauvegarde.php&verification=true 
> <https://localhost/sauvegarde.php&verification=true> " mais ca ne 
> marche pas...
> En fait, le lien sur le lequel je souhaite aller active une sauvegarde 
> de la base, quand je me sers de crontab pour executer un mysqldump 
> directement ca marche :s
>
>
> Merci d'avance...


Bonjour,

si c'est juste pour exécuter un script en php en ligne de commande il 
faut :
- installer le paquet : apt-get install php4-cli
- dans cron : 0,32,40 * * * * <chemin>/sauvegarde.php&verification=true 
<https://localhost/sauvegarde.php&verification=true>
- et au début du script php : #!/usr/bin/php




-- 
Lisez la FAQ de la liste avant de poser une question :
http://wiki.debian.net/?DebianFrench   
Vous pouvez aussi ajouter le mot ``spam'' dans vos champs "From" et
"Reply-To:"

To UNSUBSCRIBE, email to debian-user-french-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org 
 
Notice:
 
This e-mail and any attachments thereto may contain information, which is confidential and/or protected by intellectual property rights, and are intended for the sole use of the recipient(s) named above.  Any use of the information contained herein by persons other than the designated recipient(s) is prohibited. Although we attempt to sweep e-mail and attachments for viruses, it does not guarantee that either is virus-free and we accept no liability for any damage sustained as a result of viruses.
[TG_DISCLAIMER]



Reply to: