Gossamer Forum
Home : General : Internet Technologies :

Simple PHP problem I'm stuck on.

Quote Reply
Simple PHP problem I'm stuck on.
Hi Guys,

Long time no see! I've been out of the game for a while now. I'm writing a PHP script and I'm having a mental block on a simple PHP problem - Hoping someone could help me with Smile
I need to write a loop that goes up, then back down between 1 and a variable number. I.e. if $v = 5 I need the loop output to be
1,2,3,4,5,5,4,3,2,1,1,2,3,4,5,5,4,3,2,1
I know the solution is going to be simple but for some reason I can't figure it out :-(

Looks like the forums here have gone quiet since I was a regular Frown
Cheers,
Michael Bray
Subject Author Views Date
Thread Simple PHP problem I'm stuck on. Michael_Bray 7420 May 8, 2011, 9:04 PM
Thread Re: [Michael_Bray] Simple PHP problem I'm stuck on.
Michael_Bray 7165 May 8, 2011, 9:25 PM
Post Re: [Michael_Bray] Simple PHP problem I'm stuck on.
Michael_Bray 7137 May 8, 2011, 10:27 PM