Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1720
  • Last Modified:

How to include Jquery simple Model dialog in an asp.net project

First of all i wantto include the jquery simple modal dialog in an asp.net application, then
I need to call jquery simple mode dialog behind the click eventof a button in an asp.net project
0
Ammar Iqbal
Asked:
Ammar Iqbal
  • 4
  • 4
3 Solutions
 
CodebotCommented:
It is very simple
Just include reevant js and css files.
and then add code on button onclick event.

here are example with how to use tutorials
http://jquery.com/demo/thickbox/
or
http://www.ericmmartin.com/projects/simplemodal/
0
 
Alpesh PatelAssistant ConsultantCommented:
Create Model popup using jQuery and restrict to open on document.ready.
Open dialog on click of any HTML button click event. It works.
0
 
Ammar IqbalAuthor Commented:
for simple modal dialog, I have included these two js files in my .aspx page
script src="/js/jquery.simplemodal-1.4.1.js" type="text/javascript"></script>
 <script src="/js/jquery.simplemodal-1.4.1.min.js" type="text/javascript"></script>

is it right?

I am noticing, that each of the modal dialog has its own css and img files....Do i need to copy thiese in my respective folder of my project...
Is it possible to customize its css with respect of my project
0
Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.

 
Ammar IqbalAuthor Commented:
but how to create a model popup, can you give me a sample
0
 
CodebotCommented:
Yes you need all images and css file and you can customized everything according to your needs.
Example is given in my earlier post.
here are example with how to use tutorials
http://jquery.com/demo/thickbox/
or
http://www.ericmmartin.com/projects/simplemodal/
0
 
Ammar IqbalAuthor Commented:
I have added  nad include all the relvant files to invoke a contact form of simple dialog

i have included these files as well:
<link id="Link1" runat="server" type="text/css" href="/css/contact.css"  rel="stylesheet" />      
 <link id="Link2" runat="server" type="text/css" href="/css/demo.css"  rel="stylesheet" />
 
   <script src="/js/jquery.simplemodal.js" type="text/javascript"></script>
  <script src="/js/jquery.js" type="text/javascript"></script>
   <script src="/js/contact.js" type="text/javascript"></script>


Now the problem is that I need to invoke a contact form or a simple model dialog when the button is clicked. I am not figuring it out how to do this stuff in a right way.
Any suggestions?
0
 
CodebotCommented:
Simple add this link in your html

<p><a href="#" class="demo button">Demo</a> <a href="http://simplemodal.googlecode.com/files/simplemodal-demo-contact-1.4.1.zip" class="button">Download</a></p> 

Open in new window

0
 
CodebotCommented:
I mean

<a href="#" class="demo button">Demo</a>
#= your page
0
 
Ammar IqbalAuthor Commented:
partial solution
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 4
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now