javascript waiting php to complete function and refresh page

后端 未结 1 544
你的背包
你的背包 2021-01-23 18:36

I have following case:

  1. I have drop down menu from where I select currency for a website and trigger javascript function changecurrency() using onchange event
1条回答
  •  野的像风
    2021-01-23 19:11

    Pass your callback function as the second parameter:

    jQuery('#div_session_write').load('update_currency.php?val=' + x, _callback);
    

    That way, it is automatically called by jQuery when the request finishes loading. See the documentation for more info: http://api.jquery.com/load/

    0 讨论(0)
提交回复
热议问题