Ver Mensaje Individual
  #4 (permalink)  
Antiguo 31/05/2012, 06:34
kseso?
Colaborador
 
Fecha de Ingreso: junio-2007
Mensajes: 5.798
Antigüedad: 16 años, 10 meses
Puntos: 539
Respuesta: Copiar con rastro

En primer lugar dejar constancia que este es un recorte que no recuerdo su origen o autoría. Así que mis disculpas por no otorgar el debido crédito.

Código Javascript:
Ver original
  1. <script type="text/javascript">
  2. function addLink() {
  3.     var body_element = document.getElementsByTagName('body')[0];
  4.     var selection;
  5.     selection = window.getSelection();
  6.     var pagelink = "<br />Información original de: <a href='"+document.location.href+"'>"+document.location.href+"<br />Añade algo más que la dir del sitio<br />";
  7.     var copytext = pagelink + selection + pagelink;
  8.     var newdiv = document.createElement('div');
  9.     newdiv.style.position='absolute';
  10.     newdiv.style.left='-99999px';
  11.     body_element.appendChild(newdiv);
  12.     newdiv.innerHTML = copytext;
  13.     selection.selectAllChildren(newdiv);
  14.     window.setTimeout(function() {
  15.     body_element.removeChild(newdiv);
  16.     },0);
  17. }
  18. document.oncopy = addLink;
  19. </script>

Pero como verá, se necesita algo más que html.
Pida le trasladen la consulta al foro apropiado.
__________________
Por una web con mucho estilo
+++ CUENTA ABANDONADA. ¿la quieres? +++