Usamos cookies para medir audiência e melhorar sua experiência. Você pode aceitar ou recusar a qualquer momento. Veja sobre o iMasters.
Gostaria de pegar o $id e colocar no titulo,
Ex: "$id" mais uma frase padrão para todo resto
Alguem pode me salvar dessa?
Obrigado
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "[http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">http-equiv="distribution" content="global" /><meta http-equiv="resource-type" content="document" /><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /><link rel="stylesheet" type="text/css" href="style.css" /></head><body> <div align="center"> <table width="770" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td align="center" colspan="0"> </td> </tr></table><div align="center"> <?phprequire("config.php");$qnt = $colunas*$linhas;$id = $_GET['id'];$dir = "./".$id."/";$offset = $_GET['offset'];$offset2 = $_GET['offset2'];if(!isset($offset)){ $offset = 0; }if(!isset($offset2)){ $offset2 = 0; }$dt = opendir($dir);while (false !== ($filename = readdir($dt))) { if($id){ $check = substr(strtolower($filename),-4); if (($check == ".jpg" or $check == ".jpe" or $check == "jpeg" or $check == ".gif") and substr(strtolower($filename),-9) != "thumb.jpg") { $total += 1; } } else { if(is_dir($filename) and $filename != "." and $filename != ".."){ $total += 1; } }}$dh = opendir($dir);$conta = 0;if($id){ ?> <table width="750" class="table" align="center" cellpadding="5" cellspacing="5"> <tr> <td align="center" colspan="4"> </td> </tr> <tr> <td align="center" colspan="<?=$colunas;?>"> <h1><?=str_replace("_"," ",$id);?></h1><h2>Titulo</h2></td></tr> <tr> <? $contaT = 0; $contaT2 = 0; while (false !== ($filename = readdir($dh)) && $contaT < $qnt) { $check = substr(strtolower($filename),-4); if (($check == ".jpg" or $check == ".jpe" or $check == "jpeg" or $check == ".gif") and substr(strtolower($filename),-9) != "thumb.jpg") { if($contaT2 >= $offset2){ if(file_exists($dir.$filename.".tn1")) { ?> <td align="center"><span class="art-shadow"><a href="<?=$dir.$filename;?>" target=_blank><img src="<?=$dir.$filename;?>.tn1" alt="<?=$dir;?>"/></a></td> <? } else { ?> <td align="center"><a href="<?=$dir.$filename;?>" target=_blank> <img src="thumb.php?arquivo=<?=$dir.$filename;?>" alt="<?=$dir;?>"/></a></td> <? } $conta += 1; $contaT += 1; } $contaT2 += 1; if($conta>=$colunas){ echo("</tr><tr>"); $conta = 0; } } } ?></tr> <? if($total > $qnt){ ?> <tr> <td colspan="<?=$colunas;?>" align="center"> <table border="0" cellpadding="00" cellspacing="0"> <tr><P> <?php for($i=0;$i<$total/$qnt;$i++){ ?> <td align="center" class="nav" width="18" height="19"> <? if($i==$offset2/$qnt){ ?><font size="5"><? } ?> <a href="<?=$_SERVER['PHP_SELF'];?>?id=<?=$id;?>&offset2=<?=$i*$qnt;?>&offset=<?=$offset;?>"> <?=$i+1;?> </a> <? if($i==$offset2/$qnt){ ?></font><? } ?> </td> <?php } ?> </tr> </table> </td> </tr> <? } ?> <tr> <td align="center" colspan="<?=$colunas;?>"><blockquote><a href="<?=$_SERVER['PHP_SELF'];?>?offset=<?=$offset;?>" class="classe1"> Outras Galerias</a></blockquote> </td> </tr></table><? } else { ?><br /><table width="740" border="0" align="center" cellpadding="3" cellspacing="3"> </td> <tr> <h1>H1</h1> <h2>H2</h2> <? while (false !== ($filename = readdir($dh))) { if(is_dir($filename) and $filename != "." and $filename != ".."){ $dh2 = opendir("./".$filename."/"); $conta2 = 0; $arq = ""; while (false !== ($filename2 = readdir($dh2))) { $check2 = substr(strtolower($filename2),-4); if (($check2 == ".jpg" or $check2 == ".jpe" or $check2 == "jpeg" or $check2 == ".gif") and substr(strtolower($filename2),-9) != "thumb.jpg") { if($conta2==0){ $conta2+=1; $arq = $filename."/".$filename2; } } } ?> <td><span class="art-shadow"><a href="<?=$_SERVER['PHP_SELF'];?>?id=<?=$filename;?>" class="classe1"><img src="thumb.php?arquivo=<?=$arq;?>" alt="<?=$filename;?>"/> <?=$filename;?></a></span></td> <? $conta += 1; if($conta>=4){ echo("</tr><tr>"); $conta = 0; } } } ?> <?}?> </tr></table> <table width="750" border="0" align="center" cellpadding="3" cellspacing="4"> <tr> <td align="center" colspan="0"></td></tr> </table> </body></html>Carregando comentários...