I have an image in a gridview,
我在gridview中有一个图像,
I want dynamic text inside this image. Text I am getting from this way from the database:
我想要动态文本在这张图片里面。我从数据库中获取的文本:
<%#DataBinder.Eval(Container.DataItem,"textForImage")%>
but to show inside this buuble? which control i have to use?
但是在这个小玩意里面呢?我需要使用哪个控件?
2 个解决方案
#1
2
You can set this image as a background-image
on a div
and place the text inside the div
and position it using CSS
您可以将此映像设置为div上的背景映像,并将文本放置在div中,并使用CSS将其定位
<div class="bubble">
<%#DataBinder.Eval(Container.DataItem,"textForImage")%>
</div>
.bubble
{
background-image:url(...);
}
#2
1
You need to set the background image of a division to the bubble and then create the text inside that division.
您需要将一个部门的背景图像设置为bubble,然后在该部门中创建文本。
#1
2
You can set this image as a background-image
on a div
and place the text inside the div
and position it using CSS
您可以将此映像设置为div上的背景映像,并将文本放置在div中,并使用CSS将其定位
<div class="bubble">
<%#DataBinder.Eval(Container.DataItem,"textForImage")%>
</div>
.bubble
{
background-image:url(...);
}
#2
1
You need to set the background image of a division to the bubble and then create the text inside that division.
您需要将一个部门的背景图像设置为bubble,然后在该部门中创建文本。