Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#101 2017-04-20 21:55:14

singaz
Member
From: Kyiv, Ukraine
Registered: 2017-03-12
Posts: 134

Re: smd_lately: recently viewed site articles

Updated txp 4.5.7 to txp 4.6.2 and
… <txp:smd_lately by=”“ limit=“4” section=“cars” > -> Textpattern Notice: unregistered_tag …

p.s.
when
Admin > Site > Production status > Debugging


Sorry my horror English. I’m learning textpattern, I’m learning English

Offline

#102 2017-04-20 22:21:18

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,225

Re: smd_lately: recently viewed site articles

If you’re in a bold mood you can try to fix it by yourself (see the two links with “tag registering”. Not too complicated.) Or set your prefs to “Live”. Nothing bad will happen, except you can’t see other errors.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#103 2017-04-20 23:52:47

singaz
Member
From: Kyiv, Ukraine
Registered: 2017-03-12
Posts: 134

Re: smd_lately: recently viewed site articles

Need to add

 if (class_exists('\Textpattern\Tag\Registry')) {
	Txp::get('\Textpattern\Tag\Registry')
		->register('smd_lately')
	;
}

uli, thanks!


Sorry my horror English. I’m learning textpattern, I’m learning English

Offline

#104 2018-09-03 10:15:43

kees-b
Member
From: middelburg, nl
Registered: 2004-03-03
Posts: 234
Website

Re: smd_lately: recently viewed site articles

smd_lately stopped working after an upgrade to TXP 4.7.1 because IP logging was dropped to make the logs GDPR compliant, which is good. I tried to use include=“page” in stead of the default “IP” but that doesn’t seem to work. Is there a way make it work again or another way to generate a ‘most read’ list as smd_lately did?

Kees

Offline

#105 2018-09-03 10:32:31

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 3,852
Website

Re: smd_lately: recently viewed site articles

It’s not quite the same in that it doesn’t count unique visitors, but maybe this hint by NicolasGraph based on a prior tip by etc. helps. Basically it updates a timestamp in a custom field when an article is read and you can output your most recently read article using article_custom sorted by the custom_field with the timestamp.


TXP Builders – finely-crafted code, design and txp

Offline

#106 2018-09-03 11:12:05

kees-b
Member
From: middelburg, nl
Registered: 2004-03-03
Posts: 234
Website

Re: smd_lately: recently viewed site articles

jakob wrote #313783:

It’s not quite the same in that it doesn’t count unique visitors, but maybe this hint by NicolasGraph based on a prior tip by etc. helps. Basically it updates a timestamp in a custom field when an article is read and you can output your most recently read article using article_custom sorted by the custom_field with the timestamp.

Thanks Jakob I’ll give that a try!

Offline

#107 2020-04-22 08:40:01

Gallex
Member
Registered: 2006-10-08
Posts: 1,158

Re: smd_lately: recently viewed site articles

PHP version: 7.1.33
after upgrade TXP to 4.8, i get fatal error:

Fatal error: Uncaught Error: Call to undefined function find_temp_dir() in /www/apache/domains/www.varaleidja.ee/htdocs/textpattern/plugins/smd_lately/smd_lately.php:60 Stack trace: #0 [internal function]: smd_lately(Array, '\r\n<div class="a...') #1 /www/apache/domains/www.varaleidja.ee/htdocs/textpattern/vendors/Textpattern/Tag/Registry.php(141): call_user_func('smd_lately', Array, '\r\n<div class="a...') #2 /www/apache/domains/www.varaleidja.ee/htdocs/textpattern/lib/txplib_publish.php(541): Textpattern\Tag\Registry->process('smd_lately', Array, '\r\n<div class="a...') #3 /www/apache/domains/www.varaleidja.ee/htdocs/textpattern/lib/txplib_publish.php(447): processTags('smd_lately', 'limit="4" by="S...', '\r\n<div class="a...') #4 /www/apache/domains/www.varaleidja.ee/htdocs/textpattern/publish/taghandlers.php(4258): parse('\r\n\r\n<txp:articl...', true) #5 [internal function]: if_section(Array, '\r\n\r\n<txp:articl...') #6 /www/apache/domains/www.varaleidja.ee/htdocs/textpattern/vendors/Textpattern/Tag/Registry.php(141 in /www/apache/domains/www.varaleidja.ee/htdocs/textpattern/plugins/smd_lately/smd_lately.php on line 60

Offline

#108 2020-04-22 10:15:47

Gallex
Member
Registered: 2006-10-08
Posts: 1,158

Re: smd_lately: recently viewed site articles

…or maybe it can be done with TXP native tags? i need most viewed articles functionality

Offline

#109 2020-04-22 10:31:01

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 9,481
Website

Re: smd_lately: recently viewed site articles

I’ve fixed this bug on the github version. Can’t remember if I bundled up a release or not. But if not, I’ll do so later.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#110 2020-04-22 10:41:40

Gallex
Member
Registered: 2006-10-08
Posts: 1,158

Re: smd_lately: recently viewed site articles

Bloke wrote #322669:

I’ve fixed this bug on the github version. Can’t remember if I bundled up a release or not. But if not, I’ll do so later.

sorry, bloke, but… how to install it?

Offline

Board footer

Powered by FluxBB