Site Thumbnails made EASY!

Ready to have site thumbnails without all the other hassles?

This is a continued post made by 

How To get Sites to work with Thumbshots thumbnails.

Look for my earlier post for the directory and files to change.

In all of the template files look for the following line:

<a href="__site_url__"><img src="__spacer__"/></a>

Replace the above line with:

<a href="__site_url__"><img src="http://open.thumbshots.org/image.pxf?url=__url__/"></a>

Except for the view_image.html file look for the following line:

<div class="show_image">

Replace the above line with:

<a href="__site_url__"><img src="http://open.thumbshots.org/image.pxf?url=__site_url__/"></a>

Last thing that you need to do is to make sure that you have a link back to Thumbshots thumbnails

<a href="http://www.thumbshots.com/" target="_blank">Thumbshots thumbnails</a>

I will be adding this to his post.

The files to change will be in  /modules/boonex/sites/templates/base

  1. unit.html
  2. unit_admin.html
  3. view_image.html
  4. view_site.html
  5. block_hon.html
  6. block_percent.html
  7. block_prev_hon.html
  8. thumb110.html
  9. thumb200.html


I have added the files below with all the necessary changes.

The "modules.zip" contains the entire set in the correct directories, just upload to your root.

the others are the individual files 

To see in action > http://www.duvallocals.info/m/sites/home/

 

 

block_hon.html · 1.3K · 513 downloads
block_percent.html · 1K · 513 downloads
block_prev_hon.html · 710B · 540 downloads
thumb110.html · 182B · 626 downloads
thumb200.html · 182B · 479 downloads
unit.html · 1.1K · 548 downloads
unit_admin.html · 1.1K · 488 downloads
view_image.html · 633B · 516 downloads
view_site.html · 375B · 547 downloads
modules.zip · 4.6K · 445 downloads
ManOfTeal.COM a Proud UNA site, six years running strong!
24 Jun 2012

http://www.youtube.com/watch?v=KhIww4LjBYs

 

 

I will add with this, if the thumbnail changes in the future, the thumbnail on your site will automatically change! No images are stored on your server.

ManOfTeal.COM a Proud UNA site, six years running strong!
24 Jun 2012

Works good.  Here's an interesting page: http://snapcasa.com/#directory

 

I tried this with bitpixels.com ..... you can get a 200 x 150 thumbnail from them

Actual Example thumbnail:

My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
26 Jun 2012

Also, you can look in BxSitesModule.php for this big ugly piece of code:

 

    function _queryRemoteThumbnail($url, $args = null) {
        $args = is_array($args) ? $args : array();

        $defaults["Service"] = getParam('bx_sites_thumb_service');
        $defaults["Action"] = getParam('bx_sites_thumb_action');
        $defaults["STWAccessKeyId"] = getParam('bx_sites_thumb_access_key');
        $defaults["stwu"] = getParam('bx_sites_thumb_pswd');

        foreach ($defaults as $k=>$v)
        if (!isset($args[$k]))
        $args[$k] = $v;

        $args["stwUrl"] = $url;
        $request_url = urldecode(getParam('bx_sites_thumb_url') . '?' . $this->_httpParseQuery($args));
        $line = $this->_make_http_request($request_url);
        $regex = '/<[^:]*:Thumbnail\\s*(?:Exists=\"((?:true)|(?:false))\")?[^>]*>([^<]*)<\//';

        if (preg_match($regex, $line, $matches) == 1 && $matches[1] == "true")
        return $matches[2];

        return null;
    }

 

 

 

And change it to this:

 

    function _queryRemoteThumbnail() {
        return null;
    }

 

Then Dolphin won't waste all that time fetching a remote thumb from stw,

My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
26 Jun 2012

Cool Houston.

What about the add site page, the add photo part there. 

Shouldn't that be removed? I have been looking, everywhere to remove it.

It would confuse some, but maybe some would like the thumb they create.

ManOfTeal.COM a Proud UNA site, six years running strong!
26 Jun 2012

 RE:

Cool Houston.

What about the add site page, the add photo part there. 

Shouldn't that be removed? I have been looking, everywhere to remove it.

It would confuse some, but maybe some would like the thumb they create.

 I'll look into it, and remove it.   I'll post all the files to use bitpixels when I'm finished... it also takes a few css changes because of the larger thumb.  Then people will have two options to choose from.

 

Update:

In the sites module classes directory, edit BxSitesFormAdd.php

Find this chunk of code and delete it:

                'photo' => array(
                    'type' => 'file',
                    'name' => 'photo',
                    'caption' => _t('_bx_sites_form_photo'),
                ),

This just removes the photo input field from the form.  A lot of photo upload functions could also be removed, but it doesn't hurt anything to leave it.

My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
26 Jun 2012

Thanks for looking into removing that.

also, as for the image of the thumbnail, I just change the view_image.html file line to 

<a href="__site_url__"><img src="http://open.thumbshots.org/image.pxf?url=__site_url__/" width="200" height="156"></a>

That makes the thumbnail on the m/sites/view page larger than the original line we used.

I tried adding the bitpixel one but the __site_url__ returns an error. 

[edit] see the bigger nail here, just added above.. http://www.duvallocals.info/m/sites/view/NASA-s-Aeronautics-Research

ManOfTeal.COM a Proud UNA site, six years running strong!
26 Jun 2012

Z zip file for the Newton/rdonovan mod, using bitpixels.com.

 

Just unzip and upload the modules directory to your sites root, and overwrite the existing files.

Disclaimer: If any of this causes your entire site to blow up, or disappear into a black hole, blame Newton, or blame rdonovan.... blame anybody but me.

 

Update: zip file removed from this post.  Updated vesion below.

My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
26 Jun 2012

 

 RE:

Cool Houston.

What about the add site page, the add photo part there. 

Shouldn't that be removed? I have been looking, everywhere to remove it.

It would confuse some, but maybe some would like the thumb they create.

 I'll look into it, and remove it.   I'll post all the files to use bitpixels when I'm finished... it also takes a few css changes because of the larger thumb.  Then people will have two options to choose from.

 

Update:

In the sites module classes directory, edit BxSitesFormAdd.php

Find this chunk of code and delete it:

                'photo' => array(
                    'type' => 'file',
                    'name' => 'photo',
                    'caption' => _t('_bx_sites_form_photo'),
                ),

This just removes the photo input field from the form.  A lot of photo upload functions could also be removed, but it doesn't hurt anything to leave it.

 For now I'm leaving that in and may incorporate both into the view_image.html so the members can see there photo if uploaded.

ManOfTeal.COM a Proud UNA site, six years running strong!
26 Jun 2012

Oops.... the css directory is in the wrong place in my zip file. Corrected file is attached.

modules.zip · 9.5K · 393 downloads
My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
26 Jun 2012

I see how its done in css now.. lol

I do not know much about that yet.

So I will use the css files you created. Thanks!

ManOfTeal.COM a Proud UNA site, six years running strong!
26 Jun 2012

They both work fine Great job guys

...........................................
1 Jul 2012

An update on this,

I purchased an new website two days ago and built it up yesterday.

Posted the link to my demo site (not the 7.1 site)  and as expected the thumbnail that showed was, "Thumbnail coming soon"

so I thought for sure it would be quiet sometime before the new site thumb was captured.

I took only 12 hours, the thumbnail shot now is on the demo site; this is a great addition to anyone with the "Sites" module playing a big part on their site.

ManOfTeal.COM a Proud UNA site, six years running strong!
24 Jul 2012

Oh my gosh, how did I miss this?  I just came here searching for information on sites and found this.  I was asking before why someone didn't do an integration with thumbshots because it is a much better service.   I have used it on a directory I built at http://caltrade.com/directory and it has worked flawlessly for years.  Can't wait to try this.  Thanks Newton!

19 Aug 2012

Could someone tell me how and where to get the sites files for 7.0.9.   I used a mod that DolphinJay did that essentially disabled the shrinktheweb stuff, and on another site I used one he did that made the directory text only.  I appreciated him doing this - it got me going on some directories I needed to have, but if this works I won't need them.  

19 Aug 2012

 

Oh my gosh, how did I miss this?  I just came here searching for information on sites and found this.  I was asking before why someone didn't do an integration with thumbshots because it is a much better service.   I have used it on a directory I built at http://caltrade.com/directory and it has worked flawlessly for years.  Can't wait to try this.  Thanks Newton!

 The actual module is attached above, or each file is there individually.

As far as 7.1 goes, the ShrinkforWeb is incorporated into the sites module.

AND I HATE IT!

What do you mean here?

Could someone tell me how and where to get the sites files for 7.0.9. 

ManOfTeal.COM a Proud UNA site, six years running strong!
19 Aug 2012

Hi Newton,

What I mean is that I am going to have to do an uninstall and reinstall of sites, because I am using a version that was modified by DolphinJay - at my request, and the request of others here, to have a version that just strips out the shrink the we stuff entirely for a "no thumbnails" version.  

Are you saying you mod includes all the sties files?   I am really appreciative of your doing this - this is something I needed and wanted. 

 

19 Aug 2012

Thanks Rob, but it was and his original post that inspired me to do this.

It's a nice feature and the fact that it only takes one day for the thumb-shot to be updated, if there is not one, for the site.

As discussed, the thumb-shot is not the best quality, there is another company that provides better ones I just never bothered to change anything as I'm waiting on 7.1.

ManOfTeal.COM a Proud UNA site, six years running strong!
19 Aug 2012

Well thanks to rdonivan and houston as well, but you still didn't answer my question.  Does this have all the files for sites, or does it just replace some files.  As I tried to explain, I have a modified sites installation, so just replacing some files may not work.  

19 Aug 2012

I'm sorry, blond you know, it only has the changed files I listed above the actual attached module zip.

Do you need all the files in the sites module with the modification?

ManOfTeal.COM a Proud UNA site, six years running strong!
19 Aug 2012

For those that want the entire "sites" module folder with the modifications done, it's attached.

Unzip and upload to 

yoursite.com/modules/boonex

over right the matching files..

Disclaimer: If any of this causes your entire site to blow up, or disappear into a black hole, blame HL, or blame rdonovan.... blame anybody but me.

sites.zip · 65.2K · 398 downloads
ManOfTeal.COM a Proud UNA site, six years running strong!
19 Aug 2012

Awesome!  Thanks Newton. 

So here is what I am going to do to clean out the existing mod - please let me know if this is not correct.  

1.  Uninstall sites module from control panel.

2.  Delete all files in modules directory.

3.  Upload the files from your zip.

4.  Reinstall the sites module.

That's it, right?  Do you know if I will lose existing listings if I do this?  It is almost worth it to me, but it would be nice to keep them.  Thanks again to you and others who worked on this.   This looks like it will make that module actually userful.

Rob

 

 

 

 

 

19 Aug 2012

I have not checked as of this post, the sites module may have dependency's on another, mainly the forum.. check first!

ManOfTeal.COM a Proud UNA site, six years running strong!
19 Aug 2012

 

Awesome!  Thanks Newton. 

So here is what I am going to do to clean out the existing mod - please let me know if this is not correct.  

1.  Uninstall sites module from control panel.

2.  Delete all files in modules directory.

3.  Upload the files from your zip.

4.  Reinstall the sites module.

That's it, right?  Do you know if I will lose existing listings if I do this?  It is almost worth it to me, but it would be nice to keep them.  Thanks again to you and others who worked on this.   This looks like it will make that module actually userful.

Rob

 The above way would be a fresh install and you will loose all sites.

If you just replace the edited files, the thumb shots will appear. You state your module has been modified.

You could still see if the files are there and similar and or could be merged.

[edit] If you just make the changes manually, you will not loose anything. That is the method I would try first.

ManOfTeal.COM a Proud UNA site, six years running strong!
19 Aug 2012

Hi Newton - I just used those files to copy over my existing modified install, and it immediately worked - again, thank you.   Just two things I have noticed that I don't care for all that much.

1.  The Thumbshots like on every listing.  They don't require this - they just ask for one link at the bottom somewhere.  Would there be a way to do this?  I do think having those links on every listing detracts a bit.

2.  The quality of the graphics.  I think you already mentioned that it is not great.   Would there be a way to replace that big thumbshot with a smaller one?   Please see this link to the directory I mentioned where I used Thumbshots http://caltrade.com/directory/agriculture/wineries/

As you can see, they are much smaller, but I think they look pretty good.  Is there a way to modify what you have done to use these smaller thumbshots?

Rob

 

 

19 Aug 2012

 

Hi Newton - I just used those files to copy over my existing modified install, and it immediately worked - again, thank you.   Just two things I have noticed that I don't care for all that much.

1.  The Thumbshots like on every listing.  They don't require this - they just ask for one link at the bottom somewhere.  Would there be a way to do this?  I do think having those links on every listing detracts a bit.

2.  The quality of the graphics.  I think you already mentioned that it is not great.   Would there be a way to replace that big thumbshot with a smaller one?   Please see this link to the directory I mentioned where I used Thumbshots http://caltrade.com/directory/agriculture/wineries/

As you can see, they are much smaller, but I think they look pretty good.  Is there a way to modify what you have done to use these smaller thumbshots?

Rob

 

 

 I'm sure making them smaller would be no problem, I would have to know what size you wanted.

As for the link, linking back to Thunmbshots, that can be removed and added to a separate HTML Block or in the language key for page, not sure on the rules on that.

those attached files I changed are very easy to edit in something like Dreamweaver, turn off your system caches and edit, save, refresh your site and you can see the changes right away.

ManOfTeal.COM a Proud UNA site, six years running strong!
19 Aug 2012

I would like the same size in the link I posted above.  I thought Thumbshots had a fixed number of sizes?

What file is that link in?  I would like to remove it and try your approach.  

-----

Update:  Here is the site I put them on - a project I have put on hold so I could experiment: 

http://american-startups.com/m/sites/home/

Compare that to the directory link I posted above, which also uses Thumbshots

http://caltrade.com/directory/agriculture/wineries/

 

They are pretty close, but as you can see, both the size of the graphic, and the overuse of the thumbshots like detracts a bit, but this is a wonderful start. 

19 Aug 2012

your first link, private, and invite only..

to change all or any page with the images on it just change this

[EDIT]

<a href="__site_url__"><img src="http://open.thumbshots.org/image.pxf?url=__url__/" width="200" height="156"></a>

to this

<a href="__site_url__"><img src="http://open.thumbshots.org/image.pxf?url=__url__/" width="120" height="90"></a>

ManOfTeal.COM a Proud UNA site, six years running strong!
19 Aug 2012

Hey Newton, you've been great, so I hate to be so dense about this, but could you tell me the exact file to change.  This post references another post but there is a ridiculous pissing contest with ShrinktheWeb there and it is hard to figure out what is what.  This change does look easy, I just don't know which file. 

Side note - as I have always said, Boonex is different then any open source company I have ever seen as they don't seem to even consider incorporating these awesome mods from the community.  Did you see HL's blog entry on this?   Boonex was actually bragging about how great Shrinktheweb is, and he pointed out what an actual mess it is in reality. 

19 Aug 2012

Yes it can get ugly here sometimes.. hehe

the only files I changed were these

  1. unit.html
  2. unit_admin.html
  3. view_image.html
  4. view_site.html
  5. block_hon.html
  6. block_percent.html
  7. block_prev_hon.html
  8. thumb110.html
  9. thumb200.html
those are all in the /modules/boonex/sites/templates/base/


ManOfTeal.COM a Proud UNA site, six years running strong!
20 Aug 2012

Thanks Newton, but weird,  I changed the dimensions in all those files but I am still getting the bigger image.  Are you sure Thumbshots isn't just sending you some predefined size, and the size in those files has no effect?   I have removed the security on the site where I am testing it so you can see. 

http://american-startups.com/m/sites/home/

Also, would you mind telling me which file has that reference link - I want to try one of the other approaches you mentioned instead.

This is already better than what I had before, but I would like to see if there is a way to do the smaller thumbnails if possible. 

Rob

 

 

20 Aug 2012

Ok, some updated information here.  I couldn't figure out what was going on with that size being stuck, and it occurred to me to look at the settings for Sites on my system.  I found that I had configured Sites there with an access key, but I don't recall this every having worked.  Could the code we added somehow have made sites work, or more likely they finally fixed it after I got disgusted and used the mod for a text only site without thumbnails.   Now the big images are there, but I don't think they are from Thumbshots.   When you click one, you get the "Thumbshots image coming soon" though.    No matter, I think I would rather make Thumbshots work anyway.  Since this is a test setup,. I think I will try an uninstall, and reinstall of sites.

Update: uninstalled and reinstalled sites on the link above, and reentered one record - didn't work - the image is still big.  I am stumped. 

Update2: A clue.  The image on the "rater" page is the right size, but that is the only place:

http://american-startups.com/m/sites/hon

 

I am going to bed soon - if someone could help me with this mystery, I do like this mod and want to get going on it. 

20 Aug 2012

@Rob, looking into to the request, I'll update shortly.

ManOfTeal.COM a Proud UNA site, six years running strong!
20 Aug 2012

[edit] remove the previous suggestions I made "width="120" height="90"

those image sizes are done via css

 

modules/boonex/sites/templates/base/css/main.css

 

.bx_sites_unit_thumb110 {
    width: 200px;
    height: 152px;
}

.bx_sites_unit_thumb200 {
    width: 208px;
    height: 208px;
}
   
.bx_sites_unit_thumb110 img {
    width: 200px;
    height: 150px;
    border: none;
}

.bx_sites_unit_thumb200 img {
    width: 200px;
    height: 200px;
    border: none;

 

obviously you need to change them here.. I'm not a template guru by far, never claimed to be.. lol

 

The Thumbshots thumbnails link in in unit.html

 

lines 22-23

 

<div class="bx_sites_unit_content"><a href="http://www.thumbshots.com/" target="_blank">Thumbshots thumbnails</a>
        </div>

ManOfTeal.COM a Proud UNA site, six years running strong!
20 Aug 2012

Newton - Bingo.  This works, and I think it looks much  better than the bigger ones. 

I am still trying to come up with a creative place to put the attribution link though.  I tried to put it in a smaller font under the thumbnail, and it worked in some places, but not in others.  See: http://american-startups.com/m/sites/home/

Can you think of anything?  The best would be if there was a way to put it at the bottom of every listing of links, but I am open to suggestions. 

Rob

 

20 Aug 2012

Hey Newton, great work! I do have a question. How come the thumbs are so blurry?

http://towtalk.net ... Hosted by Zarconia.net!
21 Aug 2012

 

Hey Newton, great work! I do have a question. How come the thumbs are so blurry?

 Thanks,

That's what is offered by the thumbshots site.

You can do like Rob did and make them small in the css file,

HL has the option for better quality images from another service in this thread.

ManOfTeal.COM a Proud UNA site, six years running strong!
21 Aug 2012

Ok i uploaded the sites.zip to my site and then unarchived it to /modules/boonex and when i add sites i still get no thumbnail any idea what could be the problem? I'm using 7.09

12 Oct 2012

 

Ok i uploaded the sites.zip to my site and then unarchived it to /modules/boonex and when i add sites i still get no thumbnail any idea what could be the problem? I'm using 7.09

 Please clear your cache, in Admin panel.

Or manually clean the three cache folders via cPanel, File Manager.

all three have .htaccess files, they must remain.

  1. cache
  2. public_html
  3. tmp

ManOfTeal.COM a Proud UNA site, six years running strong!
12 Oct 2012

I love this mod but I think I must have done something wrong.   The thumbshots work on the listing page, which is great, but the bigger one on the detail page always says "thumbshots coming soon.   Please see this link and hit any one of the listings to see what I mean: http://world-startups.com/m/sites/home/

Any idea what I did wrong?

Rob

13 Oct 2012

 RE:

I love this mod but I think I must have done something wrong.   The thumbshots work on the listing page, which is great, but the bigger one on the detail page always says "thumbshots coming soon.   Please see this link and hit any one of the listings to see what I mean: http://world-startups.com/m/sites/home/

Any idea what I did wrong?

Rob

Your view_image.html is wrong

src="http://open.thumbshots.org/image.pxf?url=__url__/"

should be:


src="http://open.thumbshots.org/image.pxf?url=__site_url__"

My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
13 Oct 2012

Awesome - worked like a charm - thanks HT!

Source files wrong?  As I recall, all I did was copy them. 

13 Oct 2012

You might try the bitpixels version I uploaded to see what you think.  They got just a little better thumb.  Below is an example.

 

 

BTW... you should  put the image block in the left column... it'll look better.

My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
13 Oct 2012

Well gee.... that worked good, didn't it....

My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
14 Oct 2012

Brilliant! Simple fix, and it works like a charm!

@Newton  @HoustonLively  --- 3 cheers and a round of beer!

Even Monkeys and Retards get it right with repitition! - Author Unknown
17 Jan 2013

 

Brilliant! Simple fix, and it works like a charm!

@Newton  @HoustonLively  --- 3 cheers and a round of beer!

yw, and I need that beer!

ManOfTeal.COM a Proud UNA site, six years running strong!
17 Jan 2013

 Will either of these (bitpixels or thumbshots) work on v7.1.4?

... thanks.

You might try the bitpixels version I uploaded to see what you think.  They got just a little better thumb.  Below is an example.

 

 

BTW... you should  put the image block in the left column... it'll look better.

 

5 Nov 2014

Wow - this old post got bumped - i still need this and never found a good solution.   I would doubt very much that the "thumbshots" approach still works.   I used them on a non-Dolphin site and they changed their approach and made them much harder to use.

6 Nov 2014

I changed my sites module to use webthumbnail.org

Example of usage: http://api.webthumbnail.org/?width=1024&height=768&url=boonex.com

 

Actual Result:

I'll see what I can do to post the required modifications to the sites module.

My opinions expressed on this site, in no way represent those of Boonex or Boonex employees.
6 Nov 2014

HL - do you recall what version this was for?   This post is from 2012.   I have a 70.9 site - will it work with that?

6 Nov 2014
6 Nov 2014
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.