Multiple record on separate webpages

4 posts by 2 authors in: Forums > CMS Builder
Last Post: February 25, 2010   (RSS)

Re: [northernpenguin] Multiple record on separate webpages

By Dave - February 24, 2010

Hi northernpenguin,

No, you're on the right track. This can be a good approach.

The trick is figuring out how you want to associate images and pages. A few possible ways include:

- You can specify the image record number in the html/php

- You could use a 'tag' such as "about" or "services"

- You could detect the url, add a field for "url keyword" and only show an image for urls containing "services.php" for example.

Do you have any other content in the sidebar or an easy way to identify which page it is on?

Sometimes what I do is have a generic PHP include and then define a variable before I call it. Like this:

$GLOBALS['sidebarImage'] = "about_us";
<?php include "sidebar.php"; ?>

... then in sidebar.php ...

'where' = " imageTag = '{$GLOBALS['sidebarImage']}' ",

Hope that helps! Let me know if any of those ideas would work for you.
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Multiple record on separate webpages

Thanx Dave

I think I will try the tag method first and see how that will work for me.

There is no other content on the side bar, but the page itself is specific.

You can view it at http://www.globalknowledgeware.com/sandbox
--
northernpenguin
Northern Penguin Technologies

"Any sufficiently advanced technology
is indistinguishable from magic."
........Arthur C. Clarke

Re: [northernpenguin] Multiple record on separate webpages

By Dave - February 25, 2010

Great, let me know how it goes or if you have any more questions.
Dave Edis - Senior Developer
interactivetools.com