Getting variable value from PHP with jQuery

前端 未结 4 1498
一向
一向 2021-01-16 07:50

So how do i get variable value from php file with jquery...? the jquery code is in other file (tpl)

for example i have register.php and register.tpl (template file f

4条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-16 07:58

    Either you make a Jquery Ajax Request that will request a php page which will return whatever you want or you echo a javascript variable with php

     var javascript_variable = "whatever"; '; 
    ?>
    

提交回复
热议问题