This thread is a discussion for the wiki article: Recurring entries
   
 
Recurring entries
Posted: 23 August 2008 01:51 PM   [ Ignore ]  
Lab Assistant
Avatar
RankRank
Total Posts:  102
Joined  09-23-2004

Hi Lisa,

Thanks to your code examples and a google search looking for “convert timestamp to unix” and some stumbling through, I managed to put this together:

{exp:query sql=“SELECT * FROM exp_weblog_titles WHERE weblog_id=‘7’ AND exp_weblog_titles.entry_date>unix_timestamp(’{segment_3}-{segment_4} 12:00:01’) AND exp_weblog_titles.entry_date<unix_timestamp(‘2008-{segment_5} 12:00:01’)”}
{entry_id} - {title}
{/exp:query}

On the URL, if we have it like so: index.php/tasks/schedule/2008/08-25/08-31

The query will pull entries between 8/25 through 8/31. 

This enables us to view date based “reports” or “schedules” on the fly by adjusting dates in URL.  Logically, I should have been able to do this with start_on and end_before parameters but they just weren’t playing very nice with what I wanted.  This is a good alternative.  grin

I’m most proud of the fact I am not a programmer at all and managed to figure this out.  Couldn’t have figured it out without your code examples, though!

Elise

 Signature 

Elise “Lisi” Whitworth
HTMLaddicts.com

Profile
 
 
   
 
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 1149, on July 16, 2007 09:33 AM
Total Registered Members: 64912 Total Logged-in Users: 29
Total Topics: 81864 Total Anonymous Users: 18
Total Replies: 440104 Total Guests: 187
Total Posts: 521968    
Members ( View Memberlist )
Newest Members:  bjmohrAqua193Bios Elementmjpoteetguimogranwelshmrcfthenetmonkeybenekwhobutsb