Re: dates

From: Date: Fri, 04 Oct 2002 13:40:07 +0000
Subject: Re: dates
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-16162@lists.php.net to get a copy of this message
Tim, This simple script works $row = "abcd\efg"; $r1 = stripslashes($row); print "NO STRIP >$row< <br>"; print "STRIP >$r1< <br>"; And gives the output NO STRIP >abcd\efg< STRIP >abcdefg< What do you mean by "doesn't work"? Have you checked if you are stripping an empty string, for instance ? Luis ----- Original Message ----- From: "Tim Blackwell" <timblackwell@hotmail.com> To: <php-windows@lists.php.net> Sent: Friday, October 04, 2002 2:11 PM Subject: [PHP-WIN] dates > any reason why my echo statement doesn't work in this script? > > > > <? > mysql_select_db("tutorial"); > $query = "SELECT DATE_FORMAT(tutdate, '%b-%e %l%p') as date FROM > tutorial_table"; > $result = mysql_query($query); > $num_results = mysql_num_rows($result); > > for ($i=0; $i <$num_results; $i++) > { > $row = mysql_fetch_array($result); > $vardate = stripslashes($row["tutdate"]); > echo "$vardate"; > } > ?> > > > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.windows (#16162) next »