Win a copy of Serverless Applications with Node.js this week in the NodeJS forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Junilu Lacar
  • Paul Clapham
  • Knute Snortum
Saloon Keepers:
  • Stephan van Hulst
  • Ron McLeod
  • Tim Moores
  • salvin francis
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Frits Walraven
  • Vijitha Kumara

display image in center through php code  RSS feed

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sir, i want display my image on center....this code showing left side...need help


<?php

$files = glob("gallery/*.*");

for ($i = 0; $i < count($files); $i++) {

   $image = $files[$i];

   echo basename($image) . "<br />"; // show only image name if you want to show full path then use this code // echo $image."<br />";

   echo '<img src="' . $image . '" alt="" />' . "<br /><br />";

}

?>

Antony
Staff note (Knute Snortum):

This is a PHP question. I moved it to the appropriate forum.

 
Always look on the bright side of life. At least this ad is really tiny:
global solutions you can do in your home or backyard
https://coderanch.com/t/708587/global-solutions-home-backyard
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!