mIRC Home    About    Download    Register    News    Help

Print Thread
#131728 03/10/05 09:05 PM
Joined: Feb 2004
Posts: 119
D
da_hype Offline OP
Vogon poet
OP Offline
Vogon poet
D
Joined: Feb 2004
Posts: 119
anyone have a small code to change

Mon, 15 Aug 2005 to 15/08/2005

thanks

#131729 03/10/05 09:24 PM
Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
Code:
var %date = Mon, 15 Aug 2005 
echo -a $date($ctime(%date),dd/mm/yyyy)

#131730 04/10/05 12:46 AM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
You have to remove the , from the original date before converting it
Code:
var %date = Mon, 15 Aug 2005
echo -a $date($ctime($remove(%date,$chr(44))),dd/mm/yyyy)
  

If you don't remove the comma (and the same thing applies with any punctuation) you'll get an error.

#131731 04/10/05 12:56 AM
Joined: Feb 2004
Posts: 2,019
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
That's the reason he put the date in a variable first, and pass the variable to $ctime.

It works fine as he gave it, try it yourself:

//var %date = Mon, 15 Aug 2005 | echo -a $date($ctime(%date),dd/mm/yyyy)


Gone.

Link Copied to Clipboard