Dynamically Built Websites: PHP
There are many different types of coding for making dynamic websites. I chose PHP as my programming language. It can be used with MySql, most hosting companies support php and give access to mysql, and there's a lot of information online to help you learn to use PHP & MySql.
Ease of maintenance - dynamically built websites have many advantages. One of the best advantages is ease of maintenance. For a site that uses PHP and MySql, adding or updating products for your website can be as easy as entering the data for the artwork/product into Mysql!
There are two great ways to use PHP to make dynamic galleries:
- With a MySql database
- With text files
With a MySql Database:
When I first started my website, I built every product page by hand as a static page. If I wanted to change the look of my product pages or the information for my artworks, I had to change all of those pages by hand! Templates can make static pages easier to handle, but static pages just cannot compare to dynamically built pages.
For a MySql database, I added columns for the name of the artwork, price, shipping, description, etc. I've also added a "medium" column to my database. In that column, I specify for each artwork whether it is a sculpture, a relief sculpture, a print, an aceo, or a bookmark. So the "Sculpture" gallery page searches through MySql and picks out each of the artworks where "medium" == "Sculpture". As I add more artworks into my MySql database, those artworks automatically generate in the appropriate galleries!
With Text Files:
While databases are great, and they make adding products as easy as logging into PHP MyAdmin, they can be slow to load and updating them can be time consuming if you have a lot of things to add or change. I've recently switched to text files, small files that tell your gallery which products to include based on user input. Each gallery uses the include command to include the appropriate file (sculpture.php, print.php, etc.), and each file lists all of the artworks and the attributes for each artwork. This process uses Sessions, associative arrays, and is coding intensive, so knowledge of PHP is mandatory before attempting this route.
Search engines are now able to index sites with dynamic content - some people shy away from dynamic content because they have heard that dynamic pages cannot be indexed by search engines. Pages with urls that contained phrases such as '&id=' used to be hard for google and other search engines to index; but a major update in 2006 fixed that, so now google (and other search engines) can index these pages. That makes url structuring for your dynamic site much easier, as webmasters need not rewrite their dynamic links structure for this parameter. While search engines are now capable of indexing these pages, try to keep the number of parameters to a minimum - referring back to my own site, a previously constructed url such as this:
http://www.equusstudio.com/Type/Humans.php?ButtonThumb.x=66&ButtonThumb.y=51&ButtonThumb=13
was listed in the google index.
|