I have jQuery function in a PHP function. I have id
of a div
in a PHP variable. I want to pass this variable to the jQuery code, but it is not working:
public function food(){
echo '<script>
$(document).ready(function () {
$("#$this->ccid #food").show();
});
</script>';
}