Welcome to Geeklog, Anonymous Tuesday, March 19 2024 @ 05:46 am EDT

Geeklog Forums

Too many events on the events_block


FredR

Anonymous
Where can I limit the events_block output to say 12 items and/or exclude event types? A maxout would be preferable.

Fred
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
function COM_printUpcomingEvents in lib-common.php

bye, Dirk
 Quote

FredR

Anonymous
Thats where I thought i'd be. I was hoping for a code example...

Fred
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Add a LIMIT after the ORDER BY clause:
Text Formatted Code
. 'ORDER BY datestart, dateend LIMIT 15';
 
would limit it to 15 events.

bye, Dirk
 Quote

FredR

Anonymous
Line 4217

. 'ORDER BY datestart,timestart LIMIT 15';

added the limit there. Seems to work :-)

Thanks.

Fred
 Quote

All times are EDT. The time is now 05:46 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content