three time I've fricked my template.
1) I want the name of the event, and a secondary field from my event db called (State)& the date of the event to displayin two places.
in the span of my events under month view.
I also would like the exact same details to be displayed at the top of the event view page for each event in the blue bar that shows the name of the event.
(and I can't seem to find either location in template to add this, or a proper syntax to add this)
help
DS
------------------DataStreamDesignz
On the default.html template, the title is printed out using the tag <%= EVENT FIELD(title) %>. Search the template for it and you'll find all the places it might be printed.
** or a proper syntax to add this **
Any event record field can be printed using the tag <%= EVENT FIELD(field_key) %> where field_key is the key valve of the field you want printed.
Dan O.
[This message has been edited by DanO (edited May 07, 2005).]
I got everything to work ... except one minor glitch. I have modified templates for Full-Year View with Day Span, MiniCal and other goodies. The challenge I was having was getting the event dates to display in the Event View. By following much of the above advice, this now works, too EXCEPT when an event in the bottom row of the calendar grid is clicked, for some reason the "datestring" does not get attached. This appears to be specific to that bottom row, as the same events will be just fine if I use "90-day" or "Full-Year" View and get them up from the bottom row (it doesn't matter if they are actually the last date of the month, nor whether they're the first, middle or last in a span of dates).
So I'll let ya know what happens I guess....
$schedules = &Event::getEventsInRange($db,timegm(0,0,0,$DATE,$MONTH-1,$YEAR-1900),timegm(0,0,0,$DATE+1,$MONTH-1,$YEAR-1900)-1);
I get an error: "Day 31 out of range 1...30 at (eval 1) line 64.
If the month has 28 days, like February, the error template says, "Day 29 out of range."
I tried removing the +1 from the $DATE in the second set of timegm, as johannes suggested, and that fixes the problem but then I don't get a time. Does anyone have any other suggestions? What's REALLY bugging me is I have this exact same code on another calendarscript calendar on another server and it works great. Thanks,
w
------------------
Maybe the 'timezone offset' is set differently on each? If so, maybe the code calculating using an incorrect date at the end of month?
Current time on the web server is: Sat May 13 21:14:45 2006Your browser's local time is: Sat May 13 2006 21:05:27 GMT-0400 (Eastern Daylight Time)
So the time is off a little but not that much? Interestingly I copied the default.html template from server A, the one that works, and moved the whole thing over to server B, which doesn't work. It didn't work on server B, so I don't think it has anything to do with any mods or hacks I've made. Anything to do with daylight savings time?
HOWEVER...if the day span event goes from one week, to the next....the link to for the FIRST week works... http://www.wearemanalive.com/cgi-bin/calendar/calendar.pl?view=Event&event_id=73&datestring=20070428
BUT the 2nd week link doesnt. the datestring is blank... http://www.wearemanalive.com/cgi-bin/calendar/calendar.pl?view=Event&event_id=73&datestring=
i tried looking through the code, but i dont understand the dayspan code at all. im not advanced enough i guess...
the datestring on the dayspan events that DONT work, are set for the last day of that week instead of the last day of the the event. which is why the events that wrap to the next line work. because the last day of the week and the last day of that event are the same.
so somewhere, the daystring is being set wrong for events that dont extend to the last day of that week.
ALSO
i need to correct my last post. the events that span to another line, DO in fact have a datestring. The ONLY time the datestring is blank is when its on the LAST week of the month.If it spans to a new week earlier in the week, it has a datestring, but has the same issue as the problem above.