Thanks for your responds.
Entry’s are posted at the correct day, but an incorrect time (2 hours earlier). The setting for my server time zone under ‘Localization settings’ is ‘(UTC) Greenwich Time, Western European Time’. Since this website is used mostly in Western Europe, I thought that was alight. Changing it to ‘UTC +2:00” doesn’t fix the time-problem. All entries are registered 2 hours earlier than they were really sent.
So here’s the code that generates the week-menu:
exp:channel:entries dynamic="no" channel="nieuws" orderby="date" sort="desc" limit="53" disable="member_data|pagination|categories|custom_fields" show_future_entries="yes"}
{date_heading display="weekly"}
<option value="{path='nieuws'}/{segment_2}/{week_date format="%YW%W"}">week {week_date format="%W - %Y"}</option>
{/date_heading}
{/exp:channel:entries}
And here the list of entries for the selected week:
<?php
if ($this->EE->uri->segment(3) === FALSE)
{
// current date
$entryDate = date("Y-m-d");
}
else
{
$entryDate = $this->EE->uri->segment(3);
}
?>
{exp:channel:entries channel="nieuws" dynamic="no" disable="member_data|trackbacks" status="open" show_future_entries="yes" start_on="<?php echo date('Y-m-d', strtotime("$entryDate")) . " 00:00"; ?>" stop_before="<?php echo date('Y-m-d', strtotime("$entryDate"."7")) . " 24:00"; ?>"}
{if no_results}
<li>no results message here </li>
{/if}
<li>news item here</li>
{/exp:channel:entries}
I don’t know if this is the best way to do this. However the ‘start_on’ and ‘stop_before’ parameters DO work. They do filter out the correct entry’s with the corresponding week.
I hope you can help me out.
Thanks!
Jef