Best Practice
| From: | Ashley M. Kirchner | Date: | Sat, 21 Sep 2002 18:51:25 +0000 |
| Subject: | Best Practice | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-117111@lists.php.net to get a copy of this message | ||
I'm working on converting several static (price) pages on our site into dynamic pages, with
the data stored in an MySQL database and PHP to pull the data out, with CSS to build the page and
present it. At the same time, I would also like to have a 'printer friendly' link on each
page that visitors can click on and get the same page re-rendered for easy printing. What's
the best way to get the data converted from one form to another? Should I be querying the database
again to get the same data to reformat? Should I store the data in sessions and reformat based on
the CSS? I would think having to query twice for the same thing would be a degradation in
performance, right? So what's the best practice?
--
H | "Life is the art of drawing without an eraser." - John Gardner
+--------------------------------------------------------------------
Ashley M. Kirchner <mailto:ashley@pcraft.com> .
303.442.6410 x130
Director of Internet Operations / SysAdmin . 800.441.3873 x130
Photo Craft Laboratories, Inc. . 3550 Arapahoe Ave, #6
http://www.pcraft.com ..... . . . Boulder, CO 80303,
U.S.A.