Go Back   PHP Link Directory Forum > PHP Link Directory (phpLD) > Mods and contribution Discussion

Mods and contribution Discussion This forum is only for discussion of modding phpLD. For specific mod releases, please see the appropriate forum.

Closed Thread
 
Thread Tools Display Modes
Old 11-06-2005   #1
relinkd
 
Join Date: Oct 2005
Posts: 15
Default Site Thumbnail Alexa Thumbshots Mod

This mod will allow your phpLD to display site thumbnails next to each link.

Instructions
--------------

1. If you use this mod it'd be great if you'd give me a link. Thanks!
Code:
<a href="http://www.thehonickteam.com/">Atlanta Real Estate</a>
2. Turn on Display PageRank in phpLD admin area


3. Open /templates/pagerank.tpl and find...
Code:
{if $pr gt -1}
4. Replace the above line with...
Code:
 
{if $pr gt -1}
Comply with Alexa's usage requirements: Change the [yoursite.com] above to your site! ie; ?id=yourdomainnamehere.com&amp;size=

5. Save pagerank.tpl file


6. Open /main.css and find...
Code:
div.pr
7. Change the height (92px seems to work about right)


8. Save main.css


9. Enjoy! You're done!


Others have contributed some great tweaks and variations of this mod in this thread and others where you can find out how to update/create the Alexa thumbnail, show thumbnails for featured links only, create a link for visitors to update thumbnails, show the thumbnail without the pagerank, and more so read on.

PS: If you like this mod and you're using Firefox, you can get the same effect for Google, Yahoo, MSN and other search engines with BetterSearch or Google and Yahoo searches with GooglePreview.

Last edited by David; 05-30-2009 at 12:23 AM.
relinkd is offline  
Old 11-06-2005   #2
David
Administrator
phpLD Administrator
Supporter
 
David's Avatar
 
Join Date: Jan 2005
Posts: 11,667
Default

Cool! 8)
You're from Atlanta too!
David is offline  
Old 11-06-2005   #3
vkaryl
 
Join Date: Aug 2005
Posts: 263
Default

Now THAT is flat cool!
__________________
{Signature Edited - Old non-working links removed}
vkaryl is offline  
Old 11-06-2005   #4
kickass
 
Join Date: Aug 2005
Location: Delaware Valley, PA
Posts: 222
Default

VERY nice! Yes, if I ever get done with paying work and get back to working on my own projects, seek locally will benefit by this one . . . just wish we could use it without that pr bar . . .
kickass is offline  
Old 11-06-2005   #5
Bill
Mentor
 
Bill's Avatar
 
Join Date: Aug 2005
Location: New Jersey
Posts: 334
Default

Quote:
Originally Posted by kickass
VERY nice! Yes, if I ever get done with paying work and get back to working on my own projects, seek locally will benefit by this one . . . just wish we could use it without that pr bar . . .
I bet there is a way to use it without the PR bar.
Bill is offline  
Old 11-06-2005   #6
relinkd
 
Join Date: Oct 2005
Posts: 15
Default

Quote:
Originally Posted by microdude431
Quote:
Originally Posted by kickass
VERY nice! Yes, if I ever get done with paying work and get back to working on my own projects, seek locally will benefit by this one . . . just wish we could use it without that pr bar . . .
I bet there is a way to use it without the PR bar.
Just replace steps 2-5 above with this for no PR bar...

Open up a new file paste this
Code:
<div class="pr">{$link.URL}"]
</div>
Save as pagerank.tpl replacing your old pagerank.tpl

no PR bar for you!

oh and I guess this also links the image with nofollow attrib and click track ID

Last edited by David; 08-21-2008 at 05:33 AM.
relinkd is offline  
Old 11-07-2005   #7
vkaryl
 
Join Date: Aug 2005
Posts: 263
Default

relinkd, you are a gentleman and a scholar! Thanks so much!
__________________
{Signature Edited - Old non-working links removed}
vkaryl is offline  
Old 11-07-2005   #8
kickass
 
Join Date: Aug 2005
Location: Delaware Valley, PA
Posts: 222
Default

Cool! Now if those pesky paying customers would just go away . . . :lol: NOT!
kickass is offline  
Old 11-15-2005   #9
webinv
 
Join Date: Nov 2005
Posts: 2
Default

You guys are awesome! Thanks for the great mods!

-Jon
webinv is offline  
Old 11-15-2005   #10
richm
Supporter
 
Join Date: Oct 2005
Posts: 50
Default

While going through your site, if you find items that do not have current Alexa thumbnails, you can update them by going by visiting:
htxp://thumbnails.alexa.com/update_thumbnail?url=nameofsite.com

I click on the link, and paste "http://thumbnails.alexa.com/update_thumbnail?url=" before the url and press enter. Alexa will update the thumbnail within 2 days.

Last edited by David; 08-21-2008 at 05:33 AM.
richm is offline  
Old 11-16-2005   #11
Nobody
Supporter
 
Join Date: Aug 2005
Location: Sweden
Posts: 218
Default

Maybe you should somehow add a link in the admin approve links section, so that all new sites get a thumbnail.
Nobody is offline  
Old 11-16-2005   #12
richm
Supporter
 
Join Date: Oct 2005
Posts: 50
Default

Since sites change over time, I would also love to see a little php program that goes through the database (starting at a given record number) and opens this window for every record a few seconds apart. Would it be difficult to program such a thing (as a standalone php program).

For now, I am counting on the users to update the thumbnails. Therefore, my pagerank.tpl file, which displays the thumbnails, includes an "Update Thumbnail" butto for the users:

Code:
<div class="pr">
<a href="{$link.URL}" id="{$link.ID}" rel="nofollow">
  
 
 
   htxp://thumbnails.alexa.com/update_thumbnail?url={$link.URL}"]Update Thumbnail
</a>
</div>
To make this work, I had to increase the height of my thumbnail area by changing the following in main.css:
Code:
div.pr {
    font-size: 6pt;
    color: #000000;
    float: left;
    height: 112px;
    margin-right: 5px;
}

Last edited by David; 08-21-2008 at 05:34 AM.
richm is offline  
Old 11-16-2005   #13
Peter_Rosado
Supporter
 
Join Date: Nov 2005
Posts: 10
Default

Hey...weird, I just did that this morning on my directory (the update thumbnail thingy) :?
I also added that to the approve e-mail.

Last edited by David; 08-21-2008 at 05:34 AM.
Peter_Rosado is offline  
Old 11-16-2005   #14
richm
Supporter
 
Join Date: Oct 2005
Posts: 50
Default

Tell me how you added this to the email notification function. I looked at adding it to the email "function" at the bottom of dir_approve_links.php, or adding it as a button in dir_approve_links.tpl. Neither of these seemed ideal (besides, I didn't know how to add it to the function, echo?).

0r... are you saying that you added this to the text of the email message that you send, telling the submitter to click on the link (not a bad idea).
richm is offline  
Old 11-17-2005   #15
Hizson
 
Join Date: Sep 2005
Posts: 33
Default

I love this mod. But I am having a slight problem with it.

In FireFox it looks great as you can see at

{no longer using thumbnails and link removed}

But if you go to the same page in IE the site discription drops down and beneath the alexa thumbnail.

Does anyone know what I can do to fix this? Could this be because I am using vkaryl's great mod?

Thanks,

Jere
__________________
{non working links removed from sig}

Last edited by David; 03-07-2008 at 10:20 PM.
Hizson is offline  
Old 11-17-2005   #16
HighPageRank
 
Join Date: Nov 2005
Posts: 10
Default

link.tpl

Code:
{strip}
<table><tr>
{* show page rank *}
 
        <td valign="top">
        
 
        </td>
 
 
<td>
<a id="{$link.ID}" href="{$link.URL}" title="{$link.TITLE}"
{* nofollow *}
{if $link.NOFOLLOW or ($link.RECPR_VALID eq 0 and
        ($smarty.const.RECPR_NOFOLLOW eq 2 or
        ($smarty.const.RECPR_NOFOLLOW eq 1 and $link.RECPR_REQUIRED eq 1)))
    } rel="nofollow"
{/if}{if $smarty.const.ENABLE_BLANK} target="_BLANK"{/if}>
{$link.TITLE}</a>
 
{$link.DESCRIPTION}
 
<span class="url">{$link.URL}</span>
{if $smarty.const.SHOW_PAGERANK}  <span style="clear: both">{include file="pagerank.tpl" pr=$link.PAGERANK}
</span>
{/if}
</p>
</td>
</tr></table>
{/strip}
Replace ALEXA-ID
Example : {link removed - no longer using thumbnails}

Last edited by David; 08-21-2008 at 05:35 AM.
HighPageRank is offline  
Old 11-17-2005   #17
richm
Supporter
 
Join Date: Oct 2005
Posts: 50
Default

Hizson: It looks as if you are IE is clearing your alignment after the title. Could you post your link.tpl file and the styles you are using in your stylesheet?
richm is offline  
Old 11-19-2005   #18
vkaryl
 
Join Date: Aug 2005
Posts: 263
Default

Hey Jere.... yep, it's no doubt because this mod wasn't available when I set up the description class for this template.

I'll work it over this weekend, and post back when I've got a usable solution.

Thanks for the heads up!
__________________
{Signature Edited - Old non-working links removed}
vkaryl is offline  
Old 11-21-2005   #19
Hizson
 
Join Date: Sep 2005
Posts: 33
Default

Great Varkyl...I really appreciate the help.

Jere
__________________
{non working links removed from sig}
Hizson is offline  
Old 11-21-2005   #20
vkaryl
 
Join Date: Aug 2005
Posts: 263
Default Fixes....

Hi Jere (and anyone else who might need this) -

See attachment: this includes pagerank.tpl and main.css - fixes both IE and FF for use with the Alexa thumbs mod.

This is good with the thumbs but is a tad bit wonky without, so I'm providing it as just these two files instead of including it in the main template distro.

Let me know if you run into any problems (but start a new topic in the Design forum, please!); I tested at 800x600, 1024x768, 1280x1024, and 1600x1200 on both FF 1.5 RC3 and IE 6.

BTW, I took out the border=0 in the img call, inline css is a real no no, you should have a css selector in your stylesheet to cover no borders on images and images used as links/anchors (and since I'm including my main.css, you WILL have same if using my template). For those not using my template, but not sure what to put in the stylesheet, see following (implements no borders on images and images used as links/anchors):

img, img a {
border:0;
}

Other than that, relinkd, this is an OUTSTANDING mod, and thank you very very much for providing it to this community for free.
__________________
{Signature Edited - Old non-working links removed}
vkaryl is offline  
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 01:09 PM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.