Jump to content
rfalkner

Broken images on subcatagories

Recommended Posts

Hello,

 

Im currently editing a site for a friend, but i am having troubles atm.

 

I can't edit the subcatagory images in the site. At the moment it's just showing as "broken images". I have tryed to inspect the elements with chrome, and it cant find the pictures he once uploadet. Ive tryed to log on FTP to manually insert the pictures, but i cant find the folder they are supposed to be in.

 

What i am talking about can be found here: http://strobisten.dk/5-adaptere

 

Hope you can help me sort this issure.

 

Best regards

Share this post


Link to post
Share on other sites

open the category.tpl of your theme

and check it the subcategory image codes are like this

 

 

 

{if $subcategory.id_image}

<img src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'medium')}" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" />

{else}

<img src="{$img_cat_dir}default-medium.jpg" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" />

{/if}

Share this post


Link to post
Share on other sites

The code looks like this:

 

 

if $subcategory.id_image}

<img src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'subcategory')}" alt="" width="{$subcategory.width}" height="{$subcategory.height}" />

{else}

<img src="{$img_cat_dir}default-medium.jpg" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" />

{/if}

 

Seems pretty similar.

 

My questrion is, where do i replace the "broken images" with some new ones?

 

Best regards

Share this post


Link to post
Share on other sites

problem is in the first line, your code callind a image format called subcategory that seems dont have in your sintallation, change 'subcategory' to 'medium'

Share this post


Link to post
Share on other sites

So i have tried with following:

 

 

{if $medium.id_image}

<img src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'subcategory')}" alt="" width="{$subcategory.width}" height="{$subcategory.height}" />

{else}

<img src="{$img_cat_dir}default-medium.jpg" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" />

{/if}

 

and

 

 

{if $medium.id_image}

<img src="{$link->getCatImageLink($medium.link_rewrite, $medium.id_image, 'subcategory')}" alt="" width="{$medium.width}" height="{$medium.height}" />

{else}

<img src="{$img_cat_dir}default-medium.jpg" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" />

{/if}

 

nothing seems to change.

 

Am i doing this wrong or could there be something else wrong?

Share this post


Link to post
Share on other sites

nop, this is the code

 

{if $subcategory.id_image}

<img src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'medium')}" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" />

{else}

<img src="{$img_cat_dir}default-medium.jpg" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" />

{/if}

Share this post


Link to post
Share on other sites

I have implemented that.

 

So now i just have to put the images i want into the img folder?

Share this post


Link to post
Share on other sites

nop, go to the category and insert the images in the category, not manually. or send me a pm woth your site admin access and i solve

Share this post


Link to post
Share on other sites

replace the category.tpl of your theme for the category,tpl of the default prestashop theme

Share this post


Link to post
Share on other sites

Not working. I can edit the catagoty file in my template and even delete it, without any changes on the site!

 

Can somebody solve this for me?

Share this post


Link to post
Share on other sites

Hi,

 

I have exactly the same problem as rfalkner.

 

Does someone solved it ?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More