Looking to recreate this download widget thing..kinda stuck on it.

Discussion in 'WordPress' started by webcabbie, Aug 13, 2011.

  1. #1
    So check out this site.

    http://reverejournal.com
    Code (markup):
    On the left hand sidebar 3/4 of the way down there is a picture of the newspaper that says download print edition. You click it and a download window opens to pull down the entire print edition of their newspaper.

    I need to recreate something like this and can't figure out how.. I know it is some kind of javascript.. I looked at the source code and this is what I see. Any help you can offer would be appreciated.

    </div>
    </form>
    
    <script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=cse-search-box&amp;lang=en"></script></div>
    		</div><div class="side-widget"><h2>Full Print Edition</h2>			<div class="textwidget"><br>
    
    <a href="http://www.reverejournal.com/wp-content/uploads/RevereJournal.pdf">
    <img src="http://www.reverejournal.com/wp-content/uploads/full_print.jpg">
    </a>
    
    <br><br></div>
    		</div>
    Code (markup):
     
    webcabbie, Aug 13, 2011 IP
  2. primitip

    primitip Active Member

    Messages:
    37
    Likes Received:
    3
    Best Answers:
    1
    Trophy Points:
    60
    #2
    No, it's just a plain HTML, I believe it's WordPress site so you can use Text Widget and simply put this code:

    <a href="your-pdf-file-url"><img src="your-image-url" /></a>

    If you want the PDF open in new window, you can add this to the <a> tag: <a target="_blank">

    That Javascript thing is not related to the download, that's for the google custom search above
     
    primitip, Aug 13, 2011 IP
  3. webcabbie

    webcabbie Active Member

    Messages:
    355
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    58
    #3
    O.k. THANK YOU!

    However I am hitting 1 snag.. The file upload size. The media library limits it at 8mb. I tried adjusting my php config settings in WHM (I have a vps) and that did not work. I tried uploading a php.ini file and that didnt work either.

    I finally uploaded the file via ftp and set up the html code as you suggested and it is working. One thing.. this guy won't want to learn FTP and I want want to do it for him every week for free.

    I'll have to learn how to increase the file upload size somehow..
     
    webcabbie, Aug 13, 2011 IP