在jquery对话框中显示图像 [英] displaying image in jquery dialog box

查看:70
本文介绍了在jquery对话框中显示图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我是mvc3和jquery的新手。



i希望在jquery对话框中显示图像。 />


我正在使用ajax调用action方法,并希望在对话框中显示该图像。



如何可以实现,否则给出其他方式在对话框中显示图像?



提前感谢...

hi ,
i'm new for mvc3 and jquery.

i want to show the image in jquery dialog box.

i'm calling the action method using ajax and want to show that image in dialog box.

how can achieve that otherwise give other way to show image in dialog box ?

thanks in advance...

推荐答案

与在该对话框中显示任何其他内容相比,我看不出显示图像会如何产生任何影响。您应该注意这个jQuery插件可以与HTML中已经存在的任何< div> 元素一起使用。所以,你可以按照你想要的方式编写这个元素的内部HTML,并把你想要的东西放在其中。



显示带有图像的最简单的代码示例,例如,在这里: http://stackoverflow.com/questions / 4452099 / display-images-with-jquery-ui-dialog-widget-like-in-fancybox [ ^ ]。



< dd> -SA
I don't see how showing an image could make any difference, compared with showing anything else in that dialog. You should have paid attention for the fact that this jQuery plug-in is designed to work with any <div> element which may already present in your HTML. So, you can write inner HTML of this element the way you want and put anything you want in it.

The simplest code sample with an image is shown, for example, here: http://stackoverflow.com/questions/4452099/display-images-with-jquery-ui-dialog-widget-like-in-fancybox[^].

—SA


我知道这是一个非常古老的问题仍然是解决方案



i know this is a very old question still the solution is


' 。ui-dialog-buttonpane'
.find(' button:contains(Noe)'
.removeClass(' ui-button-text-only'
.addClass( ' ui-button-text-icon-primary'
.prepend(' < span class =ui-icon ui-icon-closethic>< / span>');
('.ui-dialog-buttonpane') .find('button:contains("Noe")') .removeClass('ui-button-text-only') .addClass('ui-button-text-icon-primary') .prepend('<span class="ui-icon ui-icon-closethic"></span>');







问候,

VRN




Regards,
VRN


这篇关于在jquery对话框中显示图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆