PhpDig.net

PhpDig.net (http://www.phpdig.net/forum/index.php)
-   How-to Forum (http://www.phpdig.net/forum/forumdisplay.php?f=33)
-   -   Adding thumbnail pictures to your results? (http://www.phpdig.net/forum/showthread.php?t=2782)

Dave A 06-30-2007 07:41 PM

Adding thumbnail pictures to your results?
 
If you would like to try and add thumbnail pictures to your results when using phpdig, then please feel free to try out the following method.
It is free to use and appears to give quite good results, there must be heaps of other ways to generate thumbnail pictures for your results, but I have tried to show everyone how this can be done cheaply and easily (especially for our Australian users who are rumored to be careful with spending a few bucks! Grin..)
Even a novice should be able to do this within a few minutes.
If anyone has other ways or ideas then I would be pleased to hear about them!

Visit the website of HTTP://www.websnapr.com/ and then go to the pages that mention "Preview Bubble"which is located over at http://www.websnapr.com/previewbubble/
Then simply download the file they supply that's called " previewbubble.zip "
and then copy (FTP) the contents of the previewbubble.zip file somewhere within your server.
I use the root directory which is easier for me.

Edit previewbubble.js and point the bubbleImagePath variable to the correct location of the bg.png file.

For example:
var bubbleImagePath = '/images/bg.png';
Then add the statement "Include previewbubble.js" in your templates header.
For an example:
<script type="text/javascript" src="previewbubble.js"></script>

Add class="previewlink" attribute to the links you wish to bind the preview event to. For example: <a class="previewlink" href="http://www.phpdig.net">Phpdig</a>

Then simply edit the template file you are using for your results, edit or add the following commands to it;

<script type="text/javascript" src="previewbubble.js"></script>

Add this somewhere near the top of the page:

They simply edit the following statement ( <a href="<phpdig:complete_path/>" title="go to <phpdig:complete_path/>") that is within the file a few lines below to read like this:

<a class="previewlink" href="<phpdig:complete_path/>" title="go to <phpdig:complete_path/>" class="v"><phpdig:complete_path/></a> - last update : <phpdig:update_date/></td>
</tr>
Then when the mouse is placed over the path that is shown within your results, it should then display the thumbnail picture of the web page for you.
When it's first used the web page may not have been indexed but within a few minutes it is usually added to the server and it will then be displayed when the mouse is placed over the statement within your results.
The displayed box will either show you the thumbnail picture of the page given within the path of the results, or it will show a message saying "Image Queued" and after a little while the server will add the pages which have been queued.
From then on the picture of the web page will then be displayed to your users whenever the mouse is placed over the results.
This does appear to be a very easy way to make your results better and more interesting for your users to see and use!

Have fun with it if you want too??


All times are GMT -8. The time now is 02:49 AM.

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright © 2001 - 2005, ThinkDing LLC. All Rights Reserved.