php-general Digest 24 Mar 2005 12:52:14 -0000 Issue 3356
Topics (messages 211429 through 211454):
Preorder Modified Tree Traversal
211429 by: Matt Babineau
211434 by: Burhan Khalid
Re: Apache user can't use exec(), passthru(), etc.
211430 by: Jim Poserina
211432 by: Jim Poserina
NetFlix Drag and Drop Row Ordering
211431 by: Graham Anderson
211436 by: Burhan Khalid
Re: mail() Alternative?
211433 by: Manuel Lemos
Memory use
211435 by: Joe Wollard
211438 by: M. Sokolewicz
Re: executed script URL
211437 by: Michal Kozusznik
SQL statement - please help
211439 by: Jacques
211450 by: Jason Barnett
211454 by: Jay Blanchard
file upload
211440 by: William Stokes
211441 by: Tristan.Pretty.risk.sungard.com
211444 by: William Stokes
211446 by: William Stokes
Destroying the Session Object
211442 by: Jacques
211451 by: Jason Barnett
Listing directory, return none if only one file
211443 by: Alexandru Martin
211452 by: Forest Liu
211453 by: Jason Barnett
convert date format
211445 by: Angelo Zanetti
Re: convert date format-SOLVED
211447 by: Angelo Zanetti
211448 by: Chris Ramsay
211449 by: Angelo Zanetti
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[email protected]
----------------------------------------------------------------------
--- Begin Message ---
Hi all,
I'm trying to use "pmtt" to display a windows explorer style view of
products in a database. If anyone is familiar with "pmtt" could you send me
an email, I'm looking for some help. I built some code to pull the "Levels"
out of the database, I need some help tracking which level the user is
clicking on so that I can create a drill-down scenario. I know this can most
likely be achieved more easily using the adjacent tree method, but I need
something a bit more robust than that. Let me know if you have created any
systems that are drill-down style menus or whatnot, I'm interested in the
methods you used to achieve your success.
Thanks All!
PS- Thanks to those who suggested the Linux command line HTML 2 PDF
package!!
Matt Babineau
Criticalcode
w: http://www.criticalcode.com
p: 858.733.0160
e: [EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
Matt Babineau wrote:
Hi all,
I'm trying to use "pmtt" to display a windows explorer style view of
products in a database. If anyone is familiar with "pmtt" could you send me
an email, I'm looking for some help. I built some code to pull the "Levels"
out of the database, I need some help tracking which level the user is
clicking on so that I can create a drill-down scenario. I know this can most
likely be achieved more easily using the adjacent tree method, but I need
something a bit more robust than that. Let me know if you have created any
systems that are drill-down style menus or whatnot, I'm interested in the
methods you used to achieve your success.
How are you tracking them now? What's not working?
Sitepoint has a great article that has PHP snippets on both pmtt and the
"flat" drill-down method.
http://www.sitepoint.com/article/hierarchical-data-database
--- End Message ---
--- Begin Message ---
The output is:
OS Error: 127.
I have a second server that I use as a downtime backup. On that one, all
the scripts work normally. I don't have to give a path for the commands, any
commands with permission problems return "permission denied," and the apache
user (nobody) actually has /sbin/nologin as the shell.
"Richard Lynch" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> On Mon, March 21, 2005 8:20 pm, Jim Poserina said:
> > If I run this PHP script:
> > <?php
> > echo '<pre>';
> > echo exec('whoami');
>
> The first most biggest thing wrong is that you aren't using the additional
> arguments to exec() to find out what your output is, and if your command
> generated an error.
>
> For starters, I'm betting that at least one of the following is true:
> whoami is not in the $PATH/$path of the PHP user.
> whoami is not executable by the PHP user.
>
> You'll never find out which unless you use the extra args to exec
>
> http://php.net/exec
>
> > echo '</pre>';
> > ?>
> >
> > from the web, the output is
> >
> > <pre></pre>and from the command line running as the apache
user(webuser),
> > the output is.
> > Content-type: text/html
> > X-Powered-By: PHP/4.3.9
> >
> > <pre></pre>
>
> EXCELLENT attempt to diagnose this, though!
>
> > But if I run from the command line as root, the output is:
> >
> > Content-type: text/html
> > X-Powered-By: PHP/4.3.9
> >
> > <pre>root</pre>and from the command line as a user in the root group,
the
> > output is:
> > Content-type: text/html
> > X-Powered-By: PHP/4.3.9
> >
> > <pre>jimpoz</pre>Safe mode is turned off. As webuser (or any
> > non-root-group
> > user), no shell commands work. Not echo, not ls, not whoami, not touch.
> > And
> > no shell functions work: no exec(), no passthru(), no shell_exec(), no
> > backticks. Every command I'm trying to run is world-readable and
> > world-executable.
>
> But are they in the $path of webuser?
>
> Use the full path to them if they aren't
>
> exec("/bin/whoami", $output, $error);
> if ($error) echo ("OS Error: $error.<br />\n");
> echo implode("<br />", $output);
>
> > If I turn safe mode on, it gives me a "safe mode is on" warning only
about
> > lines that call shell_exec(), and not for exec() or any of the others.
> > Other
> > than that, it doesn't hang or give any kind of error or anything when it
> > comes to a shell function call; apparently it just ignores them.
>
> No, it tries to run them, and fails, and provides the error messages and
> error number in the variables you aren't using :-)
>
> Some days, I think the PHP Dev Group should just make those arguments to
> exec() required.
>
> --
> Like Music?
> http://l-i-e.com/artists.htm
--- End Message ---
--- Begin Message ---
Wed 23 Mar 2005--23:05:30--/home/webuser>whoami
root
Wed 23 Mar 2005--23:05:33--/home/webuser>cat test.php
<?php echo exec("whoami")."\n"; ?>
Wed 23 Mar 2005--23:05:36--/home/webuser>php test.php
Content-type: text/html
X-Powered-By: PHP/4.3.9
root
Wed 23 Mar 2005--23:05:39--/home/webuser>su webuser
[EMAIL PROTECTED] ~]$ php test.php
Content-type: text/html
X-Powered-By: PHP/4.3.9
[EMAIL PROTECTED] ~]$ whoami
webuser
[EMAIL PROTECTED] ~]$ exit
"Jim Poserina" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> The output is:
>
> OS Error: 127.
>
> I have a second server that I use as a downtime backup. On that one, all
> the scripts work normally. I don't have to give a path for the commands,
any
> commands with permission problems return "permission denied," and the
apache
> user (nobody) actually has /sbin/nologin as the shell.
>
>
> "Richard Lynch" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > On Mon, March 21, 2005 8:20 pm, Jim Poserina said:
> > > If I run this PHP script:
> > > <?php
> > > echo '<pre>';
> > > echo exec('whoami');
> >
> > The first most biggest thing wrong is that you aren't using the
additional
> > arguments to exec() to find out what your output is, and if your command
> > generated an error.
> >
> > For starters, I'm betting that at least one of the following is true:
> > whoami is not in the $PATH/$path of the PHP user.
> > whoami is not executable by the PHP user.
> >
> > You'll never find out which unless you use the extra args to exec
> >
> > http://php.net/exec
> >
> > > echo '</pre>';
> > > ?>
> > >
> > > from the web, the output is
> > >
> > > <pre></pre>and from the command line running as the apache
> user(webuser),
> > > the output is.
> > > Content-type: text/html
> > > X-Powered-By: PHP/4.3.9
> > >
> > > <pre></pre>
> >
> > EXCELLENT attempt to diagnose this, though!
> >
> > > But if I run from the command line as root, the output is:
> > >
> > > Content-type: text/html
> > > X-Powered-By: PHP/4.3.9
> > >
> > > <pre>root</pre>and from the command line as a user in the root group,
> the
> > > output is:
> > > Content-type: text/html
> > > X-Powered-By: PHP/4.3.9
> > >
> > > <pre>jimpoz</pre>Safe mode is turned off. As webuser (or any
> > > non-root-group
> > > user), no shell commands work. Not echo, not ls, not whoami, not
touch.
> > > And
> > > no shell functions work: no exec(), no passthru(), no shell_exec(), no
> > > backticks. Every command I'm trying to run is world-readable and
> > > world-executable.
> >
> > But are they in the $path of webuser?
> >
> > Use the full path to them if they aren't
> >
> > exec("/bin/whoami", $output, $error);
> > if ($error) echo ("OS Error: $error.<br />\n");
> > echo implode("<br />", $output);
> >
> > > If I turn safe mode on, it gives me a "safe mode is on" warning only
> about
> > > lines that call shell_exec(), and not for exec() or any of the others.
> > > Other
> > > than that, it doesn't hang or give any kind of error or anything when
it
> > > comes to a shell function call; apparently it just ignores them.
> >
> > No, it tries to run them, and fails, and provides the error messages and
> > error number in the variables you aren't using :-)
> >
> > Some days, I think the PHP Dev Group should just make those arguments to
> > exec() required.
> >
> > --
> > Like Music?
> > http://l-i-e.com/artists.htm
--- End Message ---
--- Begin Message ---
For those who have netflix, does anyone know how you would recreate
their 'drag and drop' queue widget?
basically, you can drag and drop movies in the order you choose
is this a combination of javascript and php ?
how would you go about creating something like this to order rows in
your own CMS ?
extremely cool
g
--- End Message ---
--- Begin Message ---
Graham Anderson wrote:
For those who have netflix, does anyone know how you would recreate
their 'drag and drop' queue widget?
basically, you can drag and drop movies in the order you choose
is this a combination of javascript and php ?
how would you go about creating something like this to order rows in
your own CMS ?
I don't have an account with Netflix, but Flex has a great drag and drop
widget.
--- End Message ---
--- Begin Message ---
Hello,
on 03/23/2005 04:14 PM Dan Joseph said the following:
I've had a production system moved to a new server. Our geniuses here
have refused to allow sendmail on the server and all my e-mail
functions are now gone. Is there a way around this? I have already
checked the manual, I don't see anything....
You may want to try this MIME message class. It comes with wrapper
functions that act as direct replacements of the mail() function and let
you send the messages by alternative means which can be calling the
sendmail program directly or relaying the message to a SMTP server of
choice.
http://www.phpclasses.org/mimemessage
--
Regards,
Manuel Lemos
PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/
PHP Reviews - Reviews of PHP books and other products
http://www.phpclasses.org/reviews/
Metastorage - Data object relational mapping layer generator
http://www.meta-language.net/metastorage.html
--- End Message ---
--- Begin Message ---
Greetings,
I'm trying to help a C programmer understand and use PHP for web
development. So far all the similarities between C++ and PHP are making
the process rather speedy. He asked what seemed like a very simple
question, but I couldn't find the answer. The questions is how can you
determine how much memory a variable/object/struct/etc are using?
For instance:
$myObject = new myClass();
$myObject->performAction_and_holdResult();
At this point, how can you tell how much memory $myObject is using?
Thanks!
--- End Message ---
--- Begin Message ---
Joe Wollard wrote:
Greetings,
I'm trying to help a C programmer understand and use PHP for web
development. So far all the similarities between C++ and PHP are making
the process rather speedy. He asked what seemed like a very simple
question, but I couldn't find the answer. The questions is how can you
determine how much memory a variable/object/struct/etc are using?
For instance:
$myObject = new myClass();
$myObject->performAction_and_holdResult();
At this point, how can you tell how much memory $myObject is using?
Thanks!
you can't. PHP (the ZE actually) handles all memory related tasks behind
the screens, this means you shouldn't have to worry about it. But just
"don't worry" doesn't mean it can not be seen.
AFAIK there are functions which give you the total memory used by the
script, but I don't think there are any showing the memory used by a
structure/variable. (since there's no need for them)
--- End Message ---
--- Begin Message ---
Hello
> Rasmus answered this question a week or two ago. Search the archives
> for 'getenv request' and you will likely find the answer.
I found something (in last 3000 posts) but it says about
getenv('REMOTE_ADDR'). My problem is how to get an URL of executed
script in always working way, compatible will all servers/configs
The problem is in URLs like this
http://domain.name.com/ ... some path ... /script.php
Where I cannot get 'some path' part (in compatible way).
best regards
--
*** Media-IT Michał Kożusznik ***
*** IT networks - databases - multimedia ***
*** [EMAIL PROTECTED] ***
*** http://www.media-it.net ***
--- End Message ---
--- Begin Message ---
Dear all
Please, I realy need your help. I am trying to extract only those records
that were entered during the past hour from my MySQL database. The
following SQL statement extracts all the records. As soon as I change the
INTERVAL to 1 HOUR I see all the records in my database. When I change
CURDATE() to CURTIME() no records are extracted from the database. The
cgtimeposted field is a time data type.
Please advise me as to how I can formulate my SQL statement so that only
those records entered within the past hour displays on my page.
Here is my current SQL statement - this statement displays all the records:
$sql = "Select tblchatglobal.cgid, tblchatglobal.cgdateposted,
tblchatglobal.cgtimeposted, tblchatglobal.uid, tblchatglobal.cgmsg,
tblusers.uid, tblusers.uusername from tblchatglobal, tblusers where
(tblchatglobal.uid = tblusers.uid) and (DATE_SUB(CURDATE(),INTERVAL 1 HOUR)
<= tblchatglobal.cgtimeposted) order by tblchatglobal.cgtimeposted desc";
Jacques
--- End Message ---
--- Begin Message ---
Try a MySQL list. Or possibly even php-db.
--
Teach a man to fish...
NEW? | http://www.catb.org/~esr/faqs/smart-questions.html
STFA | http://marc.theaimsgroup.com/?l=php-general&w=2
STFM | http://php.net/manual/en/index.php
STFW | http://www.google.com/search?q=php
LAZY |
http://mycroft.mozdev.org/download.html?name=PHP&submitform=Find+search+plugins
signature.asc
Description: OpenPGP digital signature
--- End Message ---
--- Begin Message ---
[snip]
$sql = "Select tblchatglobal.cgid, tblchatglobal.cgdateposted,
tblchatglobal.cgtimeposted, tblchatglobal.uid, tblchatglobal.cgmsg,
tblusers.uid, tblusers.uusername from tblchatglobal, tblusers where
(tblchatglobal.uid = tblusers.uid) and (DATE_SUB(CURDATE(),INTERVAL 1
HOUR)
<= tblchatglobal.cgtimeposted) order by tblchatglobal.cgtimeposted
desc";
[/snip]
One of the MySQL lists will be really helpful to you.
http://dev.mysql.com/doc/mysql/en/date-and-time-functions.html
AND (DATE_SUB(CURDATE(),INTERVAL 1 HOUR)<= tblchatglobal.cgtimeposted)
CURDATE is wrong here, as it only returns a date. NOW() returns a
datetime. Try....
AND (DATE_SUB(NOW(),INTERVAL 1 HOUR)<= tblchatglobal.cgtimeposted)
--- End Message ---
--- Begin Message ---
Hello,
I'm (slowly) learning how to make a file upload stuff with php. Now I would
like to know how to define the servers upload directory in the code?
For example I have the upload script in folder /www in the www.domain.com
server and I want upload the files to /www/uploads folder. So how do write
the path in the php script?
Thanks
-Will
--- End Message ---
--- Begin Message ---
http://www.hotscripts.com/Detailed/24113.html
take a look at this.. perhaps you can reverse engineer it
"William Stokes" <[EMAIL PROTECTED]>
24/03/2005 09:18
To
[email protected]
cc
Subject
[PHP] file upload
Hello,
I'm (slowly) learning how to make a file upload stuff with php. Now I
would
like to know how to define the servers upload directory in the code?
For example I have the upload script in folder /www in the www.domain.com
server and I want upload the files to /www/uploads folder. So how do write
the path in the php script?
Thanks
-Will
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
Okl I can't reverse engineer that...
I just need to know how to set the path.
now I have it like this and it wont work. $fileame comes from a form.
if (copy($filename, "/imagedir/" . $filename_name))
print "<H2>upload succesful!</H2>";
"Tristan Pretty" <[EMAIL PROTECTED]> kirjoitti
viestiss�:[EMAIL PROTECTED]
> http://www.hotscripts.com/Detailed/24113.html
> take a look at this.. perhaps you can reverse engineer it
>
>
>
>
>
> "William Stokes" <[EMAIL PROTECTED]>
> 24/03/2005 09:18
>
> To
> [email protected]
> cc
>
> Subject
> [PHP] file upload
>
>
>
>
>
>
> Hello,
>
> I'm (slowly) learning how to make a file upload stuff with php. Now I
> would
> like to know how to define the servers upload directory in the code?
>
> For example I have the upload script in folder /www in the www.domain.com
> server and I want upload the files to /www/uploads folder. So how do write
>
> the path in the php script?
>
> Thanks
> -Will
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
>
--- End Message ---
--- Begin Message ---
Never mind. I got that sorted out! Thanks anyway...
-Will
"William Stokes" <[EMAIL PROTECTED]> kirjoitti
viestiss�:[EMAIL PROTECTED]
> Okl I can't reverse engineer that...
>
> I just need to know how to set the path.
> now I have it like this and it wont work. $fileame comes from a form.
>
> if (copy($filename, "/imagedir/" . $filename_name))
> print "<H2>upload succesful!</H2>";
>
>
> "Tristan Pretty" <[EMAIL PROTECTED]> kirjoitti
> viestiss�:[EMAIL PROTECTED]
>> http://www.hotscripts.com/Detailed/24113.html
>> take a look at this.. perhaps you can reverse engineer it
>>
>>
>>
>>
>>
>> "William Stokes" <[EMAIL PROTECTED]>
>> 24/03/2005 09:18
>>
>> To
>> [email protected]
>> cc
>>
>> Subject
>> [PHP] file upload
>>
>>
>>
>>
>>
>>
>> Hello,
>>
>> I'm (slowly) learning how to make a file upload stuff with php. Now I
>> would
>> like to know how to define the servers upload directory in the code?
>>
>> For example I have the upload script in folder /www in the www.domain.com
>> server and I want upload the files to /www/uploads folder. So how do
>> write
>>
>> the path in the php script?
>>
>> Thanks
>> -Will
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
>>
--- End Message ---
--- Begin Message ---
How can I destroy the session object for a particular user when that user
leaves my web site without properly signing out?
Jacques
--- End Message ---
--- Begin Message ---
Jacques wrote:
> How can I destroy the session object for a particular user when that user
> leaves my web site without properly signing out?
>
> Jacques
The most important part of this is "garbage collection." You can't
really know for 100% sure that a user has left without properly signing
out, but there are several things you can do to mitigate the problem:
- Only set session cookies (i.e. browser should destroy the cookie when
the browser is closed)
- Modify the following php.ini directives in a way that fits you:
- http://php.net/manual/en/ref.session.php#ini.session.gc-probability
- (also look at the next several gc_* entries)
--
Teach a man to fish...
NEW? | http://www.catb.org/~esr/faqs/smart-questions.html
STFA | http://marc.theaimsgroup.com/?l=php-general&w=2
STFM | http://php.net/manual/en/index.php
STFW | http://www.google.com/search?q=php
LAZY |
http://mycroft.mozdev.org/download.html?name=PHP&submitform=Find+search+plugins
signature.asc
Description: OpenPGP digital signature
--- End Message ---
--- Begin Message ---
I have a script that lists the files in a directory, but when i have
only ONE file , it won't display it ( here is the code :
http://www.pastebin.com/262050 )
--- End Message ---
--- Begin Message ---
it's better for getting help if you could show your code.
On Thu, 24 Mar 2005 12:15:11 +0200, Alexandru Martin
<[EMAIL PROTECTED]> wrote:
> I have a script that lists the files in a directory, but when i have
> only ONE file , it won't display it ( here is the code :
> http://www.pastebin.com/262050 )
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
Sincerely,
Forest Liu(刘云?)
--- End Message ---
--- Begin Message ---
Forest Liu wrote:
> it's better for getting help if you could show your code.
>
He did show his code, he even put it in one of those nice pastebin
sites! Hurrah!
>
> On Thu, 24 Mar 2005 12:15:11 +0200, Alexandru Martin
> <[EMAIL PROTECTED]> wrote:
>
>>I have a script that lists the files in a directory, but when i have
>>only ONE file , it won't display it ( here is the code :
>>http://www.pastebin.com/262050 )
>>
OK so I looked it over, but honestly that is some ugly looking code.
Did you try to optimize it at the cost of readability? I've already
spent 15 minutes looking at your code which is more time than it should
have taken me to diagnose this problem.
Your problem lies somewhere within the logic of your darn while()
loop... but your coding practices have made it difficult for me (someone
that codes PHP from the command-line :-/) to help you. Maybe someone
else will look at this problem for you.
--
Teach a man to fish...
NEW? | http://www.catb.org/~esr/faqs/smart-questions.html
STFA | http://marc.theaimsgroup.com/?l=php-general&w=2
STFM | http://php.net/manual/en/index.php
STFW | http://www.google.com/search?q=php
LAZY |
http://mycroft.mozdev.org/download.html?name=PHP&submitform=Find+search+plugins
signature.asc
Description: OpenPGP digital signature
--- End Message ---
--- Begin Message ---
hi guys,
I need to convert a date from this format: 2005-03-25 to 25 mar 2005.
I have tried the mktime, strftime and the date functions but they all
take a time stamp but I only have the dates in the format of 2005-03-25.
These are what i tried where $row['date'] is 2005-02-24 but they all
return 01 Jan 1970???
echo(mktime(0,0,0, date("j", $row['date']), date("M", $row['date']),
date("Y", $row['date'])));
echo(strftime("%d", $row['date']) . " " . strftime("%b", $row['date']).
" " . strftime("%Y", $row['date']));
echo(date("d",$row['date'] ) . " " . date("M", $row['date']) . " " .
date("Y",$row['date'] ));
thanks in advance
angelo
--- End Message ---
--- Begin Message ---
Hi guys,
got it to work:
$datearr = split('-', $row['date']);
$tstamp = mktime(0,0,0,$datearr[1],$datearr[2],$datearr[0]);
$myformat = date('j M Y',$tstamp);
echo 'myformat: ' . $myformat;
hope this can help others!!
Angelo
Angelo Zanetti wrote:
hi guys,
I need to convert a date from this format: 2005-03-25 to 25 mar 2005.
I have tried the mktime, strftime and the date functions but they all
take a time stamp but I only have the dates in the format of 2005-03-25.
These are what i tried where $row['date'] is 2005-02-24 but they all
return 01 Jan 1970???
echo(mktime(0,0,0, date("j", $row['date']), date("M", $row['date']),
date("Y", $row['date'])));
echo(strftime("%d", $row['date']) . " " . strftime("%b",
$row['date']). " " . strftime("%Y", $row['date']));
echo(date("d",$row['date'] ) . " " . date("M", $row['date']) . " " .
date("Y",$row['date'] ));
thanks in advance
angelo
--
Angelo Zanetti
Z Logic
[c] +27 72 441 3355
[t] +27 21 464 1363
[f] +27 21 464 1371
www.zlogic.co.za
--- End Message ---
--- Begin Message ---
Angelo,
slightly OT , but as a point of interest perhaps, $row['date'] seemed
to indicate that your date comes out of a DB - you can date format
stuff with sql too - I find that useful sometimes...
With MySQL for example, if your date field is called 'myDate' you can
do the following in the query:
SELECT ... DATE_FORMAT(myDate, %d %b %Y) AS date ,....FROM.....
which formats $row['date'] as '25 mar 2005'...
rgds
chris
--- End Message ---
--- Begin Message ---
yeah i know but its used for other calculations thats why i format it
with PHP!!
thanks anyway
Chris Ramsay wrote:
Angelo,
slightly OT , but as a point of interest perhaps, $row['date'] seemed
to indicate that your date comes out of a DB - you can date format
stuff with sql too - I find that useful sometimes...
With MySQL for example, if your date field is called 'myDate' you can
do the following in the query:
SELECT ... DATE_FORMAT(myDate, %d %b %Y) AS date ,....FROM.....
which formats $row['date'] as '25 mar 2005'...
rgds
chris
--
Angelo Zanetti
Z Logic
[c] +27 72 441 3355
[t] +27 21 464 1363
[f] +27 21 464 1371
www.zlogic.co.za
--- End Message ---