Jump to content

Advanced Tags & Prefixes - IPS 4.x


Ryan H.

Recommended Posts

6 hours ago, jair101 said:

Not sure if anyone asked before, but have you considered integrating it with Rules App? Possible uses:

- automatic tagging/prefixing based on number of replies - similar to the HOT feature, but much more flexible

- automatic tagging/prefixing based on members taking part in the conversation. Lets say "elite topic" for topics where X participants are from Elite group.

- automatic tagging/prefixing based on number of people currently reading a topic. 

Etc. My examples might sound stupid, but I am just try to communicate the idea. Integration with Rules could be very powerful. 

My understanding is Rules already supports adding of tags/prefixes, in which case no further work should be necessary. I could be mistaken. I can't speak to the specific rule examples you've mentioned, those would be on that app rather than mine.

Link to comment
Share on other sites

On 09/11/2016 at 5:10 AM, Ryan H. said:

I spent a while exploring it. Found the source of the error, but not a solution that doesn't break AT&P in the process. There's some really bizarre behavior going on with the IPS core here. I reached out to someone about it.

Any news about this?

Link to comment
Share on other sites

  • 3 weeks later...

Hey Ryan, I'm about to start using the app heavily and wanted to check on this message I got via the Support tool in the ACP:

Quote

ALTER TABLE `forums_forums` CHANGE COLUMN `require_prefix` `require_prefix` TINYINT NULL DEFAULT 0 COMMENT 'AT&P: Require a prefix'

ALTER TABLE `forums_forums` CHANGE COLUMN `show_prefix_in_desc` `show_prefix_in_desc` TINYINT NULL DEFAULT 0 COMMENT 'AT&P: Show prefixes on index'

ALTER TABLE `forums_topic_mmod` CHANGE COLUMN `topic_prefix` `topic_prefix` INT NULL DEFAULT -1 COMMENT 'AT&P: Topic prefix'

I'm posting it here because it mentions prefix so just wanted to check if you think it is something to do with the app? I have the option to 'Fix Automatically' but wanted to check first just in case.

Link to comment
Share on other sites

On 12/4/2016 at 11:07 AM, Jujuwar said:

(post)

:wub:

On 12/4/2016 at 0:25 PM, Simon Woods said:

When it says delete tags "in bulk" does that include all-at-once? Or does it mean something else?

I'm not entirely sure what you're referring to. The app listing description? There's a tag manager tool that allows you to view all tags, from which you can edit or delete all instances of a given tag/prefix at once.

Link to comment
Share on other sites

1 minute ago, Ryan H. said:

I'm not entirely sure what you're referring to. The app listing description? There's a tag manager tool that allows you to view all tags, from which you can edit or delete all instances of a given tag/prefix at once.

Yep, that's what I thought! I was wondering if there was a "delete all tags at once" option but that seems to be a mechanism that is lacking across IPS4 as a whole.

Link to comment
Share on other sites

1 minute ago, Simon Woods said:

Yep, that's what I thought! I was wondering if there was a "delete all tags at once" option but that seems to be a mechanism that is lacking across IPS4 as a whole.

Not directly, no. It could be accomplished with a few manual queries, but that's pretty technical. Otherwise, you'll just be clicking those delete buttons a bunch of times.

(Generally, exposing a 'destroy everything' button doesn't make for good user experience. Somebody, somewhere, is going to click it...)

Edited by Ryan H.
Link to comment
Share on other sites

8 hours ago, Jujuwar said:

Hello,

With the new update 4.1.17, I've a problem with this application. It displays an empty tag on every topic I view

Must be a conflict with the new tagging changes... I'll have to investigate. I haven't tried .17 yet. I don't have any immediate solution.

Link to comment
Share on other sites

I just installed this application and I'm trying to clean up the tags using the Manage Tags page.  I'm experiencing several issues, however:

  • Most of the tags I try to delete are not deleted.
  • Most of the tags I try to edit name are not edited.
  • I have 1441 pages of tags, but only 207 have tags (the remaining are empty, and every time I run the Advanced Tool to add tags to topics, the number of empty pages increases).

Are there any logs where I can check for errors?

Link to comment
Share on other sites

I think I found the cause of the first two issues: some special characters are being encoded twice.

For example, the tag @media has a delete URL containing the parameter "tag=%2540media", which won't work, but if change it to "tag=%40media" it already works.

Edited by ptprog
Link to comment
Share on other sites

1 hour ago, ptprog said:

I think I found the cause of the first two issues: some special characters are being encoded twice.

For example, the tag @media has a delete URL containing the parameter "tag=%2540media", which won't work, but if change it to "tag=%40media" it already works.

Ah, I've had similar reports from others with spaces going wonky. Be careful with any such tags until that's fixed, particularly with the mass-add tool. I can't give an estimate just now, I'm afraid.

Link to comment
Share on other sites

10 hours ago, Ryan H. said:

:mellow: Awesome. I can't imagine how.

I take a look at that and the difference is that when  Advanced Tags & Prefixes is enabled the <span> of prefix contains the template Core > Global > Prefix 

{{if $text}}
	<a href="{url="app=core&module=search&controller=search&tags={$encoded}" seoTemplate="tags"}" title="{lang="find_tagged_content" sprintf="$text"}" class='ipsTag_prefix'><span>{$text}</span></a>
{{endif}}

This template was update in .17, to add the condition {{if $text}}

And when I disable the app, the span doesn't contains this link.

This template is called in Forums > Topics > Topic at line 70

{{if $topic->prefix() OR ( $topic->canEdit() AND $topic::canTag( NULL, $topic->container() ) AND $topic::canPrefix( NULL, $topic->container() ) )}}
	<span {{if !$topic->prefix()}}class='ipsHide'{{endif}} {{if ( $topic->canEdit() AND $topic::canTag( NULL, $topic->container() ) AND $topic::canPrefix( NULL, $topic->container() ) )}}data-editablePrefix{{endif}}>
  		{template="prefix" group="global" app="core" params="$topic->prefix( TRUE ), $topic->prefix()"}
	</span>
{{endif}}

In the prefix template, $text is the second parameter :p 

Hope this will help you!

 

Link to comment
Share on other sites

Any attempt to resync the cache and get proper badges in the topic list results in this error:

SELECT DISTINCT `tag_aai_lookup`, `tag_meta_app`, `tag_meta_area`, `tag_meta_id` FROM `core_tags` ORDER BY `tag_id` ASC LIMIT 0,100
IPS\Db\Exception: Expression #1 of ORDER BY clause is not in SELECT list, references column 'support.core_tags.tag_id' which is not in SELECT list; this is incompatible with DISTINCT (3065)
#0 /home/support/public/system/Db/Select.php(346): IPS\_Db->preparedQuery('/*IPS\\advancedt...', Array)
#1 /home/support/public/system/Db/Select.php(408): IPS\Db\_Select->runQuery()
#2 /home/support/public/applications/advancedtagsprefixes/modules/admin/manage/tools.php(276): IPS\Db\_Select->rewind()
#3 [internal function]: IPS\advancedtagsprefixes\modules\admin\manage\_tools->rebuild()
#4 /home/support/public/system/Dispatcher/Controller.php(85): call_user_func(Array)
#5 /home/support/public/applications/advancedtagsprefixes/modules/admin/manage/tools.php(26): IPS\Dispatcher\_Controller->execute()
#6 /home/support/public/system/Dispatcher/Dispatcher.php(129): IPS\advancedtagsprefixes\modules\admin\manage\_tools->execute()
#7 /home/support/public/3uskbvr1xqi24czhwy51/index.php(13): IPS\_Dispatcher->run()
#8 {main}

It appears someone reported this exact problem before and it seems to be related to MySQL 5.7 almost a year (!) ago. Is there any way to fix it?

Link to comment
Share on other sites

3 hours ago, Emsi said:

Any attempt to resync the cache and get proper badges in the topic list results in this error:


SELECT DISTINCT `tag_aai_lookup`, `tag_meta_app`, `tag_meta_area`, `tag_meta_id` FROM `core_tags` ORDER BY `tag_id` ASC LIMIT 0,100
IPS\Db\Exception: Expression #1 of ORDER BY clause is not in SELECT list, references column 'support.core_tags.tag_id' which is not in SELECT list; this is incompatible with DISTINCT (3065)
#0 /home/support/public/system/Db/Select.php(346): IPS\_Db->preparedQuery('/*IPS\\advancedt...', Array)
#1 /home/support/public/system/Db/Select.php(408): IPS\Db\_Select->runQuery()
#2 /home/support/public/applications/advancedtagsprefixes/modules/admin/manage/tools.php(276): IPS\Db\_Select->rewind()
#3 [internal function]: IPS\advancedtagsprefixes\modules\admin\manage\_tools->rebuild()
#4 /home/support/public/system/Dispatcher/Controller.php(85): call_user_func(Array)
#5 /home/support/public/applications/advancedtagsprefixes/modules/admin/manage/tools.php(26): IPS\Dispatcher\_Controller->execute()
#6 /home/support/public/system/Dispatcher/Dispatcher.php(129): IPS\advancedtagsprefixes\modules\admin\manage\_tools->execute()
#7 /home/support/public/3uskbvr1xqi24czhwy51/index.php(13): IPS\_Dispatcher->run()
#8 {main}

It appears someone reported this exact problem before and it seems to be related to MySQL 5.7 almost a year (!) ago. Is there any way to fix it?

What version of AT&P are you running?

Link to comment
Share on other sites

For the issue with tags not deleting, is there any fix for that? Or do I hold onto the unwanted tags until a fix can be done?

Also, when tag deletion works I get taken back to the first page of my tags after each deletion. Is it supposed to do that? That is a particularly unfriendly way to do anything in bulk.

Edited by Simon Woods
Link to comment
Share on other sites

13 hours ago, Simon Woods said:

For the issue with tags not deleting, is there any fix for that? Or do I hold onto the unwanted tags until a fix can be done?

Also, when tag deletion works I get taken back to the first page of my tags after each deletion. Is it supposed to do that? That is a particularly unfriendly way to do anything in bulk.

No fix available yet.

I'll look at the post-delete/edit redirect, but that's not a bug.

4 minutes ago, Emsi said:

3.1.7 according to the applications list. I just bought and downloaded it from the marketplace yesterday. IPS version is 4.1.17.1.

Okay. I'll have to look and get back to you.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...