This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
###################################### | |
# sshpass - ssh. | |
# Backup script. | |
# Save on remote server. | |
###################################### | |
# Local directories to backup | |
backup_files="/media/ /test/" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Style --> | |
@media print { | |
body * { | |
visibility: hidden; | |
} | |
#section-to-print, #section-to-print * { | |
visibility: visible; | |
} | |
#section-to-print { | |
position: absolute; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Créer un dossier ex: /images-dist/ | |
//A l'interieur crée un fichier avec le code si dessous pour chaque images ex:image1.php - image2.php - ... | |
<?php | |
$nom_image = "https://eurowebpage.eu/ewp/img-ewp-dist/1.jpg"; // l'url de l'image avec l'extension jpeg | |
header ("Content-type: image/jpeg"); | |
$image = imagecreatefromjpeg($nom_image); | |
imagejpeg($image); | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Dans votre dossier images crée pour chaque images un ficher .php | |
//image1.jpg == crée un fichier image1.php | |
//image2.jpg == crée un fichier image2.php | |
//Dans chaque fichiers php ajouter le code ci-dessous et modifier suivant le nom de l'image | |
//Exemple image1.php pour l'image image1.jpg | |
<?php | |
// Exemple image1.php | |
$nom_image = "image1.jpg"; // le nom de votre image avec l'extension jpeg | |
header ("Content-type: image/jpeg"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// créer un fichier exemple ds dossier inc/ textimage1.php | |
// et coller le code si dessous | |
<?php | |
$nom_image = "../img/vide.jpg"; // le nom de votre image avec l'extension jpeg | |
$texte = '#EUROWEBPAGE'; // Le texte que vous désirez écrire sur l'image | |
header ("Content-type: image/jpeg"); | |
$image = imagecreatefromjpeg($nom_image); | |
$blanc = imagecolorallocate($image, 255, 255, 255); | |
imagestring($image, 25, 115, 115,$texte, $blanc); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$path = 'img/'; // nom du répertoire ou sont placés les images | |
$last_time = 0; | |
$last_image = ''; | |
$dir = opendir($path); // ouverture du dossier | |
while($image = readdir($dir)) | |
{ | |
if (is_file($path.$image)) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//$files = glob("images/*.*"); | |
$files = glob("img/*.*"); | |
for ($i=0; $i<count($files); $i++) | |
{ | |
$image = $files[$i]; | |
$supported_file = array( | |
'gif', | |
'jpg', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$files = glob("img/*.*"); | |
for ($i = 0; $i < count($files); $i++) { | |
$image = $files[$i]; | |
echo '<img src="'.$image.'" class="img-fluid" />'; | |
} | |
?> | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$dirname = "img/"; // répertoire | |
$images = glob($dirname."*.png"); | |
foreach($images as $image) { | |
echo '<img src="'.$image.'" class="img-fluid" />'; | |
} | |
?> |
NewerOlder