去过闪吧的人过来看一下,如何实现闪吧论坛里的快速回复功能,谢谢
点击对应心情图标,在文本框中会出现对应的如 ":) ",不明白的是如何做到在光标所在位置插入指定图标,还是就是怎样才能出现如放大镜功能,光标放在指定图标上,会出现一个大图标提示功能,如何实现,请指教.谢谢
------解决方案--------------------都是JavaScript功能能力范围之内的事情吧?这就看你的JavaScript基础了。其实纯粹的JavaScript问题,建议到对应的板问,那样比较容易更快地得到更好的答案。
------解决方案--------------------javascript
------解决方案--------------------图片放大: <SCRIPT LANGUAGE= "JavaScript ">
var offsetX=120;
var offsetY=00;
function Fpop()
{
var oImg =event.srcElement;
var px =oImg.offsetLeft;
var py =oImg.offsetTop;
popDiv.innerHTML = " <img src= " "+oImg.src+ " " /> "
popDiv.style.left =px+offsetX;
popDiv.style.top =py+offsetY;
popDiv.style.display= " ";
}
function Fhidden()
{
popDiv.style.display= "none ";
}
</SCRIPT>
<div id= "popDiv " style= "position:absolute;z-index:10;border:1px solid black;display:none; "> </div>
<img src= "http://www.ddvip.com/images/logo1.gif " width= "120 " height= "55 " onmouseout= "Fhidden() " onmouseover= "Fpop() ">
<Img Src= "http://www.ddvip.com/images/logo.gif " width=250hight=75 Border=0 onMouseOver= 'this.width=500 ' onMouseOut= 'this.width=250 '>
<Img Src= "http://www.ddvip.com/images/logo.gif " width=125 Border=0 onMouseOver= 'this.width=this.width*2 ' onMouseOut= 'this.width=this.width/2 '>