ok I have 2 arrays!
$dates[];
$providers[];

with numbers obviously in the [].
the array values are strings.

how do i make it so i get this

$test[] = $dates[0]."\n"$providers[0]; //nice loop which increments the keys please note the new line!!!
this code doesnt work!

the output needs to be an array with a new line cause i need it in a jpgraph function

$graph->xaxis->SetTickLabels($superxaxis);

    never mind after over 1 hour of trying myself i managed

    $test = $dates[0]."\n".$providers[0];
    //echo $test;
    $superxaxis = array($test);

      for($i=0; $i < count($dates)-1; $i++){
        $graph->xaxis->SetTickLabels( array (  $dates[$i] . "\n" . $providers[$i] ) );
      }
      

      A bit more compact. By the way I'm guessing that you need to call the same function for each value of the arrays, and also that each array has the same number of elements 🙂

        lol u and ur compactness.

        i see that line and have to switch on my brain to see what is going on.

        yeah it works but now I have a problems with jpgraph not dispaling it correctly cause the with between the tick marks is not long enough

          Heh I know nothing about Jpgraph sorry 🙂

            Write a Reply...