how can i refresh php page by click button (onclick funtion) in another php file

i have 2 file : a.php & b.php

so how to refresh page in b.php by click button in a.php

hope anyone can help me. Thanks

Recommended Answers

The simplest way is to have an hidden IFRAME and the second PHP file to trigger a JavaScript function that changes the innerHTML of a div in the first page. But the real solution is just AJAX.

Jump to Post

I agree ajax is the way to go. I suggest using jquery for handling ajax.

Jump to Post

All 6 Replies

The simplest way is to have an hidden IFRAME and the second PHP file to trigger a JavaScript function that changes the innerHTML of a div in the first page. But the real solution is just AJAX.

Member Avatar

I agree ajax is the way to go. I suggest using jquery for handling ajax.

thanks jkon and ardav!

thanks P0lT10n..

Member Avatar

;)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.