BlogTags with AJAX

Blog tags for plugin

Back to BlogTags with AJAX Support


Hi Surhaman,

thanks for this plugin! I was wandering how to correctly set the plugin to work with rainlab blog. We have a project and yet configured rainla blog correctly.

So we have a news page and news/Category to render the blog categories list and news/NewsPost to render the single post page. All routed correctly to work

Now in the single post page i inserted both {% component 'tags' %}{% component 'relatedPosts' %} but i have this error: [code]"SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ')) desc limit 5' at line 4 (SQL: select from rainlab_blog_posts where published is not null and published = 1 and published_at is not null and published_at < 2016-07-18 10:34:27 and id <> 3 and (select count() from rahman_blogtags_tags inner join rahman_blogtags_posts_tags on = rahman_blogtags_posts_tags.tag_id where rahman_blogtags_posts_tags.post_id = and 0 = 1) >= 1 order by ( select count(*) from rahman_blogtags_posts_tags where rahman_blogtags_posts_tags.post_id = and rahman_blogtags_posts_tags.tag_id in ()) desc limit 5)" [/code] Why? I shoud first create the tag page to render the single tag? And in the list of tags how can i create linked tags to redirect to single page as keios did here with tags cloud?

Thanks bye!

Last updated


Hi Gabtram,

Thanks for using my plugin and report that. I guess you didn't add any tag to your blog post before. But, it should fixed in the latest version (BlogTags v.1.0.7).

For second question, you can combine tags component and searchPosts component to do that. Here's my simple code,


title = "tags"
url = "/tags"
layout = "default"
is_hidden = 0

results = 0
sortOrder = "created_at desc"
{% set tags = tags.tags %}

    {% for tag in tags %}
    <li><a href="{{ 'tag'|page({ slug: tag.slug }) }}">{{ }}</a></li>    
    {% endfor %}


title = "tag"
url = "/tag/:slug/:page"
is_hidden = 0

slug = "{{ :slug }}"
pageNumber = "{{ :page }}"
postsPerPage = 10
postPage = "post"
sortOrder = "published_at desc"
{% component 'searchPosts' %}

Last updated

1-2 of 2