echo php variable from javascript and javascript is in php function : i have j.query function in P.h.p function. i have id of a div in p.h.p variable .i want to pass this variable to j.query code.
     

        public function food(){
            echo '<script>
            $(document).ready(function () {
                $("#$this->ccid #food").show();
            });
           </script>';
        }