troubleshooting Question

Jquery and PHP

Avatar of jonathan-dunstans
jonathan-dunstansFlag for United Kingdom of Great Britain and Northern Ireland asked on
7 Comments1 Solution518 ViewsLast Modified:
I am working on an update of our recruitment site as am looking into using a dropdown to allow the user to access the content. I have gotten the drop down working fine I just can't work out a way to get the usage stats that we currently have from when users view an advert.

How can I get a one added to the correct entry when a user clicks through? I am using jquery and php with a mysql database.

For example a user clicks on our top job ad the content unfurls below the job title and a click is registered in our database to show that someone has viewed it.

For all I know this could be done solely with javascript but my jscript knowledge is in its infancy.
<script src=""></script>
$(document).ready(function() {
$('a.linka').click(function() {
        var id = $(this).attr('id');
     $('#linkbox' + id).toggle(500);
        // alert(id);
     return false;
<div class="linkbar"><a href="'.$reclist['jobID'].'" id="'.$reclist['jobID'].'" class="linka" name="'.$reclist['jobID'].'" style="color:#BA3F3F">'.$reclist['jobTitle'].'</a></div>
if (!empty($reclist['logo'])) { echo '<img src="mysite/images/recruitment/logos/'.$reclist['logo'].'"'; if($width > 150){ echo ' width="150">'; }else{ echo 'height="70">'; }} echo'
<td colspan="4">
<div id="linkbox'.$reclist['jobID'].'" class="linkbox" style="display:none">

Open in new window

Join our community to see this answer!
Unlock 1 Answer and 7 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 7 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros