Disculpa por no contestar antes:S, unas largas vacaciones y con eso que no checo mis mensajes privados, bien prueba con esto, espero todavia te sirva.:S
Código HTML:
Ver original<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<form id="form1" name="form1" method="post" action="galeria.php"> <table width="750" border="0" cellspacing="0" cellpadding="0"> <input type="submit" name="button" id="button" value="Cargar_galeria" /></td> <table width="750" border="0" cellspacing="0" cellpadding="0"> <?
if(isset($_REQUEST["button"])){
$carpeta = "imagenes";
$subcarpeta = $_POST["galeria"];
$dir = opendir($carpeta."/".$subcarpeta."/");
while($leer = readdir($dir)){
echo "<img src='$carpeta/$subcarpeta/$leer' />";
}
closedir($dir);
}else{
echo "Por favor, seleccione una opción.";
}
?>
Lo mas rapido que puedo ver es que, en $_REQUEST['name_del_boton'], debes de recibir el nombre del boton, si gustas hacerlo de esa forma