.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

Refresh an image with jquery

Posted By:      Posted Date: September 14, 2010    Points: 0   Category :ASP.Net
Hi,how can I refresh an image with below script.This  url returns '/CAPTCHAImage' an gif. I can get image with this but I can't set the gif to img.How can I do this?Kind regards.$.get('/CAPTCHAImage', function(data) { $("#guvenlikKodu").attr("src",data);});

View Complete Post

More Related Resource Links

slideshow image gallary using jQuery



i need a gallary like following link.


actually,i bound multiple image in a gridview using handler(.ashx).

for example,in one dep_id(1),there are 6 image and i need to slideing one by one.

could some one help me,how i can do like this?

i think is it easy in jquery.

please someone help me.

Thanking you.

how to refresh image updated with AsyncFileUpload


I've created an AsyncFileUpload device that uploads an image in ListView but it doesn't refresh on the page until the page is manually refreshed. Any ideas on how to accomplish this? This is the applicable code:

In ListView control:

<asp:UpdatePanel ID="udpPhoto" runat="server">
        <span style="text-align: center; vertical-align: middle; font-size: 7pt;">
            <br />
            <asp:Button ID="btnEPhoto" Font-Bold="False" TabIndex="160" Text="Upload/Change Photo"
                UseSubmitBehavior="False" OnClick="btnPhoto_Click" runat="server" />
            <br />
            <asp:Label ID="lblEPhoto" runat="server" Font-Bold="True" Text="Uploaded Photo:" />
            <br />
            <asp:HyperLink ID="lnkEPhoto" runat="server" BorderWidth="2px" NavigateUrl='<%# Eval("Photo_Recent") %>'
                <asp:Image runat="server" ImageUrl='<%# Eval("Photo_Recent") %>' Height="50px" ID="imgEPhoto">

jquery image loader in asp.net repeater

Hello folks., i am binding images to repeater from database. i want to load images one by one till that time imageloader.gif should display in place of all the loading Images. Plz suggest me any idea,i would like to use jquery for this.. thank youHello folks.,i am binding images to repeater from database.i want to load images one by one till that time imageloader.gif should display in place of all the loading Images.Plz suggest me any idea,i would like to use jquery for this..thank you

Refresh Cached image

Hello! I have an Image that is cached because I want to be able to change the file on runtime without getting exception about the file being in use. This works fine, but how can I programatically force a refresh of the image from file. I have a function that replace the file, so it would be nice to have a refresh function.  Is this possible?   <Image Name="imageThatIWouldLikeToRefreshFromCode"> <Image.Source> <BitmapImage UriSource="C:\image.jpg" CacheOption="OnLoad" /> </Image.Source> </Image>

how to call a event another page & refresh other page jquery

!) i have two page a with event   Bu_DocSearch_Click (object sender, System.EventArgs e)  i require it call another page and reftesh automatically protected void Bu_DocSearch_Click (object sender, System.EventArgs e){            //+" order by a.ID";            string sql="";            string S_SubjectContain=CCUtility.ToSQL((Utility.GetParam("txt_SubjectContain")+"%"),FieldTypes.Text);;            string Find=" and a.Subject Like "+S_SubjectContain;            //string Find=" and a.Subject ='"+S_SubjectContain+"%'";                                ArrayList SelectedChkBox =new ArrayList();                SelectedChkBox =Utility.CheckboxSelected(CheckBoxBind);                    string Inclause="";            for(int i=0;i<SelectedChkBox.Count;i++){ 

Jquery to display image map in sharepoint


I need to use google maps in sharepoint site .

and need to highlight on mouseover location stored in the list.

this list contains location name and co-ordinates of the location.

how can I use Jquery to display image map in sharepoint.Plesae give some initial thoughts.


Rebind datalist after upload an image using jquery


Hi, I'm having a problem with using jquery to trigger a datalist rebind here, hope people here could help me with it. 

I'm using a jquery plugin called uploadify to upload images to my database. I'd like my datalist to be auto-rebind after the images' been uploaded so people could see the changes immediately. Also because this is a feature for admin there is a delete button in the datalist. I used updatePanel for this.  

I put __doPostBack('" + upnlUploaded.ClientID + "','') to the javascript so when Images have been uploaded the update panel will postback. 

I also have the following two lines to make it working... 

<asp:UpdatePanel ID="upnlUploaded" runat="server" UpdateMode="Conditional" OnLoad="upnlUploaded_Load"> <%--upnlUploaded_Load   --%>

       <asp:UpdatePanel ID="upnlUploaded" runat="server" UpdateMode="Conditional" OnLoad="upnlUploaded_Load"

        protected void upnlUploaded_Load(object sender, EventArgs e)

How to refresh MVC form using Jquery without getting the resend popup


I have a MVC form. want to refresh it without getting the resend/Retry popup.i want to post the data again but it gives me Resend/Retry popup.

I think in asp.net we get it by window.document.forms["formname"].submit();

but how can i accomplish it in Asp.net MVC?

Please help.

Image Refresh problem


Im quite new to WPF and I'm stuck with an refresh issue.
The scene is as follows:

1) I have a form with an image on it.
2) A screenshot is made, and saved to the above mentioned image. (from the app)
3) The image should be refreshed to show the new image (but same file)

However I can not get it to work.
I can see the file is changing on the disk (viewing it and timestamp) and even in the WPF designer the image changes, but not in the running app :-/

I don't know what wrong. (other than the image does not refresh). So can anyone help?
My code is as follows:


<Window x:Class="Imagetest.Window1"




Jquery Image Slider



I want to implement a jquery image slider exactly like the one in this website http://www.ea.com/ , placed at the bottom of the page

I have searched for the examples that can help in building this type of demo but still not succeded.

Can anyone know any example to build this image slider?

Any help will be really appreciated. 



Display progress image when page is loading using jquery


hi friends,

When I click Submit button in my Registration form it should be open a (div) progress bar Showing processing.... (or) loading  and block background.


how to display a progress bar loading.... in div after Submit button click??


plsssssss tell me,it's very urgent.

Many Thanks in Advance.

Image display through jQuery!


Hi, I have a set of images which are subjected to display inside a usercontrol(horizontally) but while loading the page the images are displaying  vertically. Only after the page completely loaded they are displaying properly. How can I use jQuery to hide the images when the page is loading and display them when the page is fully loaded. Below is the usercontrol code I am using for displaying controls:

<%@ Control Language="C#" AutoEventWireup="false" CodeBehind="cbLeadStory.ascx.cs" Inherits="Monster.Seeker.Content20.Web.Controls.cbLeadStory" EnableViewState="false" %>

<asp:PlaceHolder runat="server" ID="phAjaxControlContainer">
    <div runat="server" id="div_container">
        <asp:PlaceHolder runat="server" ID="plcStatic"><%= this.BlockHtml %></asp:PlaceHolder>
        <asp:PlaceHolder runat="server" ID="plcCarousel">
            <div class="ajaxLoading"></div>
            <span id="content"><%= this.BlockHtml %></span>
            <div id="paging"></div>
            <script type="text/javascript" language="javascript">

can't refresh image in ModalPopup


I have a page where the following code works to refresh an updated image, but it won't work in another page. (The Util.FindChild is an enhanced FindControl that I use.) I'm sure it has to do with the ModalPopupExtender not closing but I don't know what to do about it. I also use a ModalPopupExtender on the other page and it works--in fact, both are virtually identical since they both originate from the same user control. Any ideas?

'these three statements could be cleaner but at present 
'they come from a number of controls in different templates
Dim img As WebControls.Image = DirectCast(Util.FindChild(Me, "imgUploaded"), WebControls.Image)
If img Is Nothing Then img = DirectCast(Util.FindChild(Me, "imgUploadedE"), System.Web.UI.WebControls.Image)
If img Is Nothing Then img = DirectCast(Util.FindChild(Me, "imgUploadedT"), System.Web.UI.WebControls.Image)
If img IsNot Nothing Then
   ScriptManager.RegisterClientScriptBlock(Me, _
      GetType(Page), _
      "imageRefresh", _
      "window.parent.document.getElementById('" _
      + img.ClientID + "').src='" + strFile + "?t=" + _
      (New Random().Next(9999)).ToString() + "';", _
End If

how to enlarge the image in jquery


iam using this jquery for displaying the image....but it displays the image as very small image though image is big...how to enlarge the image..within this code

var newImage = $('<img />');

newImage.attr('src', '<%= ResolveUrl("../../Content/Images/" )%>' + optionData.Image);


Refresh Parent Page when close the jquery dialog



I have to open PopupPage.aspx from MainPage.aspx using jquery Dialog. For this i have added the iframe inside the Div and loaded the PopupPage.aspx in the iframe. 


    <link href="inc/css/jquery-ui-1.8.6.custom.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="inc/scripts/jquery-1.4.2.min.js"></script>
    <script type="text/javascript" src="inc/scripts/jquery-ui-1.8.6.custom.min.js"></script>

    <script type="text/javascript" language="javascript">
        function OpenJQueryDialog()
            $('#dialog-modal').dialog({ autoOpen: false, bgiframe: true, modal: true });                         

GridView Confirmation Box Using JQuery BlockUI in asp.net

JQuery is the most popular JavaScript library. One of the main reasons for its fame is the plugin architecture. Anyone can create a separate library that leverage the JQuery library. In this article we are going to look at the BlockUI library which is used to block the user screen while performing a task.

jQuery $(document).ready() and ASP.NET Ajax asynchronous postback

Many call it the ASP.NET jQuery postback problem, but using the technique below should make it no problem anymore. $(document).ready() isn't called after an asynchronous postback. What this means? You lose the functionality that should be executed within $(document).ready() after an UpdatePanel rendered its contents after an asynchronous postback.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend