I am trying to get a calendar page set up for a site I’m working on, and I’ve been having some trouble with the “next” and “previous” month links. There are two embed tags in my sidebar div (near the top of my code) that show up on the current month page, but disappear on any other month pages.
Also, I am using the Lg .htaccess generator extension to remove “index.php” from my urls, but all links generated within the calendar tag (next and previous months links, and links to events) put the “index.php” back in the url.
Are these issues related? Does anyone know what’s causing them or how to resolve them? My code is below, and you can see the site here.
{embed="includes/header" page_title="Calendar"}
<div id="sidebar">
{embed="includes/side_bucket" id_number="2"}
{embed="includes/side_bucket" id_number="3"}
</div>
<div id="content">
<div id="crumbs">
Home : Events : Calendar
</div>
[removed]
$(document).ready(function(){
$('table.calendarBG tr td:first-child').addClass('alt');
});
[removed]
<div id="calendar">
{exp:weblog:calendar switch="calendarToday|calendarCell" weblog="events" show_future_entries="yes"}
<table class="calendarBG" border="0" cellpadding="0" cellspacing="0" summary="My Calendar" width="100%">
<thead>
<tr class="calendarHeader">
<th colspan="7">{date format="%F %Y"}</th>
</tr>
<tr>
{calendar_heading}
<td class="calendarDayHeading">{lang:weekday_short}</td>
{/calendar_heading}
</tr>
</thead>
<tbody>
{calendar_rows }
{row_start}<tr>{/row_start}
{if entries}
<td class="{switch}" align='center'>
<div class="date-cell">{day_number}</div>
{entries}
<div><a href="http://{title_permalink=events/details}title={embed=id={entry_id}">{title}</a></div>
{/entries}
</td>
{/if}
{if not_entries}
<td class="{switch}" align='center'><div class="date-cell">{day_number}</div></td>
{/if}
{if blank}
<td class="{switch} calendarBlank"><div class="date-cell">{day_number}</div></td>
{/if}
{row_end}</tr>{/row_end}
{/calendar_rows}
</tbody>
<tfoot>
<tr>
<td colspan="7">
<a href="http://{previous_path=events/calendar}class=left">« Previous Month</a><a href="http://{next_path=events/calendar}class=right">Next Month »</a>
</td>
</tr>
</tfoot>
</table>
{/exp:weblog:calendar}
</div>
</div>
</div>
{embed="includes/footer"}