Ir para conteúdo

POWERED BY:

Arquivado

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

W. Sales

[Resolvido] FCKEditor Grava, abre, mas não atera no banco de dados

Recommended Posts

<!-- #INCLUDE file="fckeditor.asp" -->

 

<%If session("usr_log_ok")="" Then

Response.Write "Você está Logado no sistema!"

Response.write "<a href='login.asp'>Clique aqui para se logar.</a>"

Session("pagina_restrita") = Request.ServerVariables("SCRIPT_NAME")&"?"&request.ServerVariables("QUERY_STRING")

Response.End()

End If

set conexao = Server.CreateObject("ADODB.Connection")

conexao.provider= "Microsoft.Jet.OLEDB.4.0;Data Source="&Server.MapPath("dados/dados.mdb")&";"

conexao.open

SQL = "select * from usuarios where id_usuario ="&session("usr_log_ok")

Set RS = Conexao.Execute(SQL)

If rs.eof then

Response.write "Ocorreu um erro ao se logar no sistema!"

Else %>

 

<title>:: Web 3 ::</title>

</head>

 

<STYLE type=text/css>

BODY

{

font-family: verdana;

font-size: 12px;

color: #000000;

scrollbar-face-color: #DEE3E7;

scrollbar-highlight-color: #FFFFFF;

scrollbar-shadow-color: #DEE3E7;

scrollbar-3dlight-color: #D1D7DC;

scrollbar-arrow-color: #006699;

scrollbar-track-color: #EFEFEF;

scrollbar-darkshadow-color: #98AAB1;

}

 

BODY {

BACKGROUND-REPEAT: repeat-y

}

TD {

FONT-FAMILY: verdana,arial,helvetica,sans-serif; FONT-SIZE: 11px

}

P {

FONT-FAMILY: verdana,arial,helvetica,sans-serif; FONT-SIZE: 11px

}

LI {

FONT-FAMILY: verdana,arial,helvetica,sans-serif; FONT-SIZE: 11px

}

 

A {

text-decoration: none;

color: #000000;

}

 

A:Hover {

text-decoration: none;

color: #000000;

}

 

IMG {

border-color: #4D4B4D;

}

 

A:Visited {

text-decoration: none;

color: #4D4B4D;

}

 

A:Active {

text-decoration: none;

color: #4D4B4D;

}

 

</STYLE>

<script language="JavaScript" type="text/JavaScript">

function ValidaCadastro(form)

{

 

if (form.frm_login.value == "")

{

alert("Login não Informado!");

return false;

}

else if (form.frm_senha.value == "")

{

alert("Senha não informada!");

return false;

}

}

</script>

<style type="text/css">

<!--

.link2:link {

font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;

font-size: 11px;

color: #FFFFFF;

text-decoration: none;

}

.link2:visited {

font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;

font-size: 11px;

color: #FFFFFF;

text-decoration: none;

}

.link2:hover {

font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;

font-size: 11px;

color: #FFFFFF;

text-decoration: underline;

}

-->

</style>

<body leftmargin="0" topmargin="0" bgcolor="#F6F6F6">

 

<table cellpadding="0" cellspacing="0">

<tr>

<td background="img2/top.gif" width="778" height="134" valign="top">

<br>

<br>

<br>

<br>

 

 

<br>

<br>

<br>

<br>

 

 

 

 

<table cellpadding="0" cellspacing="0">

<tr>

<td width="20"> </td>

<td><table cellpadding="0" cellspacing="0">

<tr>

<td><strong><a href="addnotfoto-w.asp">Adicionar Notícias</a> - <a href="alteralista.asp">Alterar Conteudo</a> - <a href="apagalista.asp">Deletar Noticias</a></strong></td>

</tr>

</table></td>

</tr>

</table>

 

</td>

</tr>

</table>

<span style="font-size:12pt;"><b><br><%end if%></b></span></font></p>

 

<table width="642" align="center">

 

 

<form name="cidosilva" method="post" action="altera1.asp">

<tr>

<td width="59"><b><font face="Tahoma"><span style="font-size:9pt;">Título:

</span></font></b><font color="#000000" size="1" face="Verdana, Arial, Helvetica, sans-serif"><%

Set con = Server.CreateObject("ADODB.Connection")

con.Open "Driver={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("dados/dados.mdb")

sql = "SELECT * FROM Noticias WHERE id=" & Request.QueryString("id") & ""

set Rs = Con.Execute(sql)

%>

</font></td>

<td width="573"><input type="text" name="Topico" size="80" value="<%=Rs("Topico")%>"></td>

</tr>

<tr>

<td width="59">

<p><b><font face="Tahoma"><span style="font-size:9pt;">Manchete</span></font></b></p>

</td>

<td width="573">

<p><textarea name="Resumo" rows="3" cols="74"><%=Rs("Resumo")%></textarea></p>

</td>

</tr>

<tr>

<td width="59">

<p><b><font face="Tahoma"><span style="font-size:9pt;">Noticia</span></font></b></p>

</td>

<td width="573">

<p><%

Dim sBasePath, svalordocampo

sBasePath = Request.ServerVariables("PATH_INFO")

sBasePath = Left( sBasePath, InStrRev( sBasePath, "/_samples" ) )

svalordocampo = Rs("Noticia")

Dim oFCKeditor

Set oFCKeditor = New FCKeditor

oFCKeditor.BasePath = sBasePath

oFCKeditor.Value = svalordocampo

oFCKeditor.Create "Noticia"

%></p>

</td>

</tr>

<tr>

<td width="59">

<p><b><font face="Tahoma"><span style="font-size:9pt;">Classe</span></font></b></p>

</td>

<td width="573"><select size="1" name="Classe">

<option value="<%=Rs("Classe")%>"><%=Rs("Classe")%></option>

<option value="Esportes">Esportes</option>

<option value="Politica">Politica</option>

<option value="Economia">Economia</option>

<option value="Promocoes">Promocoes</option>

<option value="Eventos">Eventos</option>

</select></td>

</tr>

<tr>

<td width="59">

<p><b><font face="Tahoma"><span style="font-size:9pt;">Classe1</span></font></b></p>

</td>

<td width="573"><select size="1" name="Classe1">

<option value="<%=Rs("Classe1")%>"><%=Rs("Classe1")%></option>

<option value="Programas">Programas</option>

<option value="Menu">Menu</option>

</select></td>

</tr>

<tr>

<td width="59">

<p><b>Fonte</b></p>

</td>

<td width="573"><input type="text" name="Autor" size="40" value="<%=Rs("Autor")%>">

  </td>

</tr>

<tr>

<td colspan="2" width="636">

<p align="center"><input name="ID" type="hidden" id="ID" value='<%=request.querystring("ID")%>'><input type="submit" name="submit" value="Enviar notícia">

</td>

</tr>

</form>

</table>

Compartilhar este post


Link para o post
Compartilhar em outros sites

Poderia explicar melhor o seu problema?

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.