Announcement: New plug-in SuperSizer

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Locked
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

ok... just runing it stright... lets see if this works...  ;D I bet if nothing else does this will ...  Thank you all for testing... -Jeremy
Attachments

[The extension txt has been deactivated and can no longer be displayed.]

darconny
Forum Members
Forum Members
Posts: 104
Joined: Thu Nov 22, 2007 12:43 pm

Re: Announcement: New plug-in SuperSizer

Post by darconny »

hmm,first my Apache crashed and after restart I got nothing, like there was no SuperSizer at all.
Then, I reverted to a working version and again nothing. So, I cleared everything and called supersizer manually at the test page. I succeed to get working the old version, but the newest one produces errors again:

getimagesize(http://localhost/cms-1.6.6/uploads/cgblog/id35/img 105.jpg) [function.getimagesize]: failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in C:\xampp\htdocs\cms-1.6.6\plugins\function.supersizer.php on line 49

Warning: Division by zero in C:\xampp\htdocs\cms-1.6.6\plugins\function.supersizer.php on line 260

maybe something is wrong on my localhost setup, I'll try it soon at a live environment as I plan to make this site live in a week or so.

Darko
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

wow yeah... not sure why... it's working every where I test it... thanks for getting back... -J
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

;D fredp  caught me on a dumb oversight... when clearing the cache of images... so I fixed that... also I added a exit if the path is bad... Now this should work... should should...  :D

Here is the test....

http://www.digitalbarn.tv/testpage.html

as you can see there is a space test at the bottom... so it's from

{assign var=Files value="uploads/Copy of feusers/*.jpg"|glob} verse the one above... {assign var=Files value="uploads/feusers/*.jpg"|glob}

so the very last one is

http://www.digitalbarn.tv/uploads/SuperSizerTmp/fishGal/Copy of Camp'09 011.-w200-h0-p0-F-S1.jpg


so it's working there... Gosh I hope this works... Thank you all for testing .. I think this is it ...

Cheers
Jeremy
Attachments

[The extension txt has been deactivated and can no longer be displayed.]

Last edited by JeremyBASS on Thu Dec 03, 2009 9:40 pm, edited 1 time in total.
darconny
Forum Members
Forum Members
Posts: 104
Joined: Thu Nov 22, 2007 12:43 pm

Re: Announcement: New plug-in SuperSizer

Post by darconny »

Thanks.. but on my localhost the same errors come up  ???

But, never mind.. I don't want to feel like party breaker here  :D

I'll come back soon with tests on a real web server.

Darko
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

darconny if you could try this one... it was the first try it this and I may have just had a typo in it as I started off trying to fix the issue with rawurldecode, and fredp  can confirm it works when he adds it so... if you could try it then it'd be back to 100% working...  ;D that'd be nice lol...



Cheers
Jeremy
Attachments

[The extension txt has been deactivated and can no longer be displayed.]

darconny
Forum Members
Forum Members
Posts: 104
Joined: Thu Nov 22, 2007 12:43 pm

Re: Announcement: New plug-in SuperSizer

Post by darconny »

hi Jeremy :)

Well, now my details page works but summary breaks:

getimagesize(http://localhost/cms-1.6.6/uploads/cgblog/id35/img 105.jpg) [function.getimagesize]: failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in C:\xampp\htdocs\cms-1.6.6\plugins\function.supersizer.php on line 48
There is a path issue

Obviously this is something with my CGBlog customization, but not sure why is this happening as I have the same calls:

Summary:(breaks)
{assign var=Photo value=$field->value}
{assign var=Location value=$entry->file_location}
{assign var=Item value=$entry->id}
{supersizer path="$Location/$Photo" height='80' URL=true Assign="MinnyPic" Quality=100 Subdir="$Item"}
       detail_url}" alt="{$entry->title}">

Details:(works)
{assign var=Photo value=$field->value}
{assign var=Location value=$entry->file_location}
{assign var=Item value=$entry->id}
{supersizer path="$Location/$Photo" height="450" URL=true Assign="MainPic" Protect =false Subdir="$Item"}
{supersizer path="$Location/$Photo" height="80" URL=true Assign="MinnyPic" Quality="100" Subdir="$Item"}




cheers
Darko
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

yeah I'd bet there is something else off... it't can't work half the time on the same file there.... hmmm... try this in both loactions and let me kow what you get...

{assign var=Photo value=$field->value}
{assign var=Location value=$entry->file_location}
{assign var=pathIS value="$Location/$Photo" }
{$pathIS}


It should be working everywhere now... I've run thru every encoding function php has to offer... lets start there... -J
darconny
Forum Members
Forum Members
Posts: 104
Joined: Thu Nov 22, 2007 12:43 pm

Re: Announcement: New plug-in SuperSizer

Post by darconny »

sorry for delayed answer..

I put your code, and get these:

Summary:
http://localhost/cms-1.6.6/uploads/cgbl ... G_5536.JPG
http://localhost/cms-1.6.6/uploads/cgblog/id35/img 105.jpg
http://localhost/cms-1.6.6/uploads/cgbl ... G_5127.JPG
http://localhost/cms-1.6.6/uploads/cgblog/id31/img 043.jpg
and so on...

Details
http://localhost/cms-1.6.6/uploads/cgbl ... G_5536.JPG
http://localhost/cms-1.6.6/uploads/cgblog/id35/img 105.jpg
etc..

paths look the same... don't know.

maybe it's due to my summary template customization, where I show only first image thumbnail.. posting this whole part so you could maybe encounter a problem:

{if isset($entry->fields)}
  {foreach from=$entry->fields item='field'}
   
        {if $field->type == 'file'}
          {if $field->name == 'image1'}   
            {assign var=Photo value=$field->value}
            {assign var=Location value=$entry->file_location}
            {assign var=Item value=$entry->id}
            {supersizer path="$Location/$Photo" height='80' URL=true Assign="MinnyPic"  Protect =false Quality=100 Subdir="$Item"}
            detail_url}" alt="{$entry->title}">
          {/if}
      {else}
          {$field->name}: {eval var=$field->value}
      {/if}
   
  {/foreach}
{/if}

thanks
Darko

ps. previous version still working great
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

Thought I'd share this... if you need to address height and width you can do this...

Code: Select all

{assign var=widthIS value=$image->file|getimagesize}
{if $widthIS[1]>$widthIS[0]}
{supersizer path=$image->file alt="" height='700' Quality='100' cacheBuster=true  Subdir="gallery" Assign="Major" URL=ture}
{else}
{supersizer path=$image->file alt="" width='700' Quality='100' cacheBuster=true  Subdir="gallery" Assign="Major" URL=ture}
{/if}

you can see this in action here... http://creativeaquariums.com.s44997.gri ... ge=gallery

Remember the key to this mod is using smarty to accent and add to the logic path of processing... so in this case I added a "if portrait or landscape" mode



@darconny --- I'm stumped why it doesn't seem to work for you... in the last release it used $this->strOriginalImagePath = str_replace(" ", "%20", $strPath);  but that had the issue of if there was ' in the file names...
$this->strOriginalImagePath = rawurldecode($strPath);  should do the same thing along with every other this we tried here...

So it now works everywhere else but yours so far as report IIRC... once you get on a live server we'd know if it was a bad GD install.  At this point I'm going to read , but I'm going to move to the crop function and the multiple filter actions... Hopefully we can get the reason soon on why yours is not working ...

Cheers
Jeremy
Last edited by JeremyBASS on Sat Dec 05, 2009 8:24 pm, edited 1 time in total.
kendo451

Openbasedir

Post by kendo451 »

Hi Jeremy,

I see from your example paths that you are using a Plesk setup on Linux, which is the same as my server.

I'm curious how you got around openbasedir restrictions?  I'm trying to put the CMSMS uploads directory in the subdomain

ul.mydomain.com

So, I created the subdomain and also made the appropriate changes to config.php.

But the openbasedir restrictions are preventing my CMS made simple from writing to the subdomains.

Hmmm.

I could change the openbasedir setup on this server, if I knew which file to change.

OR

I could use .htaccess to rewrite ul.mydomain.com to point to http://www.mydomain.com/uploads

I think I will fiddle with that.
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

Thou it's not really related directly to this plug-in... but since one of the param is meant to work with subdomain, let's get that worked out... so if your aiming to turn openbasedir you could do it in a php.ini... or in the case of the visitnorthcentralidaho.org

To resolve this, I created the file vhost.conf in /var/www/vhosts/visitnorthcentralidaho.org/conf/ containing the following:


  php_admin_value open_basedir none


After doing this, I ran '/usr/local/psa/admin/bin/websrvmng -va' to make Plesk rebuild its httpd.include file (adding an Include line for the vhost.conf file), and then restarted Apache with '/etc/init.d/httpd restart'.  After doing so, the site was able to load properly.


now that may-be way more than most people need to do or can do... so you can do a sub-domain setup in the same dir level... you can read more here... http://forum.cmsmadesimple.org/index.ph ... 953.0.html ... it's all about sub-domains with cmsms..

That is most likely the solution that will be the easiest to adopt.

Really you should talk to your host first for the best options that they would recommend for your particular setup.

Hope this helps,
Cheers
Jeremy
Last edited by JeremyBASS on Sun Dec 06, 2009 3:07 am, edited 1 time in total.
kendo451

Re: Announcement: New plug-in SuperSizer

Post by kendo451 »

You're right.  This would be better as a new thread.

http://forum.cmsmadesimple.org/index.php/topic,39686.0.html
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

So kendo451 show me I was not clear on what I said as I thought I was  ;D oh well it happens in muddy waters lol.... so with this (you may need to adjust for you our setup)

Code: Select all


# subdomain hanlding for both
RewriteCond %{HTTP_HOST} !^www\.example.tdl
RewriteCond %{REQUEST_URI} ^/$
RewriteCond %{HTTP_HOST} ([^.]+)\.example.tdl
RewriteRule ^(.*)$ %1

you get this...

http://blog.corbensproducts.com/uploads ... r_bird.png
http://www.corbensproducts.com/uploads/ ... r_bird.png

Now blog is an aliased subdomain at the dns level which is step one.  I'll get an example up soon on this in use with SuperSizer...


Cheers
Jeremy
JeremyBASS

Re: Announcement: New plug-in SuperSizer

Post by JeremyBASS »

Okaydoky,  so here it is....

http://www.corbensproducts.com/users/1/ ... Subdomains

look to the image and you'll see it's coming from

http://blog.corbensproducts.com/uploads ... 0-F-S1.jpg

were your looking from on the www subdomain... if you wondering why do this... well take a look in yslow and you'll see that no cookies were severed with it... that can add up in big way so... :D it's a good thing... here is the tag I used...

{supersizer path="uploads/feusers/$onepropvalue" width="101" Subdir=$oneuser.id cacheBuster=true Quality=100 rootUrl="http://blog.corbensproducts.com/uploads"}


Cheers
Jeremy
Locked

Return to “Modules/Add-Ons”