Heim  >  Artikel  >  Web-Frontend  >  超链接文字的 右边有个图片,是用css弄在一起的吗?_html/css_WEB-ITnose

超链接文字的 右边有个图片,是用css弄在一起的吗?_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 12:24:15802Durchsuche



超链接文字的 右边有个图片,是用css弄在一起的吗?

请问该怎么写?  谢谢


回复讨论(解决方案)

可以在超链接后追加DIV,内部包含图片,之后控制图片的LEFT和TOP即可。POSITION可以用相对位置

.position {    position: relative;    left: 0px;    top: 0px}

可以在超链接后追加DIV,内部包含图片,之后控制图片的LEFT和TOP即可。POSITION可以用相对位置

.position {    position: relative;    left: 0px;    top: 0px}


那个图片和超链接一样可以点击的,我觉得他们是做成一体的

这其实有几种方式:
1. 超链接和图片放在同一个DIV,且DIV的鼠标样式设为手型并加CLICK事件
2. IMG设置鼠标样式为手型并加CLICK事件

LZ可以二选一

这其实有几种方式:
1. 超链接和图片放在同一个DIV,且DIV的鼠标样式设为手型并加CLICK事件
2. IMG设置鼠标样式为手型并加CLICK事件

LZ可以二选一
我直接用css  background

Stellungnahme:
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn