Jump to content


Tutorial Request


1 reply to this topic

#1 iPoptart

    Young Padawan

  • Members
  • Pip
  • 2 posts

Posted 18 June 2005 - 01:31 PM

I'd like to see a tutorial, or atleast a code example on how, like in PHP, you have a string, say, 'lol'. I want for say, 10 times, to add   to the begining this string. So the outcome would look like this:

lol
 lol
  lol
   lol
    lol

etc. Does anyone know how to do it?

Edited by iPoptart, 18 June 2005 - 01:32 PM.


#2 Time-2-Design

    Young Padawan

  • Members
  • Pip
  • 16 posts

Posted 19 June 2005 - 03:52 PM

Do you mean something like this?

<?
$i=0;
while ($i<10) {
echo $space."lol";
$space .= "&nbsp;";
$i++;
}
?>






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users