Author |
Topic |
|
Andy Humm
Average Member
United Kingdom
908 Posts |
Posted - 25 April 2008 : 17:39:21
|
Having just sucessfully installed the Calendar Events MOD, I have noticed the date format that is shown on an event is not in the same format as the rest of the forum.ie the rest show dd mmm yyyy What is shown on my calander event is first image
Ideally to match the rest of the date formats I would like it to show like this:
Can anyone point us to the str that formats the date style for the topic ..
Shaggy did mention on the forum a while ago - the date style that I need to change is the LCID in the config.asp file so that any other dates passed through the strtodate function is displayed correctly. As I'm in the UK, I have changed change the LCID to 2057.
is there some strtodate missing in the code to display the date above
regards andy
|
Edited by - Andy Humm on 25 April 2008 17:50:18 |
|
leatherlips
Senior Member
USA
1838 Posts |
|
leatherlips
Senior Member
USA
1838 Posts |
|
Andy Humm
Average Member
United Kingdom
908 Posts |
Posted - 25 April 2008 : 20:23:41
|
When I was adding the code in post_info.asp Where the readme file says Line 894 my_Conn.Execute (strSql),,adCmdText + adExecuteNoRecords
Below that, insert this %><!--#INCLUDE FILE="cal_post_info2.asp"--> <% I noticed when I did a search on the file for my_Conn.Execute (strSql),,adCmdText + adExecuteNoRecords there was more than one entry of this text. I ended up putting the inserted code on line 926 hope that helps andy
|
|
|
Andy Humm
Average Member
United Kingdom
908 Posts |
Posted - 25 April 2008 : 20:28:14
|
Re 'found a clue in the cal_topic.asp file line 41:' I'll give it a fiddle Leatherlips thank you,, see also post above.. |
|
|
leatherlips
Senior Member
USA
1838 Posts |
|
Andy Humm
Average Member
United Kingdom
908 Posts |
Posted - 26 April 2008 : 02:43:35
|
Apols, for delay, my last post was at 1.30am British Summer Time, didn't realise time. However there is a lot of code around the 'my_Conn.Execute (strSql),,adCmdText + adExecuteNoRecords ' where I have put the '%><!--#INCLUDE FILE="cal_post_info2.asp"--> <%' so I have posted a text file of post_info.asp here, as I have other mods installed too. Look for line 926.. Regards andy |
|
|
Andy Humm
Average Member
United Kingdom
908 Posts |
Posted - 26 April 2008 : 03:04:43
|
Regarding the date format as posted with images above, I tried your changes Leatherlips, if the topic shows reoccurring dates in the suggested format it displays like: April 2008 27 May 2008 4, 11, 18, 25 June 2008 1, 8, 15, 22, 29 July 2008 6, 13, 20, 27 August 2008 3, 10, 17, 24, 31 Thinking about it, I think it is easier to read in the yyyy mmmm dd format, especially when more than one date is listed, so I will 'stay as is' and put up with non UK date format in that area. All the rest of the date formats are okay to match LCID,,, Thank you anyway..
|
|
|
Andy Humm
Average Member
United Kingdom
908 Posts |
Posted - 26 April 2008 : 03:17:14
|
Leatherlips, further to my post regarding the positioning of the Events Topic Title in side the topic page, see Topic.asp lines 900-913
Response.Write " <hr noshade size=""" & strFooterFontSize & """></td>" & vbNewLine & _ " </tr>" & vbNewLine & _ " <tr>" & vbNewLine & _ " <td valign=""top"" height=""100%""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><span class=""spnMessageText"" id=""msg"">" If blnEvent Then %> <!-- #include file="cal_topic.asp" --> <% End If if Request.QueryString("SearchTerms") <> "" then Response.Write SearchHiLite(formatStr(Topic_Message)) else Response.Write formatStr(Topic_Message) end if Response.Write "</span id=""msg""></font></td>" & vbNewLine & _ " </tr>" & vbNewLine
Your line numbers might be slightly different, owing to mod status.. Hope this helps Andy |
|
|
leatherlips
Senior Member
USA
1838 Posts |
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 28 April 2008 : 04:44:26
|
quote: Originally posted by leatherlips I found a clue in the cal_topic.asp file line 41:
Response.Write vbNewLine & " <BR/>" & Year(Event_Date) & " " & MonthName(Month(Event_Date)) & " "
If I reversed the two parts in red it gives me this:
May 2008 13
Maybe if you played around with that you could get the format you wanted. Also this file has the strtodate code you mentioned.
Either the chkDate or strToDate function should be used to display dates pulled from the database to ensure they're formatted properly.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
|
Topic |
|