Supersizer and Cataloger - How do I get them to work together?

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
mfal55
Forum Members
Forum Members
Posts: 131
Joined: Fri Jan 09, 2009 10:00 pm

Supersizer and Cataloger - How do I get them to work together?

Post by mfal55 »

Has anyone had success using the Supersizer and Cataloger?  I've been trying to work this out, but don't seem to be having any luck.  Here's my code:

Code: Select all

<ul class="img_list">
{section name=numloop loop=$items}
<li class="image_one"><a href="{$items[numloop].link}">
{assign var=photo value=$items[numloop].image}
{supersizer path="$photo" URL=true}</a>
<div class="title">{$items[numloop].title}<br />{$title}</div></li>
{/section}
</ul>
It gives me a path error and code reads:

Code: Select all

<h2>There is a path issue!</h2><h3>Does this look right?</h3><strong>Path:</strong>/Applications/MAMP/htdocs/website/modules/Cataloger/Cataloger.Image.php?i=photo1_s_1_300_1.jpg&ac=27795<br/>http://localhost:8888/website/uploads/SuperSizerTmp/Cataloger.Image.php?i=photo1_s_1_300_1.-w-h-p25-F-S1.jpg&ac=27795

Can anyone help?  I'm not sure what I'm doing wrong.
JeremyBASS

Re: Supersizer and Cataloger - How do I get them to work together?

Post by JeremyBASS »

It's

{assign var=photo value=$items[numloop].image_src}

Always use the src image is Cataloger

Cheers Jeremy
mfal55
Forum Members
Forum Members
Posts: 131
Joined: Fri Jan 09, 2009 10:00 pm

Re: Supersizer and Cataloger - How do I get them to work together?

Post by mfal55 »

Ah! Thanks so much Jeremy!  In case anyone else needs to know, the full code for calling a set of Category Items using the Supersizer Plugin is below:

The original code prior to adding Supersizer was this (for comparison):

Code: Select all

<ul>
{section name=numloop loop=$items}
<li>
<a href="{$items[numloop].link}">
<img src="{$items[numloop].image}" title="{$items[numloop].title}" alt="{$items[numloop].title}"/>
</a>
</li>
{/section}
</ul>

The new code with the Supersizer Plugin is this:

Code: Select all

<ul>
{section name=numloop loop=$items}
<li>
<a href="{$items[numloop].link}">
{assign var=photo value=$items[numloop].image_src}
<img src="{supersizer path="$photo" URL=true width='300' quality='100'}" />
</a>
</li>
{/section}
</ul>

Thanks Jeremy!
JeremyBASS

Re: Supersizer and Cataloger - How do I get them to work together?

Post by JeremyBASS »

Super.. happy to help.. it's good karma for the soul...

a side not you could also do this...
{supersizer path=$photo width='300' quality='100' alt=$items[numloop].title title=$items[numloop].title}

you always want the alt's

Cheers
Jeremy
mfal55
Forum Members
Forum Members
Posts: 131
Joined: Fri Jan 09, 2009 10:00 pm

Re: Supersizer and Cataloger - How do I get them to work together?

Post by mfal55 »

Indeed! Thanks so much Jeremy!  The plugin rocks - thanks for the great work.
User avatar
airelibre
Dev Team Member
Dev Team Member
Posts: 99
Joined: Tue Dec 01, 2009 3:42 pm
Location: Alsace // France

Re: Supersizer and Cataloger - How do I get them to work together?

Post by airelibre »

Hi,

I was searching a solution for caching cataloger resized files, and I found your plugin.
Thank you, it works great !

www.airelibre.fr
Mathieu // AireLibre
JeremyBASS

Re: Supersizer and Cataloger - How do I get them to work together?

Post by JeremyBASS »

Well Great, I'm glad you like it.. I have a new version in the announcement post... it has the new param overwrite and is much smaller too... Happy to see people getting use out of it.. Cheers -Jeremy
moonoo
Forum Members
Forum Members
Posts: 77
Joined: Fri Jan 08, 2010 12:23 am
Location: Wales - UK

Re: Supersizer and Cataloger - How do I get them to work together?

Post by moonoo »

So upon reading the above, am I right in thinking the supersizer by passes the Cataloger re-size script or do we need to mod the cataloger module code to switch it off?
vicpug
Forum Members
Forum Members
Posts: 22
Joined: Mon Jul 12, 2010 1:58 pm

Re: Supersizer and Cataloger - How do I get them to work together?

Post by vicpug »

Hi, have spent days trying to figure out how to get Supersizer to resize Cataloger images.

This code does not work.

Code: Select all

<ul>
{section name=numloop loop=$items}
<li>
<a href="{$items[numloop].link}">
{assign var=photo value=$items[numloop].image}
<img src="{supersizer path="$photo" url=true width='100' quality='100' strip_tags=true}" />
</a>
</li>
{/section}
</ul>
Error is :

Code: Select all

There is a path issue with the orginal image!
Does this look right?
Path:/home/photonet/public_html/devtest/modules/Cataloger/Cataloger.Image.php?i=sean-o-carroll-3_ct_1_120_0.jpg&ac=37969
http://www.photonet.com.au/devtest/uploads/SuperSizerTmp/Cataloger.Image.php?i=sean-o-carroll-3_ct_1_120_0.-w100-h0-p0-q100-F-----S1-c.jpg&ac=37969?" /> 
The path looks fine, but maybe Supersizer does not like the ?i= in the path string. Strange. Also the $items[numloop].image_src as suggested in a previous post does not actually exist. Thanks for any help.
darconny
Forum Members
Forum Members
Posts: 104
Joined: Thu Nov 22, 2007 12:43 pm

Re: Supersizer and Cataloger - How do I get them to work tog

Post by darconny »

Hi,

I have a similar problem with Cataloger and Supersizer on Category page. Also I get almost identical message as in vicpug las post.

Have you found solution to the problem yet? As I can see the problem is with the path that is passed on Supersizer call.

I use latest versions of cmsms, cataloger and supersizer.

thanks
Darko
JeremyBASS

Re: Supersizer and Cataloger - How do I get them to work tog

Post by JeremyBASS »

Hello, So I know I have solved this some time ago and I was just passing thru and saw this. I only have a sec but if you’re sure that can't find the post I solved it for someone by googling or using the site search, this is what I'd look at, the headers (that it's not coming out at text/html).. the next thing would be to see if you can get to to the image in the browser via just the img url. If IIRC it was that you fake the path... not 100%


@moonoo it doesn't stop the module from trying to size it, but what you do is just go after the source file which is still there IIRC



I'll be back in a few day.. Hope that helps some. Cheers -Jeremy
darconny
Forum Members
Forum Members
Posts: 104
Joined: Thu Nov 22, 2007 12:43 pm

Re: Supersizer and Cataloger - How do I get them to work tog

Post by darconny »

Hello,

Jerremy, thank you very much for stopping by :)

Well all I could found is this thread http://forum.cmsmadesimple.org/viewtopi ... =7&t=41352
not sure if this is one you mentioned.

But unfortunately I haven't solved the problem yet. It seems that the path is wrong - the first image in array is missing, but the second is ok.. very strange.

My problem is related to Category page of Cataloger, I try to create thumbnails for each item with SuperSizer.

So the category page template is like this:

Code: Select all

{section name=numloop loop=$items}
        <div class="category_item">
             <div class="image">    
                <a href="{$items[numloop].link}">
                {assign var=photo value=$items[numloop].image_src}
                {supersizer path="$photo" URL=true width='100' height='100' quality='100'}
                </a>
                </div>
         </div>
{/section}
At the moment I have 2 items in array, and the problem is that the first thumbnail is missing (path wrong?) and the second one is ok.

Also, if I put {$photo} in a div that is associated to this loop (items description ie {$items[numloop].description}), I get correct paths on my page printed out, for both items on category page.
1. http://localhost/skyboard193/uploads/im ... _src_1.jpg
2. http://localhost/skyboard193/uploads/im ... _src_1.jpg

Both images are in that folder, but the first thumbnail is missing.

Any thoughts on this wierd issue? :-\

Thanks a lot
Darko
darconny
Forum Members
Forum Members
Posts: 104
Joined: Thu Nov 22, 2007 12:43 pm

Re: Supersizer and Cataloger - How do I get them to work tog

Post by darconny »

After some time kicking my head through a wall, I finally got it work!! :D

This is how I set Category template, so the thumbnails derived from items are 'supersized' correctly (square thumbnails).

Code: Select all

{section name=numloop loop=$items}
        <div class="category_item">
             <div class="image">
                 <a href="{$items[numloop].link}">
                   {capture assign="headerimgpath"}{root_url}/uploads/images/catalog_src/{$items[numloop].alias}_src_1.jpg{/capture}

{supersizer path=$headerimgpath width=110 height=110 protect=false crop=true strip_tags=true alt=$items[numloop].title title=$items[numloop].title}
                 </a>
             </div>  
             <div class="cat_title">
                <h2><a href="{$items[numloop].link}">{$items[numloop].category_title}</a></h2>
             </div>
             <div class="cat_text">
		{$items[numloop].description}
	     </div>
        </div>
   {/section}
Hope this'll help someone..

cheers :)
Post Reply

Return to “Modules/Add-Ons”