If and only if you are using PHP then try this script in your header:
PHP Code:
<head>
...
...
...
<?php
// input criteria
$category = 'region_dallas_photos';
// replace 'region_' with 'bg-'
$category = substr( 'region', 'bg-', $category);
// replace '_photos' with '.jpg'
$category = str_replace(_photos'', '.jpg', $search);
// new background
$bg_new = $category;
?>
<style type='text/css'>
.td-top { background-image: url(img/<?php echo $bg_new;?>);}
</style>
</head>
<body>
Typical background image names will be 'bg-chicago.jpg', 'bg-newyork.jpg', 'bg-buffalo.jpg'.
Makes it easier for alphabetic path sorting.
Bookmarks