Ver Mensaje Individual
  #7 (permalink)  
Antiguo 01/04/2002, 08:46
sifi
 
Fecha de Ingreso: mayo-2001
Mensajes: 148
Antigüedad: 24 años
Puntos: 0
Re: Smyles en Libro de Visitas

Hola,


Pues yo también he estado mirando el código. Lo que he encontrado lo pongo aquí.El código que escribo es el que introduce, en la ventana de escribir mensaje, los símbolos : _ - () , ... cuando pulsamos sobre un smyles. Ahora abría que tener el código para transformar esto en dibujos. Seguiré mirando y estudiando el código.Si encuentro algo interesante lo escribo.Hasta pronto.Sifi.
--------------CÓDIGO--------------------
<SCRIPT language=Javascript type=text/javascript>
<!--
// Este genial Script fue desarrollado por Tukzone, SirMatrix y Unknow, todos usuarios del Foro.. Gracias a ellos por su colaboración


function storeCaret(text) {
if (text.createTextRange) {
text.caretPos = document.selection.createRange().duplicate();

}

}

function meter(text) {
var postopic=document.PostTopic.Message
if (postopic.createTextRange && postopic.caretPos) {
var caretPos = postopic.caretPos;
caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ?text + ' ' : text;
}
else postopic.value += text;
postopic.focus(caretPos)
}


function codigo(accion)
{
switch(accion)
{
case "url":
url = prompt("URL de el Enlace", "http://");
if(url)
{
url=&quot;<a href='ir.asp?http://&quot;+url+&quot;' target='_blank'>&quot;+url+&quot;...</a>&quot;;
meter(url);
}
break;
case &quot;bold&quot;:
negras = prompt(&quot;Texto en Negritas&quot;, &quot;&quot;);
if(negras)
{
negras=&quot;&quot;+negras+&quot; &quot;;
meter(negras);
}
break;
case &quot;italics&quot;:
italics = prompt(&quot;Texto en Italicas&quot;, &quot;&quot;);
if(italics)
{
italics=&quot;&quot;+italics+&quot; &quot;;
meter(italics);
}
break;
case &quot;code&quot;:
code=&quot; &quot;;
meter(code);
break;
case &quot;quote&quot;:
quote=&quot; &quot;;
meter(quote);
break;
default:
meter(accion);
break;
}
}
// --&gt;
&lt;/SCRIPT&gt;

-------Continúa más abajo-----




<center><A HREF=" http://www.elenet.org"><IMG SRC="http://www.elenet.org/GRAFICOS/ele468x60.gif"> </A> </center>