ERLEDIGT
NEIN
NEIN
ANTWORTEN
2
2
ZUGRIFFE
348
348
EMPFEHLEN
-
27.03.05 19:47 #1pledermann Tutorials.de Gastzugang
Hallo zusamen
das script funktioniert gut, bis auf die blätterfunktion.
Wer kann mir weiterhelfen. Finde die lösung einfach nicht
Wäre sehr dankbar wenn mir jemand helfen könnte !PHP-Code:<?php
$url = "/card.php?action=card&kat=$kat&bild=";
$subdir = "./post/img/$kat/";
$verzeichnis = opendir("./".$subdir.$gal);
while($img = readdir($verzeichnis)) {
$parts = explode(".", $img);
if((($parts[1] == "gif") OR ($parts[1] == "jpg") OR ($parts[1] == "png")) AND (strtolower($parts[0]{0}))){ //anstatt $parts[0]{0} kannst du auch substr($parts[0], 0, 1) verwenden.
$images[] = $img;
}}$entrys = count($file) - 1;
$perpage = 12; //Einträge pro Seite
$pages = ceil($entrys / $perpage);
if ($page == 0): $page = 1; endif;
$globalcounter = ($page * $perpage) - $perpage;
$counter = 1;
while($counter <= 12 && $globalcounter <= $entrys):
include($subdir."/".$file[$globalcounter]);
$counter++;
$globalcounter++;
endwhile;
closedir($verzeichnis);
if (count($images) > 0) {
foreach ($images as $image) {
print " <a href=\"".$url.$image."\"
onmouseover=\"self.status='".$image."'; return true;\"
onmouseout=\"self.status=''; return true;\">";
print "<img width=\"140\" heigh=\"140\" src=\"./".$subdir.$gal."".$image."\" alt=\"$image\"
border=\"0\"></a>";
}
} else {
print "<b> Sorry, in dieser Kategorie sind noch keine Bilder<b>\n";
}
if ($page > 1):
$lastpage = $page -1;
echo "<a href = \"".$PHP_SELF."?page=".$lastpage."\">Zurück</a>|";
endif;
for($i = 1; $i <= $pages; $i++):
if($i != $page):
echo " <a href = \"".$PHP_SELF."?page=".$i."\">".$i."</a>";
else:
echo " <b>".$i."</b>";
endif;
endfor;
if ($pages > 1 && $page < $pages):
$nextpage = $page + 1;
echo " |<a href = \"".$PHP_SELF."?page=".$nextpage."\">Nächste</a>";
endif;
?>
Grüss Jörg
-
Wie wäre es denn mit einer etwas genaueren Fehlerbeschreibung?
[:.drumba.:] - Wordpress Entwicklung Berlin
_______________________________________
Staatlich anerkanntes Experiment:
Kohlkopf | Angela | Merkel| Angela Merkel
-
27.03.05 19:56 #3pledermann Tutorials.de Gastzugang
Alle Bilder werden aus dem verzeichnis ausgelesen (ca. 40 Bilder ) möchte aber nur 16 bilder haben dann die Blätterfunktion mit ( zurüch | 1 2 3 4 5 | Nächste. Nur diese wir nicht aktiviert.
Ähnliche Themen
-
Bridge Probleme mit der Vorschau
Von topolino im Forum PhotoshopAntworten: 1Letzter Beitrag: 15.12.09, 15:11 -
FCKeditor + Bilder Vorschau
Von oldputz1990 im Forum PHPAntworten: 0Letzter Beitrag: 01.04.08, 14:01 -
Probleme bei RAM Vorschau in After Effects CS3
Von NikiFrank im Forum Videoschnitt, Videotechnik & -produktionAntworten: 2Letzter Beitrag: 16.10.07, 20:53 -
ListView mit Vorschau-Bilder
Von xbu58 im Forum .NET Windows FormsAntworten: 0Letzter Beitrag: 08.10.07, 09:26 -
Outlook Express Fehler bei Bilder vorschau
Von babone im Forum Office-AnwendungenAntworten: 4Letzter Beitrag: 16.10.03, 22:48





Zitieren
Login






[PHP][Snippet] Array zu XML konvertieren