MakePdf WeBid 1.2.* ONLY

MakePdf is a mod to create, store and display a PDF data sheet of any given auction.

  1. BabyDunk
    WeBid Version:
    • 1.2.*
    To install this mod copy the makepdf folder to the /includes/packages/ dir

    then copy all these functions to the bottom functions_global.php
    PHP:
    // Get items url
    function get_item_url($id){
        global 
    $system$SETTINGS;

        return 
    $system->SETTINGS['siteurl'] . 'item.php?id=' $id;
    }

    // Get base url
    function base_url(){
        global 
    $system$SETTINGS;

        return 
    $system->SETTINGS['siteurl'];
    }


    // PRINT PDF 
      
    function makepdf($id) {
      return 
    '<a href="'.base_url().'includes/packages/makePdf/download.php?pdfitem='.$id.'" class="makepdf_link" >Open PDF DataSheet</a>';
      }


    // SHORT URLS
        
    function makepdf_shorturl($url)  {
            
    $ch curl_init();
            
    $timeout 5;
            
    curl_setopt($ch,CURLOPT_URL,'http://tinyurl.com/api-create.php?url='.$url);
            
    curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);
            
    curl_setopt($ch,CURLOPT_CONNECTTIMEOUT,$timeout);
            
    $data curl_exec($ch);
            
    curl_close($ch);
            return 
    $data;
        }

    then open item.php and find this
    PHP:
            'BNIMG' => get_lang_img('buy_it_now.gif'),
    and replace with this
    PHP:
            'BNIMG' => get_lang_img('buy_it_now.gif'),
            
    'MAKEPDF' => makepdf(),

    then all's left to do is call
    HTML:
    {MAKEPDF}
    
    in your item.tpl, wherever you desire to place it.

    Images

    1. makepdf.JPG

Recent Updates

  1. Bug Fixed**
  2. Some typos fixed