oha055 Posted November 8, 2011 Share Posted November 8, 2011 Hi! So I have got some code that looks like this: if (isset($_GET['view_log'])) { // show content (text from db) } When I click the button named "view_log" everything displays just fine, however I would like to be able to click the button again and make the content disappear. Is this possible using only PHP?? Thanks for the help! It is greatly appreciated! Quote Link to comment https://forums.phpfreaks.com/topic/250686-dynamically-displayinghiding-content-using-php/ Share on other sites More sharing options...
MasterACE14 Posted November 8, 2011 Share Posted November 8, 2011 if you want to do it dynamically use either Javascript or AJAX(if the database request needs to be done dynamically too). Quote Link to comment https://forums.phpfreaks.com/topic/250686-dynamically-displayinghiding-content-using-php/#findComment-1286165 Share on other sites More sharing options...
oha055 Posted November 8, 2011 Author Share Posted November 8, 2011 Ok, thanks! I thought it could maybe work by only using php, but I guess not! I'll check out js then Quote Link to comment https://forums.phpfreaks.com/topic/250686-dynamically-displayinghiding-content-using-php/#findComment-1286168 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.