Joining Data Tables with Onclick event (Error in Second Page)
Joining Data Tables with Onclick event (Error in Second Page)
dwin102003
Posts: 1Questions: 0Answers: 0
Good Day,
I am having trouble using Data Tables on my site. I have loop list of companies and icon with has view_profile class,
I use the view_profile class as an onclick event to access the companies profile. Using Data Tables it works fine on the First page but in the Second Page It doesn't work at all.
Here's my code
javascript code
[code]
$(document).ready(function(){
$(".view_profile").click(function(){
var company_id = $(this).attr('title');
alert(company_id);
});
});
[/code]
html code
[code]
List of Availables Companies
Company Name
<?php
if(count($get_company_list) > 0){
foreach($get_company_list as $key => $value):
?>
<?=$value['company_name']?>
<!---->
<?php endforeach; } ?>
[/code]
Thanks in advance
I am having trouble using Data Tables on my site. I have loop list of companies and icon with has view_profile class,
I use the view_profile class as an onclick event to access the companies profile. Using Data Tables it works fine on the First page but in the Second Page It doesn't work at all.
Here's my code
javascript code
[code]
$(document).ready(function(){
$(".view_profile").click(function(){
var company_id = $(this).attr('title');
alert(company_id);
});
});
[/code]
html code
[code]
List of Availables Companies
Company Name
<?php
if(count($get_company_list) > 0){
foreach($get_company_list as $key => $value):
?>
<?=$value['company_name']?>
<!---->
<?php endforeach; } ?>
[/code]
Thanks in advance
This discussion has been closed.