Ir para conteúdo

POWERED BY:

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

designmix

demora

Recommended Posts

galerao pq acontece isso nao da erro tambem nao mostra nada fica lendo um tempo e nada

 

<!--#include File="_conn/bib_conexao.asp"--><%strSQL = "Select * From fotos"call abre_conexaoSet rs = conn.Execute (strSQL) function GetBytes(flnm, offset, bytes)	 Dim objFSO	 Dim objFTemp	 Dim objTextStream	 Dim lngSize	 on error resume next	 Set objFSO = CreateObject("Scripting.FileSystemObject")	 Set objFTemp = objFSO.GetFile(flnm)	 lngSize = objFTemp.Size	 set objFTemp = nothing	 fsoForReading = 1	 Set objTextStream = objFSO.OpenTextFile(flnm, fsoForReading)	 if offset > 0 then		strBuff = objTextStream.Read(offset - 1)	 end if	 if bytes = -1 then		GetBytes = objTextStream.Read(lngSize)	 else		GetBytes = objTextStream.Read(bytes)	 end if	 objTextStream.Close	 set objTextStream = nothing	 set objFSO = nothing  end function  function lngConvert(strTemp)	 lngConvert = clng(asc(left(strTemp, 1)) + ((asc(right(strTemp, 1)) * 256)))  end function  function lngConvert2(strTemp)	 lngConvert2 = clng(asc(right(strTemp, 1)) + ((asc(left(strTemp, 1)) * 256)))  end function  function gfxSpex(flnm, width, height, depth, strImageType)	 dim strPNG 	 dim strGIF	 dim strBMP	 dim strType	 strType = ""	 strImageType = "(unknown)"	 gfxSpex = False	 strPNG = chr(137) & chr(80) & chr(78)	 strGIF = "GIF"	 strBMP = chr(66) & chr(77)	 strType = GetBytes(flnm, 0, 3)	 if strType = strGIF then	' se for GIF		strImageType = "GIF"		Width = lngConvert(GetBytes(flnm, 7, 2))		Height = lngConvert(GetBytes(flnm, 9, 2))		Depth = 2 ^ ((asc(GetBytes(flnm, 11, 1)) and 7) + 1)		gfxSpex = True	 elseif left(strType, 2) = strBMP then  ' se for BMP		strImageType = "BMP"		Width = lngConvert(GetBytes(flnm, 19, 2))		Height = lngConvert(GetBytes(flnm, 23, 2))		Depth = 2 ^ (asc(GetBytes(flnm, 29, 1)))		gfxSpex = True	 elseif strType = strPNG then   ' Se for PNG		strImageType = "PNG"		Width = lngConvert2(GetBytes(flnm, 19, 2))		Height = lngConvert2(GetBytes(flnm, 23, 2))		Depth = getBytes(flnm, 25, 2)		select case asc(right(Depth,1))		   case 0			  Depth = 2 ^ (asc(left(Depth, 1)))			  gfxSpex = True		   case 2			  Depth = 2 ^ (asc(left(Depth, 1)) * 3)			  gfxSpex = True		   case 3			  Depth = 2 ^ (asc(left(Depth, 1)))  '8			  gfxSpex = True		   case 4			  Depth = 2 ^ (asc(left(Depth, 1)) * 2)			  gfxSpex = True		   case 6			  Depth = 2 ^ (asc(left(Depth, 1)) * 4)			  gfxSpex = True		   case else			  Depth = -1		end select	 else		strBuff = GetBytes(flnm, 0, -1)		lngSize = len(strBuff)		flgFound = 0		strTarget = chr(255) & chr(216) & chr(255)		flgFound = instr(strBuff, strTarget)		if flgFound = 0 then		   exit function		end if		strImageType = "JPG"		lngPos = flgFound + 2		ExitLoop = false		do while ExitLoop = False and lngPos < lngSize		   do while asc(mid(strBuff, lngPos, 1)) = 255 and lngPos < lngSize			  lngPos = lngPos + 1		   loop		   if asc(mid(strBuff, lngPos, 1)) < 192 or asc(mid(strBuff, lngPos, 1)) > 195 then			  lngMarkerSize = lngConvert2(mid(strBuff, lngPos + 1, 2))			  lngPos = lngPos + lngMarkerSize  + 1		   else			  ExitLoop = True		   end if	   loop	   if ExitLoop = False then		  Width = -1		  Height = -1		  Depth = -1	   else		  Height = lngConvert2(mid(strBuff, lngPos + 4, 2))		  Width = lngConvert2(mid(strBuff, lngPos + 6, 2))		  Depth = 2 ^ (asc(mid(strBuff, lngPos + 8, 1)) * 8)		  gfxSpex = True	   end if	 end if  end function%><!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"><head><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /><title>Untitled Document</title><style type="text/css"><!--.style1 {	font-family: Verdana, Arial, Helvetica, sans-serif;	font-size: 10px;}--></style><script language="JavaScript" type="text/JavaScript"><!--function MM_openBrWindow(theURL,winName,features) { //v2.0  window.open(theURL,winName,features);}//--></script></head><body><p></p><table border="0" cellpadding="0" cellspacing="0">  <tbody>	<tr>	  <td width="449">		  <table cellspacing="0" cellpadding="0" border="0">			<tbody>			  <tr>				<td width="147" valign="top">				  <div align="left">					<table cellspacing="0" cellpadding="0" width="147" 								border="0">						<tbody>						  <tr>							<td><table height="88" cellspacing="1" cellpadding="1" width="147" bgcolor="#e6e6e6" border="0">								<tbody>								  <tr>									<td valign="center" align="middle" bgcolor="#ffffff"><div align="center">							  <% if rs("foto_p") <> "" then					Set objFS = Server.CreateObject("Scripting.FileSystemObject")					Set objFile = objFS.GetFile(server.mappath(rs("foto_g")))					If gfxSpex(objFile.Path, w, h, c, strType) = True then				%> 					<a href="javascript:" onClick="MM_openBrWindow('<% = rs("foto_g") %>','','width=<%= w+20%>,height=<%= h+30%>')"><img src="foto/<%=rs("foto_p")%>" width="139" height="80" border="0" id=foto2></a>				<%					End If					Set objFile = Nothing					Set objFS = Nothing				end if %>									</div></td>								  </tr>								</tbody>							</table>							</td>						  </tr>						</tbody>					</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table>				</div></td>				<td width="10"> </td>				<td width="147" valign="top"><table cellspacing="0" cellpadding="0" width="147" border="0">					<tbody>					  <tr>						<td><table height="88" cellspacing="1" cellpadding="1" width="147" bgcolor="#e6e6e6" border="0">							<tbody>							  <tr>								<td valign="center" align="middle" bgcolor="#ffffff"><div align="center"></div></td>							  </tr>							</tbody>						</table></td>					  </tr>					</tbody>				</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table></td>				<td width="10"> </td>				<td width="147" valign="top"><table cellspacing="0" cellpadding="0" width="147" border="0">					<tbody>					  <tr>						<td><table height="88" cellspacing="1" cellpadding="1" width="147" bgcolor="#e6e6e6" border="0">							<tbody>							  <tr>								<td valign="center" align="middle" bgcolor="#ffffff"><div align="center"></div></td>							  </tr>							</tbody>						</table>						</td>					  </tr>					</tbody>				</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table></td>			  </tr>			  <tr>				<td valign="top">				  <div align="left">					<table cellspacing="0" cellpadding="0" width="147" border="0">						<tbody>						  <tr>							<td><table height="88" cellspacing="1" cellpadding="1" 								width="147" bgcolor="#e6e6e6" border="0">								<tbody>								  <tr>									<td valign="center" align="middle" 								bgcolor="#ffffff"><div align="center"></div></td>								  </tr>								</tbody>							</table></td>						  </tr>						</tbody>					</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table>				</div></td>				<td> </td>				<td valign="top"><table cellspacing="0" cellpadding="0" width="147" 								border="0">					<tbody>					  <tr>						<td><table height="88" cellspacing="1" cellpadding="1" 								width="147" bgcolor="#e6e6e6" border="0">							<tbody>							  <tr>								<td valign="center" align="middle" 								bgcolor="#ffffff"><div align="center"></div></td>							  </tr>							</tbody>						</table></td>					  </tr>					</tbody>				</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table></td>				<td> </td>				<td valign="top"><table cellspacing="0" cellpadding="0" width="147" 								border="0">					<tbody>					  <tr>						<td><table height="88" cellspacing="1" cellpadding="1" 								width="147" bgcolor="#e6e6e6" border="0">							<tbody>							  <tr>								<td valign="center" align="middle" 								bgcolor="#ffffff"><div align="center"></div></td>							  </tr>							</tbody>						</table></td>					  </tr>					</tbody>				</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table></td>			  </tr>			  <tr>				<td valign="top">				  <div align="left">					<table cellspacing="0" cellpadding="0" width="147" 								border="0">						<tbody>						  <tr>							<td><table height="88" cellspacing="1" cellpadding="1" 								width="147" bgcolor="#e6e6e6" border="0">								<tbody>								  <tr>									<td valign="center" align="middle" 								bgcolor="#ffffff"><div align="center"></div></td>								  </tr>								</tbody>							</table></td>						  </tr>						</tbody>					</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table>				</div></td>				<td> </td>				<td valign="top"><table cellspacing="0" cellpadding="0" width="147" 								border="0">					<tbody>					  <tr>						<td><table height="88" cellspacing="1" cellpadding="1" 								width="147" bgcolor="#e6e6e6" border="0">							<tbody>							  <tr>								<td valign="center" align="middle" 								bgcolor="#ffffff"><div align="center"></div></td>							  </tr>							</tbody>						</table></td>					  </tr>					</tbody>				</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table></td>				<td> </td>				<td valign="top"><table cellspacing="0" cellpadding="0" width="147" 								border="0">					<tbody>					  <tr>						<td><table height="88" cellspacing="1" cellpadding="1" 								width="147" bgcolor="#e6e6e6" border="0">							<tbody>							  <tr>								<td valign="center" align="middle" 								bgcolor="#ffffff"><div align="center"></div></td>							  </tr>							</tbody>						</table></td>					  </tr>					</tbody>				</table>					<table height="10">					  <tbody>						<tr>						  <td></td>						</tr>					  </tbody>					</table></td>			  </tr>			</tbody>		  </table>		<!-- /ÄÁÅÙÃ÷ ¸®½ºÆ® --></td>	</tr>	<tr>	  <td align="middle"><div align="center"><a href="#"><img src="images/back.gif" width="42" height="13" border="0" /></a> <span class="style1">1 2 3 4 5 6 7 8 9</span> <a href="#"><img src="images/next.gif" width="42" height="13" border="0" /></a></div></td>	</tr>  </tbody></table><p> </p></body></html>

Compartilhar este post


Link para o post
Compartilhar em outros sites

Cara é muita sacanagem você postar um codigo desse tamanho e esperar que alguem fique analisando linha por linha pra você pra te dizer qual o problema... :angry:

Compartilhar este post


Link para o post
Compartilhar em outros sites

designmix...Também não olhei seu código, mas procure por duas coisas1 - Loop infinito2 - você tem antivirus ?...Se tiver desabilite-o.

Eai marcelo.Oque o antivirus influencia nisto??

Compartilhar este post


Link para o post
Compartilhar em outros sites

Tire o ON ERROR RESUME NEXT de seu código.

 

O antivirus pode bloquear a execução de Scripts, principalmente do FSO.

Compartilhar este post


Link para o post
Compartilhar em outros sites
Se não me engano, esse problema ocorre apenas com o Norton!
Já ví alguns posts de usuários de AVG com o mesmo problema.

Compartilhar este post


Link para o post
Compartilhar em outros sites

Nossa legal nem sabia dessa do Antvirus!E uma coisa tenta fazer o que o Salgado falo.Tire o ON ERROR RESUME NEXT de seu código.E ve o que retorna!

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.