<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:arial,helvetica,sans-serif;font-size:12pt"><div style="font-family: arial,helvetica,sans-serif; font-size: 12pt;"><br><div style="font-family: arial,helvetica,sans-serif; font-size: 13px;">> /* This is not intended to fuel a heated debate about which is better! */<br>><br>> I just need to be clear in my mind as to which is appropriate to use and<br>> when. I recognise that one is server side and the other is browser side.<br>> I see both as tools in a toolbox and therefore use as appropriate.<br>><br>> The way I see them: JavaScript for presenting web pages, PHP for data<br>> handling and processing.<br>><br>> Am I on the right tracks? I would welcome your thoughts on this, if you<br>> can give me an example/s where one is more appropriate to employ than<br>> the other, or indeed where they both live happily
together! Obviously<br>> there are areas where they overlap.<br>><br><br><br>>It should be the case that Javascript merely enhances the user <br>>experience - e.g. adding a popup calendar, rather than someone having to <br>>type in 2010/01/21 or provides e.g client side validation (i..e no need <br>>to click submit and wait for the server to respond).<br><br>>In an ideal world, PHP does everything (validation, data presenting etc) <br>>and then Javascript perhaps makes the page more interactive - but if JS <br>>is turned off everything continues to be usable.<br><br>>David.<br><br>Hi David<br><br>This is how I see it. I just need to mindful of the "if JS is turned off everything continues to be usable."<br>I have seen some very nice and well presented content using JS which you can't do with PHP, hence my question. <br><br>Mo<br><br><br><br><br></div></div>
</div><br>
</body></html>