date format xx-xx-xxxx

Get help with installation and running phpwcms here. Please do not post bug reports or feature requests here.
artico
Posts: 23
Joined: Tue 1. Jun 2004, 01:14
Location: denmark
Contact:

date format xx-xx-xxxx

Post by artico »

I want the dateformat in article content to be 02-06-2004 but i have tried to edit the file article.editcontent.inc.php to correct this ? But with no luck ?

Where can i change to get the rigth format ?
Pappnase

Re: date format xx-xx-xxxx

Post by Pappnase »

artico wrote:I want the dateformat in article content to be 02-06-2004 but i have tried to edit the file article.editcontent.inc.php to correct this ? But with no luck ?

Where can i change to get the rigth format ?
hello

goto to the include/inc_conf/ folder open the conf.tempalet_default.inc.php and change line 152 from

Code: Select all

$template_default["date"]["short"]			= "y/m/d";      // (2003/12/25)
to

Code: Select all

$template_default["date"]["short"]			= "d-m-Y";      // (2003/12/25)
the changes are the same for the other date_long ......
artico
Posts: 23
Joined: Tue 1. Jun 2004, 01:14
Location: denmark
Contact:

No it dosent work ?

Post by artico »

I have done the d-m-Y change but nothing happend ? maybe its is somthing about the language ? In data base Danish = DK but ind the conf file it is da ? What is it ?
Pappnase

Re: No it dosent work ?

Post by Pappnase »

artico wrote:I have done the d-m-Y change but nothing happend ? maybe its is somthing about the language ? In data base Danish = DK but ind the conf file it is da ? What is it ?
test it please with DA not DK


the lang file:

Code: Select all

// language: DA

$weekday_long[0]	= "Søndag"; 		$weekday_short[0]	= "Sø";
$weekday_long[1]	= "Mandag";			$weekday_short[1]	= "Ma";
$weekday_long[2]	= "Tirsdag";		$weekday_short[2]	= "Ti";
$weekday_long[3]	= "Onsdag"; 		$weekday_short[3]	= "On";
$weekday_long[4]	= "Torsdag";		$weekday_short[4]	= "To";
$weekday_long[5]	= "Fredag"; 		$weekday_short[5]	= "Fr";
$weekday_long[6]	= "Lørdag"; 		$weekday_short[6]	= "Lø";
$month_long[ 1]	= "Januar";			$month_short[ 1]		= "Jan.";
$month_long[ 2]	= "Februar";		$month_short[ 2]		= "Feb.";
$month_long[ 3]	= "Marts";			$month_short[ 3]		= "Mar.";
$month_long[ 4]	= "April";			$month_short[ 4]		= "Apr.";
$month_long[ 5]	= "Maj";			$month_short[ 5]		= "Maj";
$month_long[ 6]	= "Juni";			$month_short[ 6]		= "Juni";
$month_long[ 7]	= "Juli";			$month_short[ 7]		= "Juli";
$month_long[ 8]	= "August";			$month_short[ 8]		= "Aug.";
$month_long[ 9]	= "September";		$month_short[ 9]		= "Sep.";
$month_long[10]	= "Oktober";		$month_short[10]		= "Okt.";
$month_long[11]	= "November";		$month_short[11]		= "Nov.";
$month_long[12]	= "December";		$month_short[12]		= "Dec.";
artico
Posts: 23
Joined: Tue 1. Jun 2004, 01:14
Location: denmark
Contact:

No!

Post by artico »

I have tryed with: da and DA nothing is changed, my article is still made:
YYYY-MM-DD TT:MM:SS ??

In the file: article.new.tmpl.php line 45 there is the dataformat: Y-m-d H:i:s But when i change this all my articles will not shows ?
Pappnase

Post by Pappnase »

hello

wich version did you use!?
it seems to be that you have an error somewhere else!

at my site it works!
take a look
i use in the template {DATE_LONG} and before this {DATE_SHORT}
http://www.mohrundmehr.de

conf.template_default.inc.php

Code: Select all

// date and time formatting
$template_default["date"]["language"]		= "DA";         // DE=German, IT=Italian, FR=French
$template_default["date"]["long"]			= "l, j. F Y";  // (Monday, 1. October 2003)
$template_default["date"]["medium"]			= "D, j. M y";  // (Mon, 1. Oct 03)
$template_default["date"]["short"]			= "d-m-Y";      // (2003/12/25)
$template_default["date"]["article"]		= "d-m-Y";      // (2003/12/25)
$template_default["time"]["long"]			= "H:i:s";      // 15:25:45
$template_default["time"]["short"]			= "H:i";        // 15:25
artico
Posts: 23
Joined: Tue 1. Jun 2004, 01:14
Location: denmark
Contact:

Post by artico »

I just download the zip today, and begin install ?? But the date is still wron ? where can i look ore what can i do ?
Pappnase

Post by Pappnase »

hello

did your entry in the conf.template_default.inc.php file the same as i showed above?!
artico
Posts: 23
Joined: Tue 1. Jun 2004, 01:14
Location: denmark
Contact:

Yesss

Post by artico »

I copy it in ?
Pappnase

Post by Pappnase »

hello

yes you can but search for the lines would be enough and change it manually! it's only 2 rows you need to change! wich {DATE-x} TAG did you use!?
Pappnase

Re: No!

Post by Pappnase »

artico wrote:I have tryed with: da and DA nothing is changed, my article is still made:
YYYY-MM-DD TT:MM:SS ??

In the file: article.new.tmpl.php line 45 there is the dataformat: Y-m-d H:i:s But when i change this all my articles will not shows ?
also you don't need to edit the article.new.tmpl.php file the most config files are in the include/inc_conf/ folder!
artico
Posts: 23
Joined: Tue 1. Jun 2004, 01:14
Location: denmark
Contact:

it isen´t the TAG

Post by artico »

It is the article opdated info like this: http://www.webtik.dk/date/
Pappnase

Re: it isen´t the TAG

Post by Pappnase »

artico wrote:It is the article opdated info like this: http://www.webtik.dk/date/
hello

that has nothhing to do with the template! thats only when is the article created. and you can setup there from when the article should be shown and how long!

you need to include in the header or were ever you want the {DATE_LONg} Or {DATE_SHORT} or {DATE_MEDIUM} than the users will see the actual date at the site.
artico
Posts: 23
Joined: Tue 1. Jun 2004, 01:14
Location: denmark
Contact:

OK But

Post by artico »

Is i not possibal to change the dateformat to DD-MM-YYYY in the backend ?
:-)
Pappnase

Re: OK But

Post by Pappnase »

artico wrote:Is i not possibal to change the dateformat to DD-MM-YYYY in the backend ?
:-)
no it's not possible! also why!?
Post Reply