Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#361 2017-04-28 15:06:53

michaelkpate
Moderator
From: Avon Park, FL
Registered: 2004-02-24
Posts: 1,372
Website GitHub Mastodon

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

Bloke wrote #305538:

You’ll require the hidden feature that I forgot to document, d’oh.

Thanks again. This site is really coming together (and really dependent on some of your plugins to make it work).

Offline

#362 2017-12-30 10:47:38

jpdupont
Member
From: Virton (BE)
Registered: 2004-10-01
Posts: 752
Website

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

Error when installing on a new 4.7 dev site :

A problem occurred while loading the plugin: -> User_Error: Unknown column 'prefs_id' in 'field list' on line 410

Offline

#363 2017-12-30 11:58:26

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,566
Website GitHub

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

jpdupont wrote #308487:

Unknown column 'prefs_id' in 'field list' on line 410

Try this version.


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

#364 2017-12-30 12:40:07

jpdupont
Member
From: Virton (BE)
Registered: 2004-10-01
Posts: 752
Website

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

No more installation problem.

However, I installed the English textpack. It is not taken into account on my French Textpattern.

Offline

#365 2017-12-30 14:51:36

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,566
Website GitHub

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

jpdupont wrote #308493:

I installed the English textpack. It is not taken into account on my French Textpattern.

Umm, please explain why it should? If the pack you installed designated English as the target language, you will only get the strings installed in that language. If, however, you knock out the line that specifies the language, it will install in the current admin-side language.

Note that the Plugin Composer will wrongly use the front-end language in the current released version, so it’s advisable not to install plugins that way for now.


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

#366 2017-12-30 17:40:05

jpdupont
Member
From: Virton (BE)
Registered: 2004-10-01
Posts: 752
Website

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

Thank you, I understood and it works!

Offline

#367 2018-02-22 15:45:05

jpdupont
Member
From: Virton (BE)
Registered: 2004-10-01
Posts: 752
Website

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

I’m installing smd_tags on a 4.7 dev site and I want to select the tags in a textarea. In the editor, I get both a textarea and a multiselect list. See the screenshot below. When I click on an item in the textarea, I select an item from the list. I use smd_tags 0.6 beta1.

Offline

#368 2018-02-22 17:57:34

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,566
Website GitHub

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

Ack, thanks for the report. The 4.7.0 branch should fix this. I’d forgotten to bring in the style rules on the content pages.


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

#369 2018-02-22 20:10:54

jpdupont
Member
From: Virton (BE)
Registered: 2004-10-01
Posts: 752
Website

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

I uploaded the php file with Pugin Composer. Same problem.

Offline

#370 2018-02-22 20:30:28

jpdupont
Member
From: Virton (BE)
Registered: 2004-10-01
Posts: 752
Website

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

An error on my part, I just reload the file, and it’s perfect now! Thanks, Stef !

Offline

#371 2018-02-24 18:22:58

jpdupont
Member
From: Virton (BE)
Registered: 2004-10-01
Posts: 752
Website

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

Is it possible to list the tags of articles belonging to a well-defined section?

With the functions of smd_tags, I do not see how.
With a smd_query?
I have below a query that displays all the tags and articles that are marked by this tag. Possible to modify it? Or to use the new functions of the 4.7 dev in order to display only non empty tags (without article)?

<ul>
<!-- QUERY 1 = the TAGS -->
<txp:smd_query query='SELECT name AS parentName, title AS parentTitle, id AS parentID 
FROM smd_tags WHERE parent ="root" AND type = "article" AND name <> "root" ORDER BY title ASC' break="">
<li>{parentTitle}
<!-- QUERY 2 = ARTICLES -->
<txp:smd_query query='SELECT textpattern.Title, textpattern.Status, textpattern.ID, textpattern.Body,textpattern.Section FROM textpattern INNER JOIN smd_tags_used ON smd_tags_used.item_id = textpattern.id WHERE Status=4 AND smd_tags_used.tag_id = "{parentID}"  ' wraptag="dl" class="" break="">
<dt><a href='/{Section}/{ID}/{Title}'>{Title}</a></dt>
<dd>
<txp:smd_wrap_all transform="strip_tags, cut|200|20w|&hellip;">
{Body}
</txp:smd_wrap_all>&nbsp;
<a href='/{Section}/{ID}/{Title}'><span>More</span></a>
</dd>
</txp:smd_query>
</li>
</txp:smd_query>
</ul>

Offline

#372 2018-02-25 08:30:39

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,566
Website GitHub

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

jpdupont wrote #309416:

Is it possible to list the tags of articles belonging to a well-defined section?

Try something along the lines of this query:

SELECT tags.name, tags.title
FROM smd_tags_used AS tagu
LEFT JOIN smd_tags AS tags ON (tags.id = tagu.tag_id)
LEFT JOIN textpattern AS txp ON (tagu.item_id = txp.ID)
WHERE tagu.type = 'article'
AND txp.section = '<your section here>'

I think that gets you near where you want to be. Might need to add a clause for status='4' in there if you need to limit it to only published articles.


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

Board footer

Powered by FluxBB