I have an option box on a webpage and have around 10 options on it and have run into a doubt, which is more efficient to do:
1. <option value="1"<?php if($th_order==1){echo " SELECTED"; } ?>>Something1</option> <option value="2"<?php if($th_order==2){echo " SELECTED"; } ?>>Something2</option>
(or)
2. instead of having the <?php and ?> mixed in the HTML is it better to echo/print the whole lines?
Use a template engine to separate your presentation from your logic. :)
-- ---John Holmes...
Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/
php|architect: The Magazine for PHP Professionals – www.phparch.com
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php