Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Pop-up Type Dialog when clicking cell in datatable

Posted on 2014-09-18
11
Medium Priority
?
1,336 Views
Last Modified: 2014-09-26
Wow has this site been helpful.  I don't want to single anyone out for fear of missing someone but there have been a few very helpful experts on my journey through this process and I have learned a ton on the way.  I have one more task )for now).  on ththis page I would like to have a classic asp page/div/etc dialog "pop-up" when clicking on the person's name.  The asp code is already written...just need to know how to get it from a click on a specific name.

Thanks!
0
Comment
Question by:Bob Schneider
  • 5
  • 3
  • 2
10 Comments
 
LVL 34

Assisted Solution

by:Big Monty
Big Monty earned 800 total points
ID: 40330061
Have you looked into jquerys modal dialog box?

http://jqueryui.com/dialog/

It's a bare  bones dialog box good for simple uses and can be customized a bit.

For something a bit more powerful check our LightView

http://www.nickstakenburg.com/projects/lightview/

I like e it a lot because it's simple to set up and the documentation is good
0
 

Author Comment

by:Bob Schneider
ID: 40330082
Good choices.  Thank you!
0
 

Author Comment

by:Bob Schneider
ID: 40330088
Oh, crap...but how do I get it to fire based on a click from a cell in my datatable.  Should I post a new question?
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 54

Assisted Solution

by:Scott Fell, EE MVE
Scott Fell,  EE MVE earned 1200 total points
ID: 40330203
If you use http://getbootstrap.com/ there is a modal built into the framework.  It will make your front end a lot easier to manage and the modal code is easier as well.
0
 
LVL 54

Assisted Solution

by:Scott Fell, EE MVE
Scott Fell,  EE MVE earned 1200 total points
ID: 40330211
I don't see a real answer here.  Do you need help with the actual code?
0
 

Author Comment

by:Bob Schneider
ID: 40330362
Let me look at your link...I think you gave that to me before...sorry.  I will  repost as needed.
0
 
LVL 54

Assisted Solution

by:Scott Fell, EE MVE
Scott Fell,  EE MVE earned 1200 total points
ID: 40330472
Do you need actual code or do  you understand what to do.  I don't see that just the link answer here is of any use. We can reopen up the question.
0
 

Author Comment

by:Bob Schneider
ID: 40330509
Lets either re-open or I can post a new one.  I am certain I am going to need some assistance.
0
 

Author Comment

by:Bob Schneider
ID: 40333800
Ok so I have downloaded bootstrap and unzipped it.  

1) Do I need to do install Bower and, if so, how?
2) Ditto with Grunt.
0
 
LVL 34

Accepted Solution

by:
Big Monty earned 800 total points
ID: 40336776
I don't necessarily agree that Bootstrap is the way to go on this one. It has somewhat of a steep learning curve and since you have most of your front end already built out, this seems like overkill.

i found this discussion on the datatables forums, it seems to do what you're ultimately looking to fire a javascript function on a cell click:

$("#myTable tbody tr").live("click", function(event){
    var position = myTable.fnGetPosition(this); // getting the clicked row position
    var id = myTable.fnGetData(position)[0];    // getting the value of the first column
   // displayUserInfo(id);
   alert('You clicked on " + id );
    });

Open in new window


if you can get the alert to come up with the proper cell text, it'll be easy to make that into a nice pop up. All you need to do is change the datatable ID with the one you're using
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Confluence of Individual Knowledge and the Collective Intelligence At this writing (summer 2013) the term API (http://dictionary.reference.com/browse/API?s=t) has made its way into the popular lexicon of the English language.  A few years ago, …
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses

577 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question