Click here to Skip to main content
13,046,045 members (47,976 online)
Rate this:
Please Sign up or sign in to vote.
See more:
I have a page which contains some panels,each panel contains a image and a label with the description of the image. I am trying to display a modal popup when user clicks on any part of the panel. In the modal popup some other details will be displayed but the image will be there.Images will be taken from database.I need to fetch the image id from the panel and need to supply it to the modal popup panel. But the problem is panel does not contain a server side click event. I don't want to post back the entire page on click on the panel. Any suggestion ? Thanks in advance.
Posted 6-Jan-13 6:33am

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

There are no server side click events. There's a click event on the client which creates a postback.

The best answer for AJAX is always to use jquery, and avoid the MS AJAX library. The MS library always does a full postback, even if it's not clear to you that it does.
Boy in the Box 8-Jan-13 12:22pm
thanks for your answer .. I was just thinking that I can do a post back using javascript and save the id of the image in that panel in a session variable then i can set the url of the of the image in pop up using the value of the session variable.But for this I need a full post back . Please suggest me a way so that I can avoid full post back .
Christian Graus 8-Jan-13 14:05pm
You can store session values in an AJAX call. You use jquery to do real AJAX, not the MS library
Boy in the Box 27-Jan-13 2:18am
can u please help with code snippet

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web02 | 2.8.170713.1 | Last Updated 6 Jan 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100