Pages vues depuis 25/05/2001 : 110 229 688
Index du forum »» Questions »» $variable écrite dans un fichier
<?php
/**************************************************************************************************/
/* Module de gestion de slideshow pour NPDS */
/* =================================================== */
/* (c) 2010-2011 colonelwog - http://www.outils.npds.free.fr */
/* */
/* This program is free software. You can redistribute it and/or modify it under the terms of */
/* the GNU General Public License as published by the Free Software Foundation; */
/* of the License. */
/**************************************************************************************************/
/**************************************************************************************************/
/* Page Principale */
/**************************************************************************************************/
if (!strstr($PHP_SELF,"admin.php")) { Access_Error(); }
if ($admin) {
global $site_font, $title, $NPDS_Prefix, $ModPath, $language;
$resultat= "SELECT * FROM ".$NPDS_Prefix."slideshow ";
$reponse = sql_query($resultat)or die(mysql_error());
// récupération des données du formulaires
$fp = fopen("modules/slideshow/fpss/slideshows/demoslideshow/data.php", 'w+');
$php = "<?php\n"
." $slides = array(\n";
while ($res = sql_fetch_assoc($reponse)) {
$php .= "\t array( \n";
$php .= "\t\t 'slidelink' => '".$res['link']."' , \n";
$php .= "\t\t 'title' => '".$res['title']."' , \n";
$php .= "\t\t 'category' => '".$res['subtitle']."' , \n";
$php .= "\t\t 'tagline' => '".$res['thumbdescriptif']."' , \n";
$php .= "\t\t 'text' => ''".$res['description']."' , \n";
$php .= "\t\t 'slideimage' => '".$res['image']."' \n";
$php .= "),\n";
}
$php .= ");\n";
$php .= "?>\n";
fputs($fp, $php );
fclose($fp);
// Paramètres utilisé par le script
$ThisFile = "admin.php?op=Extend-Admin-SubModule&ModPath=$ModPath&ModStart=admin/admin";
}
!include! ("footer.php");
?>