Accessing album pages

by on July 28, 2014

When I first started working on the stamp collection web site, pages were accessed through a php script that read HTTP GET variables and generated the album page based on the content of those variables. Example:

kevinsstampalbum.com/StampAlbum.php?CountryCode=RO&PageID=477

As I started getting occasional questions about some of the pages, I thought it might be interesting to see whether others might be interested in the answers. I was also curious whether providing feedback capability on each page might increase the level of interactivity. But rather than create the feedback capabilities under the existing php, I thought it would be really cool to put the static pages in a WordPress blog, with the album pages as static content in WP while notices of updates would be treated as blog entries.

The new links looked like this: http://kevinsstampalbum.com/stamps/romania/ro0477/

The .htaccess files contained the rules required to convert this URL into a link that the PHP in WordPress could use to load the correct stuff.

Since pages were not necessarily created in order, inserting pages became fairly difficult, so as the number of pages increased, I added scripts to automate page insertion and re-numbering, creation of update posts, and regeneration of TOC pages. Adding a new page now involves running a script that can take 20 minutes to execute.

Since WP allows variables to be embedded into each page, those embedded variables tell WP what to actually load with each “static” page. Different variables allow WP to use different templates for each type of page, and each template contains the ability to interpret page variables unique to each template.

But with each page change, certain elements are loaded over & over (which client caching ameliorates somewhat), a single-page web application would only reload those elements that actually change from one page to the next.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>