Reputation: 21
I have a normal link button where I am getting data through like this
<a href="ViewRemarks.aspx?jobid=<%#DataBinder.Eval(Container.DataItem,"jobid")
%>" id="btn_remarks" data-toggle="modal" data-target="#exampleModalCenter3"
class="open-AddBookDialog btn btn-outline-info " ><i class="fa fa-comments" ></i>
</a>
Note: in this button, I am getting data called job id
Then I took one bootstrap modal inside that modal I kept one child page like this
<iframe style="width: 470px; height: 195px;" id="Iframe1" class="embed-responsive embed-responsive-16by9" src="ViewRemarks.aspx?jobid=null"></iframe>
Note: iframe is not showing in stackoverflow don't know why but yes that is an iframe so i kept one a before iframe.
But here I want to pass that particular jobid from that button inside the data table how can I solve this in asp.net or javascript anything is accepted please help.
Upvotes: 0
Views: 206
Reputation: 207501
So use the link target which will load the link in the iframe.
<iframe name="iframe1" id="iframe1" />
and the link
<a href="//example.com?foo=bar" target="iframe1">My LInk</a>
<iframe name="iframe1" id="iframe1"></iframe>
<a href="//example.com?foo=bar" target="iframe1">My LInk</a>
Upvotes: 2