cotonti.com : ignore a category in plugin recent index https://www.cotonti.com Последние сообщения в теме Cotonti en Wed, 22 Oct 2025 15:56:14 -0000 elfrenazo without problems, it is not essential, thanks for your time smiley

]]>
сб, 21 янв 2012 10:40:17 -0000
ez @Gert:
I have no intention to work on cotonti... i simply havent got the time.. but you are free to use this change :) its a good one that should have been there long ago..

@Elfrenazo:
This is very easy to change for the cot devs... so they can implement it.. i am not familiar with github so this will cost me too much time to do what Gert suggested..
Sorry about that...

]]>
сб, 21 янв 2012 08:53:18 -0000
elfrenazo #32839 ez:

Something like this !!
I have developed it years ago.. its ez..
By the way this code also does the time exclusion bit

	/* 2basix change: added exclude categories and added timefilter */
	// 2basix added: page_author
	$excludecats = trim($cfg['plugin']['recentitems']['excludecats']);
	$excludecats = "system". (empty($excludecats) ? "":",".$excludecats );
	$timefilter = "page_begin<'".$sys['now_offset']."' AND page_expire>'".$sys['now_offset']."'";

	$sql = sed_sql_query("SELECT page_id, page_alias, page_cat, page_title, page_date, page_author FROM $db_pages WHERE page_state=0 AND $timefilter AND FIND_IN_SET(page_cat,'$excludecats')<=0 ORDER by page_date DESC LIMIT $l");

	$newitem = (empty($excludecats) ? "":",".$excludecats );
	/* 2basix EndOfChange EOC */
Like you see i made a new item in setup called excludecats:
something like this

excludecats=02:string:::Exclude PageCats (comma separated)

 where I have to put that code?
sorry no i'am programmer

]]>
сб, 21 янв 2012 04:34:41 -0000
GHengeveld $sys['now_offset'] is replaced with $sys['now'] in recent versions of Cotonti. The one with _offset was used to work with user's timezone setting, but this has been replaced with a more global approach which doesn't need it anymore, so $sys['now_offset'] and $sys['now'] are identical.

@ez: If you fork Cotonti on Github, then make this change to the recentitems plugin and send a pull request, I can include this feature in the core package.

]]>
пт, 20 янв 2012 23:00:04 -0000
ez Something like this !!
I have developed it years ago.. its ez..
By the way this code also does the time exclusion bit

	/* 2basix change: added exclude categories and added timefilter */
	// 2basix added: page_author
	$excludecats = trim($cfg['plugin']['recentitems']['excludecats']);
	$excludecats = "system". (empty($excludecats) ? "":",".$excludecats );
	$timefilter = "page_begin<'".$sys['now_offset']."' AND page_expire>'".$sys['now_offset']."'";

	$sql = sed_sql_query("SELECT page_id, page_alias, page_cat, page_title, page_date, page_author FROM $db_pages WHERE page_state=0 AND $timefilter AND FIND_IN_SET(page_cat,'$excludecats')<=0 ORDER by page_date DESC LIMIT $l");

	$newitem = (empty($excludecats) ? "":",".$excludecats );
	/* 2basix EndOfChange EOC */
Like you see i made a new item in setup called excludecats:
something like this

excludecats=02:string:::Exclude PageCats (comma separated) ]]>
пт, 20 янв 2012 20:08:39 -0000
elfrenazo ok thanks for your answer

]]>
пт, 20 янв 2012 14:46:54 -0000
GHengeveld With recentitems its not possible. It should be relatively simple to modify it to ignore specific categories though. Maybe you can try that and release it so we can use it in the Cotonti package?

]]>
пт, 20 янв 2012 14:14:01 -0000
elfrenazo you can ignore a category in plugin recent index ?

]]>
пт, 20 янв 2012 11:16:23 -0000