SitePoint Sponsor

User Tag List

Results 1 to 4 of 4

Threaded View

  1. #1
    SitePoint Mentor silver trophy
    Rubble's Avatar
    Join Date
    Dec 2005
    Cambridge, England
    82 Post(s)
    3 Thread(s)

    Working with different arrays created on Windows or Linux

    I am have a problem formating some data from an array. I am getting two different outputs and think the difference is due to Windows or Linux.
    The full code I am using is displayed at the bottom of this page:

    Selected parts of the output from the arrays are:

    Currently I am using a function I found on the net and deleting out what I do not need:
    PHP Code:
    // Function to remove items from array
    function array_delete$array$filterfor ){ 
    $thisarray = array (); 
    $array as $value 
    stristr$value$filterfor ) === false && strlen$value ) > 
    $thisarray[] = $value

    // Remove blank lines    
    $NoBlanks array_filter$IMarray ); 

    // Remove items containing Name from the arrary
    $NoName array_delete$NoBlanks"Name" ); 

    // Remove items containing Path: from the array
    $NoPath array_delete$NoName"Path:" ); 

    I need to remove the blank lines, lines with --------, lines with Name, lines with Path etc. In fact all I need is the font name

    There must be a better way to do this please could somebody give me a hand.
    Last edited by Rubble; Apr 5, 2009 at 02:07. Reason: Modified the text


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts