Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Problem mit Gif-Verarbeitung

Empfohlene Antworten

Veröffentlicht

Hi zusammen,

habe ein Problem beim verarbeiten, verwenden von Gif-Pics. Das Script sieht wie folgt aus und funktioniert zumindest schonmal bei jpg-files :


<?php
$_GET ['file'] = $file;

if (preg_match("/jpg/i", '$file')) {
$strHeader = "Content-type: image/jpeg";
$jpg = 1;

}
if (preg_match("/gif/i", '$file')) {
$strHeader = "Content-type: image/gif";
$gif = 1;
}

header('$strHeader');


$size = getimagesize($file);
$width = $size[0];
$height = $size[1];

if ($jpg="1"){
$old_picture = imagecreatefromjpeg($file);
}else{
$old_picture = imagecreatefromgif($file);
}


$new_picture = imagecreatetruecolor($width, $height);


imagecopyresampled($new_picture, $old_picture, 0, 0, 0, 0, $width, $height, $width, $height);


$transition = 50;
$watermarkfile = imagecreatefrompng('logo.png');
$waternarkpic_width = imagesx($watermarkfile);
$waternarkpic_height = imagesy($watermarkfile);
$watermarkdest_x = $width / 2 - ($waternarkpic_width / 2);
$watermarkdest_y = $height / 2 - ($waternarkpic_height / 2);
imagecopymerge($new_picture, $watermarkfile, $watermarkdest_x, $watermarkdest_y, 0, 0, $waternarkpic_width, $waternarkpic_height, $transition);

if ($jpg="1"){
imagejpeg($new_picture);
}else{
imagegif($new_picture);
}

?>
[/PHP]

Kann mir da bitte jemand weiterhelfen ? Bin wahrscheinlich einfach nur zu blinde ;)

http://de3.php.net/imagecreatefromgif

Anmerkung: ACHTUNG: Ab Version 1.6 wurde die komplette GIF-Unterstützung aus der GD-Bibliothek entfernt. Diese Funktion ist also nur verfügbar, wenn Sie eine Version vor 1.6 verwenden.

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.