Help Adding URLs to Tab Script

Discussion in 'PHP' started by jawinn, Dec 1, 2006.

  1. #1
    I've been working with this canned script and I cann't figure out where the add the destination URLs. Can anyone tell me how to add them?

    
    
    <?
    
    // add the class
    require_once("paypaltabs.class.php");
    
    // the item var will determine which tab is raised
    
    if($HTTP_GET_VARS[item] == "") $item = 'Yahoo';
    else $item = $HTTP_GET_VARS[item];
    
    /*
    // Create an array of tab items with urls, then declare the tabs 
    // class and add the array with an image url for the tab images.
    // Keep in mind the items are case sensitive.
    */
    
    $tabs_items  = array(	'Google'=>$PHP_SELF.'?item=Google',
    				'Yahoo'=>$PHP_SELF.'?item=Yahoo',
    				'Dmoz'=>$PHP_SELF.'?item=Dmoz',
    				'Dogpile'=>$PHP_SELF.'?item=Dogpile'
    
    );
    
    // specify the location of the images to be used
    
    $tab_images_url = "/images";
    
    $tabs = new PayPalTabs($tabs_items,$tab_images_url);
    
    $tabs->ShowTabs($item);
    
    
    ?>
    
    
    Code (markup):
    thx,
     
    jawinn, Dec 1, 2006 IP
  2. crazyden

    crazyden Guest

    Messages:
    15
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I think this one is the array of links:

    
    $tabs_items  = array(	'Google'=>$PHP_SELF.'?item=Google',
    				'Yahoo'=>$PHP_SELF.'?item=Yahoo',
    				'Dmoz'=>$PHP_SELF.'?item=Dmoz',
    				'Dogpile'=>$PHP_SELF.'?item=Dogpile'
    
    );
    
    PHP:
    you just do:
    
    $tabs_items  = array(	'Google'=>'google.com',
    				'Yahoo'=>'...',
    				'Dmoz'=>'...',
    				'Dogpile'=>'...'
    
    );
    
    PHP:
     
    crazyden, Dec 1, 2006 IP