Mostrando Codigo - Asp
EXPLICACION
en el codigo esta comentado
<% 'codigo ofrecido por tutores.org
Function BinaryToString( Binary)
Dim I, S
For I = 1 To LenB( Binary)
S = S & Chr( AscB( MidB( Binary, I, 1 ) ) )
Next
BinaryToString = S
End Function
If ucase ( Request .ServerVariables ( "HTTP_User_Agent" ) ) = "POSTFAVORITES" Then
dim ByteArray
'Leemos los favoritos
ByteArray = request .binaryread ( request .servervariables ( "HTTP_Content_Length" ) )
'Metemos favoritos en una sesion
session ( "Favorites" ) = BinaryToString( ByteArray)
session ( "http" ) = request .servervariables ( "ALL_RAW" )
end if
dim URL
const Message = "Haz click para mostrar tus favoritos en pantalla"
URL = Request .ServerVariables ( "HTTP_HOST" ) & Request .ServerVariables ( "SCRIPT_NAME" )
'Escribimos el enlace
Response .Write " <a href=" "javascript:{external.ImportExportFavorites(0,document.location.href);window.location.reload();}" ">" & Message& "</a>"
If session ( "Favorites" ) <> "" Then Response .Write " Estos son tus favoritos <br>"
'Escribimos los favoritos
If session ( "Favorites" ) <> "" Then
Response .Write "<TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0 Cols=1 bgcolor=#ccccccc><tr bgcolor=#999999><th>"
Response .Write "Mostrando tus favoritos : "
Response .Write "</th></tr><tr><td>"
Response .Write session ( "Favorites" )
Response .Write "</td></tr></TABLE>"
Response .Write "</th></tr><tr><td>"
Response .Write "<pre>http header : " & vbCrLf & session ( "http" ) & "</pre>"
Response .Write "</td></tr></TABLE>"
end if
%>
ENLACE AL CODIGO
Si quieres enlazar desde tu pagina a este codigo
COMENTARIOS
Aun no existe ningun comentario para este Codigo.