Zen Cart Logo
Forums / Setting Up Categories, Products, Attributes / Sub category images missing

Sub category images missing

Views: 737

Results 1 to 5 of 5
13 Apr 2013, 4:18 PM
#1
thekenster avatar

thekenster

New Zenner

Join Date:
Jan 2012
Posts:
27
Plugin Contributions:
0

Sub category images missing

I am using a template supplied by monster and im not sure but since weve uploaded new images the category images no longer work. All that's displayed is the category properties which is repeated from the

Ive attempted to load them in the normal way but to no avail, checking some links ive ascertained this may well be the .php code related, it seems different to what other people have pasted on here, can anyone look at it and let me know why is specifies catbanner, and more importantly if there's anything wrong here.

tpl_index_categories.php

<?php* //if (PRODUCT_LIST_CATEGORIES_IMAGE_STATUS_TOP == 'true') { // categories_image $categories_image = zen_get_categories_image($current_category_id); if (is_file(DIR_WS_IMAGES . 'catbanner/' . $categories_image)) { ?> <div class="ttext2 tie-margin1"><?php echo zen_image(DIR_WS_IMAGES .'catbanner/'. $categories_image); ?></div> <?php // categories_image } else { ?> <?php // categories_description if ($current_categories_description != '') { ?> <div class="tie2 text2 tie-margin1"> <div class="tie2-indent"> <div class="catDescContent"><strong>Property categories:</strong><br /><?php echo $current_categories_description; ?></div> <?php } // categories_description } ?>

Ive attempted to load them in the normal way but to no avail, checking some links ive ascertained this may well be the .php code related, it seems different to what other people have pasted on here, can anyone look at it and let me know why is specifies catbanner, and more importantly if there's anything wrong here.

13 Apr 2013, 4:33 PM
#2
thekenster avatar

thekenster

New Zenner

Join Date:
Jan 2012
Posts:
27
Plugin Contributions:
0

Re: Sub category images missing

Just to add I found one page still works if I upload any image as long as I call it close up country bed.jpg even if I rename another image the actual image displayed is always as below using this path:

<div class="ttext2 tie-margin1"><img src="images/catbanner/close up country bed.jpg" alt="" width="600" height="600" /></div>
13 Apr 2013, 5:25 PM
#3
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: Sub category images missing

Apart from the fact that you are using a "dangerous" template, your naming of images is also bad (for unix and linux).

Image names should all be lower-case with NO SPACES IN THEM - so

close up country bed.jpg

SHOULD BE

close-up-country-bed.jpg

When you look at the source code you will see stuff like:

close%20up%20country%20bed.jpg as the browser desperately tries to interpret the spaces in a filename.

  1. Get rid of the TM junk... they cause a LOT of conflicts and are just not worth the hassle. It is possible to create the "look" of ANY t.m template using existing and compatible free ones.

  2. learn how to name files, folders and images correctly.

13 Apr 2013, 6:40 PM
#4
thekenster avatar

thekenster

New Zenner

Join Date:
Jan 2012
Posts:
27
Plugin Contributions:
0

Re: Sub category images missing

schoolboy:

Apart from the fact that you are using a "dangerous" template, your naming of images is also bad (for unix and linux).

Image names should all be lower-case with NO SPACES IN THEM - so

close up country bed.jpg

SHOULD BE

close-up-country-bed.jpg

When you look at the source code you will see stuff like:

close%20up%20country%20bed.jpg as the browser desperately tries to interpret the spaces in a filename.

  1. Get rid of the TM junk... they cause a LOT of conflicts and are just not worth the hassle. It is possible to create the "look" of ANY t.m template using existing and compatible free ones.

  2. learn how to name files, folders and images correctly.

  1. If I had all the time in the world I would build everything myself believe me, but ive not got round to cloning myself yet. Therefore I used a ready made template. I get the hint they are potentially life threatening but Im prepared to live with it.

  2. Yes very good, on the whole yes I use file references with '_' in unix and yes lowercase normally to save any 'confusion'. On this occasion I just grabbed a local windows file to test one from I had uploaded to see if it made any difference.

All of this is by the by, I was looking for a helpful answer, not a lecture thanks.

13 Apr 2013, 10:30 PM
#5
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: Sub category images missing

TheKenster:

  1. If I had all the time in the world ....

Well... you will start hoping that in a BIG way with TM templates.

You will spend hundreds of unnecessary hours in tears over the problems they cause. Properly designed (from a FUNCTIONS point-or-view) templates will give you all the time in the world to make easy and expected design alterations.

I have had FULLY FUNCTIONAL SITES up-and-running in under an hour. In fact, I did THIS ONE yesterday afternoon in just under two hours - that's from inintial zencart installation to being ready to take orders...