Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#391 2018-02-27 17:43:57

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 651
Website

Re: smd_tags: unlimited article, image, file and link taxonomy

Stef, i don’t find the error. Everything looks like you proposed to me.

Could it be, that some mechanism doesn’t work on an https connection?
And: I’m on a Litespeed server, not running Apache…

I feel almost tempted to post diagnostics, and i know you guys are busy with 4.7.0 for sure…

anyway here it is/low resolution:

Textpattern version: 4.6.2 (bfa46b9ca53321b86032998cc23950ab)
Last update: 2018-02-19 12:17:11/2018-02-19 12:04:44
...
Article URL pattern: title_only
Temporary directory path: /tmp
Site URL: ...
PHP version: 5.4.45
GD Graphics Library: bundled (2.1.0 compatible); supported formats: GIF, JPG, PNG.
Server TZ: Europe/Moscow
Server local time: 2018-02-27 20:45:18
Daylight Saving Time enabled?: 0
Automatically adjust Daylight Saving Time setting?: 0
Time zone (GMT offset in seconds): Europe/Berlin (+3600)
MySQL: 5.5.5-10.1.30-MariaDB
Database server time: 2018-02-27 11:45:18
Database server time offset: 0 s
Database server timezone: SYSTEM
Database session timezone: SYSTEM
Locale: en_GB.UTF-8
Server: LiteSpeed
PHP server API: litespeed
RFC 2616 headers: 
Server OS: Linux 3.10.0-714.10.2.lve1.4.77.el7.x86_64
Active plugins: cbe_frontauth-0.9.7m, smd_query-0.50, smd_multi_choice-0.20, adi_gps-0.4, rah_replace-0.4.2m, rah_repeat-1.0.1, adi_matrix-2.1beta2, oui_player-1.3.1, etc_search-0.9.5, smd_tabber-0.11, yab_cf_article_list-0.2, glz_custom_fields-1.5.0, smd_user_manager-0.21, smd_tags-0.60
Admin-side theme: hiveneutral 4.6.2

Pre-flight check: 
------------------------
Clean URLs are only supported on Apache, use at your own risk.
/home/kliklak/public_html/infra/textpattern/setup/ still exists
Some Textpattern files have been modified: 
	/home/kliklak/public_html/infra/textpattern/textpattern.js
------------------------

.htaccess file contents: 
------------------------
#DirectoryIndex index.php index.html

#Options +FollowSymLinks
#Options -Indexes
SecFilterEngine Off
<IfModule mod_rewrite.c>
	RewriteEngine On
	#RewriteBase /relative/web/path/

	RewriteCond %{REQUEST_FILENAME} -f [OR]
	RewriteCond %{REQUEST_FILENAME} -d
	RewriteRule ^(.+) - [PT,L]

	RewriteCond %{REQUEST_URI} !=/favicon.ico
	RewriteRule ^(.*) index.php

	RewriteCond %{HTTP:Authorization}  !^$
	RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization}]
	RewriteCond %{HTTPS} !=on [NC]
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
</IfModule>

##php_value register_globals 0


EDIT: The only error in debugging mode is the missing article tag on the landing page, no errors in backend.

Last edited by jayrope (2018-02-27 23:39:44)


a hole turned upside down is a dome, when there’s also gravity.

Offline

#392 2018-02-27 18:42:33

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

Re: smd_tags: unlimited article, image, file and link taxonomy

Can’t figure what could be going wrong. Would it be possible to have a publisher login so I can see if I can figure it out?


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

#393 2018-02-27 19:10:29

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 651
Website

Re: smd_tags: unlimited article, image, file and link taxonomy

Thank you, Stef, that’s very kind. I sent you a PM.


a hole turned upside down is a dome, when there’s also gravity.

Offline

#394 2018-02-27 23:34:10

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

Re: smd_tags: unlimited article, image, file and link taxonomy

Thank you for the login. And the award for most obscure bug to track down on the planet goes to… me, probably.

For a panicked moment, I thought it wasn’t working because you were using a subdomain (and I thought I’d fixed that long ago). Thank goodness it wasn’t that.

Nope, the reason it was falling down was…

… deep breath…

you had an article in the same section as your tag result lists.

Remember in the first exchange I questioned why you’d done that and said it might not work? Well it doesn’t, I just found out for sure!

Thinking about it, I know why this happens. It’s to do with tag protection and (partly) poor coding on my part. Since you can use <txp:smd_tag_list> in multiple contexts so you can list tags on landing pages and also within articles, if it detects that an article is in use it blows away the tags found on the URL in deference to the ones it might find in the article. In this case of course, there are no tags in the article in the filter section, so you get no output.

In an ideal world, it would be able to handle both, but the plugin keeps track of the “tags I’ve found” in a single global variable, so there can be only one list. And if you have an article, it beats the URL and overwrites what it finds there. Articles always win.

Simply hiding (or better yet deleting) the article restored everything to full working order, and saved my sanity… just. So please delete that article at your leisure and wire up your in-article tag lists to point to the /filter page using the link attribute.

Job done.


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

#395 2018-02-27 23:49:30

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 651
Website

Re: smd_tags: unlimited article, image, file and link taxonomy

Whew ha. I guess I had misunderstood you. I was just not using txp:article tags on the filter page. Didn’t realize the sheer existence of an an actual article assigned to the filter section would be a problem.

the plugin keeps track of the “tags I’ve found” in a single global variable, so there can be only one list.

I am secretly wishing already i could run several of those plugs, and creating several tag lists with different content. This is perfect ground for networking, cross-reference.

Stef, thank you very much. Now i can go network the heck out of that! It isn’t commercial, really, however I’ll send flowers soon again.

Last edited by jayrope (2018-02-27 23:50:24)


a hole turned upside down is a dome, when there’s also gravity.

Offline

#396 2018-03-01 17:30:22

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 651
Website

Re: smd_tags: unlimited article, image, file and link taxonomy

Stef, smd_tags is really an awesome idea. Bravo!

i found, that i can do sorting of related tags by custom fields and use those in a form to display addtional information
<txp:smd_related_tags sort="custom_1 asc, custom_2 asc" match="tag_title" form="sitemap_secondary" />

and form sitemap_secondary for instance like this:

<li class="left"><txp:if_different><txp:custom_field name="country" /><txp:else />"</txp:if_different></li> <li class="left"><txp:if_different><txp:custom_field name="city" /><txp:else />"</txp:if_different></li> <li><txp:permlink><txp:title /></txp:permlink></li>

That is super awesome!

Now i wonder (is that a feature request?) can one also establish sthg. like
<txp:smd_related_tags custom_2="Berlin" form="sitemap_secondary" />
? The version above at least doesn’t work, neither does
<txp:smd_related_tags city="Berlin" form="sitemap_secondary" />

Provided i can use a section to select output of smd_related_articles it just seems logical to go further.

So can i do this somehow already, or is this a feature request?


a hole turned upside down is a dome, when there’s also gravity.

Offline

#397 2018-03-01 18:10:37

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 651
Website

Re: smd_tags: unlimited article, image, file and link taxonomy

Is there a naming convention for tags?

Somehow i can only get tag result lists from smd_related_tags, when the tag name has only one word in it.

As soon as i use
Design company which names to design-company or word1 (word2) which names to @word1-word2
the result is not a list anymore, but just the note, that the tag has x entries. Page source shows nothing else as well, not even surrounding html tags.

Bug or naming convention?


a hole turned upside down is a dome, when there’s also gravity.

Offline

#398 2018-03-01 18:20:27

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

Re: smd_tags: unlimited article, image, file and link taxonomy

jayrope wrote #309555:

can one also establish sthg. like <txp:smd_related_tags custom_2="Berlin" form="sitemap_secondary" /><txp:smd_related_tags city="Berlin" form="sitemap_secondary" />

I’m not entirely sure what you want to achieve, but <txp:smd_related_tags> can compare any field in any context. Combined with tags-in-tags you should be able to tie your content in some pretty cool knots.

Look at the documentation for that tag’s match attribute. It defaults to comparing tag_name, but you’re not restricted to finding tags in that field:

<txp:if_custom_field name="genre">
    <txp:smd_related_tags match="genre">
        <txp:permlink><txp:title /></txp:permlink>
    </txp:smd_related_tags>
</txp:if_custom_field>

If you populate your custom field called “genre” with a tag name, that’ll go and find other articles with that tag. Heck you can pull out related files with the tag defined in your article’s custom field if you add type="file" to the above smd_related_tags.

Just remember that when you’re matching stuff like this it always matches the tag name not it’s title.


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

#399 2018-03-01 18:38:12

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 651
Website

Re: smd_tags: unlimited article, image, file and link taxonomy

Bloke wrote #309557:

<txp:if_custom_field name=“genre”> <txp:smd_related_tags match=“genre”> <txp:permlink><txp:title /></txp:permlink> </txp:smd_related_tags>
</txp:if_custom_field>

Ai. I didn’t realize smd-related_tags could be enclosing. And yes, name tag, not title tag. Thank you much!


a hole turned upside down is a dome, when there’s also gravity.

Offline

#400 2018-03-10 15:49:44

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 651
Website

Re: smd_tags: unlimited article, image, file and link taxonomy

EDIT: Solved. smd_related_tags needs to have match="tag_name" set to enable display of entries using multi worded tags. Original question below.

Sorry to ask this again, Stef.

on the tags_results page you set up for me i can see lists of articles belonging to a specific tag only, when the specific tag only consists of one word.

The tag Designer for instance gives me an article count first, followed by a list of articles per title, that is tagged with Designer. That’s expected behaviour.

_But strangely, when i use double worded tags, like Designer (company) or Producer (movie) etc.
then i get the article count only, and no list of articles, which are tagged like that. This goes for any tag, that is longer than one word._

Is that a bug or my coding inconsistency? EDIT: My coding inconstency ,)

Thank you much in advance!

Last edited by jayrope (2018-03-15 12:54:22)


a hole turned upside down is a dome, when there’s also gravity.

Offline

Board footer

Powered by FluxBB