asmith Posted November 22, 2007 Share Posted November 22, 2007 how can i disable my forms elements like select, or submit button or ... with php , NOT JAVASCRIPT. i mean for example when i click on a check box it disables submit button when i unckeck it , it activate submit button ... it is possible with php ? Quote Link to comment Share on other sites More sharing options...
trq Posted November 22, 2007 Share Posted November 22, 2007 Its possble, but not at all practical. PHP is server-side Buttons, checkboxes, html elements are all client side, hence there are client side scripting languages like Javascript specifically designed for such a thing. Quote Link to comment Share on other sites More sharing options...
asmith Posted November 22, 2007 Author Share Posted November 22, 2007 does it take too much coding ? Quote Link to comment Share on other sites More sharing options...
Wuhtzu Posted November 22, 2007 Share Posted November 22, 2007 I think what thorpe means is that you have to reload the page in order for the disabling / enabling of elements take effect. Often you would like it to happen dynamically when some chooses a certain item all options not related to that item will be grayed out or similar. With javascript it could be done without reloading the page, but with php you will have to reload the page. Quote Link to comment 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.