Usamos cookies para medir audiência e melhorar sua experiência. Você pode aceitar ou recusar a qualquer momento. Veja sobre o iMasters.
Este eh o meu codigo, a parte em negrito é a imagem que quero mudar...
Funciona assim. De acordo com o cadastro no banco de dados essa imagem irá mudar para cada registro.
Ex. se o campo "INTENCAO" for = 1, mostrar imgnormal.
se o campo "INTENCAO" for = 3, mostrar imgnervosinho
Já tentei com os if.. mas estou com dificuldades ainda...
É muito complicado ?
>
<%
set strConexao = CreateObject("ADODB.Connection")
strConexao.Open("DRIVER=Firebird/InterBase® driver; UID=SYSDBA;PWD=masterkey; DBNAME=localhost:C:\Teste\Mensageiro\Dados\MENSAGEIRO.FDB")
Set lista = Server.CreateObject("ADODB.Recordset")
Set lista = strConexao.Execute("SELECT * FROM tbmensageiro")%>
<style type="text/css">
<!--
.style1 {font-family: Arial, Helvetica, sans-serif}
.style2 {
font-size: 10px;
font-weight: bold;
}
.style3 {
font-family: Arial, Helvetica, sans-serif;
font-size: 10px;
font-weight: bold;
}
.style5 {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
font-weight: bold;
}
.style6 {font-size: 12px}
.style7 {font-size: 12px; font-weight: bold; }
.style8 {font-size: 10px}
.style9 {font-family: Arial, Helvetica, sans-serif; font-size: 11px; }
.style10 {font-size: 11px; }
.style11 {font-weight: bold}
.style13 {font-weight: bold}
-->
</style>
<center>
<table width="934" height="103" border="0">
<tr>
<td height="57" colspan="6" bgcolor="#FFFFFF"><img src="img/LOGObARRAsUPERbRASIL1.jpg" width="930" height="57" /></td>
</tr>
<tr>
<td colspan="6" bgcolor="#B9BCFF"> <span class="style6 style1 style2"> :: Caixa de Entrada ::</span></td>
</tr>
<tr>
<td width="23" height="21" bgcolor="#B9BCFF"> </td>
<td width="23" bgcolor="#B9BCFF"> </td>
<td width="140" bgcolor="#B9BCFF" class="style6 style1"><strong> :: De:</strong></td>
<td width="140" bgcolor="#B9BCFF" class="style6 style1"><strong>:: Para </strong></td>
<td width="485" bgcolor="#B9BCFF" class="style1"><div align="center" class="style11">
<div align="left" class="style7">:: Assunto:</div>
</div></td>
<td width="103" bgcolor="#B9BCFF"><div align="center" class="style6">
<div align="left" class="style5">:: Data:</div>
</div></td>
</tr>
</table>
</center>
<%
lista.MoveFirst
Do While not lista.Eof%>
<center>
<table width="936" height="25" border="0">
<tr>
<td width="24" height="21" bgcolor="#DFE1FF"><div align="center"><img src="img/cartinhaverde1.gif" width="18" height="12" /></div></td>
<td width="24" bgcolor="#DFE1FF"><div align="center**"><img src="img/normal.gif" width="19" height="19" />**</div></td>
<td width="134" bgcolor="#F2F2FF" class="style1"><div align="left" class="style8"><%=lista.fields("REMETENTE")%></div></td>
<td width="134" bgcolor="#F2F2FF" class="style9"><%=lista.fields("DESTINATARIO")%></td>
<td width="492" bgcolor="#F2F2FF" class="style1"><div align="center">
<div align="left" class="style10"><a href="detalhes.asp?gravacodigo=<%=lista.fields("CODMSG")%>"><%=lista.fields("assunto")%></a>
<td width="102" bgcolor="#F2F2FF" class="style9"><%=lista.fields("DATA")%></td>
</tr>
</table>
<%lista.MoveNext
Loop%>
</center>
<table width="938" height="29" border="0">
<tr>
<td width="932" height="25" colspan="6" bgcolor="#FFFFFF"><img src="img/BARRAINFERIORSAF.jpg" width="934" height="23" /></td>
</tr>
</table>pode ser LucasBr,melhor ainda !! como ficaria ?
caso você queira dar uma olhadinha de como esta ficando..
http://200.138.31.71:8031/asp/Mensageiro/teste.asp
login: pcgeison
senha: 123
ainda ta uma zona os arquivos.. só pra teste... depois eu crio um diretorio final.. :)
Isso Lucas ! Na hora de compor a mensagem, tenho que ver como vou fazer para aparecer os emotions, mas acho que poderia ser como o "icones do post" deste forum, cada img tem um radio button, e de acordo com o que for escolhido ele grava no banco !O que acha ?
Humm... legal !!Vou tentar aqui. QQ coisa posto ..Muito obrigado novamente !
Ola lucasBR !Entao, poderia ter varias, mas inicialmente eu queria deixar umas 5 imagens no server... sao parecidas com esses emotions que tem aqui.Quando fosse escrito uma nova mensagem ele ia la e escolhia um emotion, que seria traduzido para um numero no banco de dados...Quando fosse aberta a pagina principal, e fosse feito o select, de acordo com o numero cadastrado ele ia buscando as imagens e colocando no lugar..