Re: problem formatting output

From: Date: Sun, 04 Jan 2015 16:56:16 +0000
Subject: Re: problem formatting output
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-324225@lists.php.net to get a copy of this message
Tim: > On Jan 3, 2015, at 10:31 PM, Tim Dunphy <bluethundr@gmail.com> wrote: > > Hey all, > > Followign along in php & mysql web development by Luke Welling and Laura > Thompson I came along an example to format the output text file. The file > was meant to hold the orders of a fctional online store. A text file to hold the orders of a fictional online store? That's not the way I would do it. My advice, take everything to a MySQL database. Place your Product, Customers, and Sales in different tables. That way it will become a simple matter to keep track of everything. > Here's the output of the code: > > Bob’s Auto PartsCustomer OrdersOrder DateTiresOilSpark PlugsTotalAddress9:49pm > EST Saturday, 01/03/2015125$140.00960 Fairview Dr08753010:05pm EST > Saturday, 01/03/2015125$140.00904 Sylvan Ave07632010:06pm EST Saturday, > 01/03/2015334$346.00900 Sylvan Ave07632010:07pm EST Saturday, 01/03/2015125 > $140.00960 Fairview Dr087530 > > As you can see, at the first line the address entry doesn't line up and > then throws the rest of the form out of whack. -snip- Try using CSS in your forms and thus take the styling out of them. Remember to separate content from presentation -- it will make your code much easier to debug. Cheers, tedd _______________ tedd sperling tedd@sperling.com

« previous php.general (#324225) next »