Jump to content

Tag cloud documentation


jakesmalley

Recommended Posts

WHMCS v7.4.2

I'm trying to get the tag cloud to show all tags when in the ticket list / admin area. It only shows one tag and it's huge. I cannot find any documentation on how to work with this, looked through newer version changelogs to see if something was addressed. I've tried removing all unnecessary elements such as advanced search and the support center link list from the admin sidebar.

This is the code in sidebar.tpl 

{if $inticketlist}

<span class="header"><img src="images/icons/tickets.png" alt="Tag Cloud" width="16" height="16" class="absmiddle" /> {$_ADMINLANG.support.tagcloud}</span>
<div class="tagcloud"> {$tagcloud} </div>

{/if}

 

If someone can point me into the right direction, that would be appreciated. My only concern is displaying all of the tags in the sidebar so I don't have to create menu links each time one is created.

 

 

Link to comment
Share on other sites

28 minutes ago, jakesmalley said:

I cannot find any documentation on how to work with this, looked through newer version changelogs to see if something was addressed.

had a quick look, but could only find the link below.... t

https://docs.whmcs.com/Support_Tickets#Ticket_Tags.2FTag_Cloud

Quote

The Ticket Tags/Tag Cloud functionality is designed to link tickets that have a common item (for example: all reporting the same issue). For example, this could be used to save a case ID from an external system for example in case you wish to follow up with those tickets once it is marked as resolved. To find all the tickets linked to the tag, please use the same name for the tag and then search by tag from the Search/Filter option on the ticket list page. It should bring up the list of tickets linked to the tag and the results can be used as desired.

here may well be other documentation, but if there is, I don't remember reading it!

30 minutes ago, jakesmalley said:

If someone can point me into the right direction, that would be appreciated.

if you click on an existing ticket in supporttickets.php, you should see the following in the sidebar...

Q5wcrj8.png

enter your tag, click on the "Add xxx" button and it should add the tag to the ticket... and when you return to the main support ticket page, the tagcloud should be updated.

oTfzTb0.png

Link to comment
Share on other sites

Thanks for the response. 

My issue is that despite there being multiple tags created, only a single tag is shown on the sidebar, as attached.

It's possible that in sidebar.tpl, $tagcloud is a single value, not an array. I'm not that familiar with php, but I stuck $tagcloud in a foreach loop and it still only spit out the 'frontoffice' tag, not the rest of the tags.

I'm really looking for developer documentation on the tag cloud function, but I can't find it there or in the forums or through Google / Bing / Yahoo / Yandex searches. 

Because of the name, I expect it to display a cloud of words, not just a single word, and I am not seeing that behavior. 

 

 

 

 

single_tag_cloud.png

Link to comment
Share on other sites

1 hour ago, jakesmalley said:

My issue is that despite there being multiple tags created, only a single tag is shown on the sidebar, as attached.

i'm not seeing that locally....

KO9sHGw.png

1 hour ago, jakesmalley said:

It's possible that in sidebar.tpl, $tagcloud is a single value, not an array. I'm not that familiar with php, but I stuck $tagcloud in a foreach loop and it still only spit out the 'frontoffice' tag, not the rest of the tags.

it is a html string, not an array - so there's nothing to loop through.

E0HMEZR.png

1 hour ago, jakesmalley said:

I'm really looking for developer documentation on the tag cloud function, but I can't find it there or in the forums or through Google / Bing / Yahoo / Yandex searches. 

as I said previously, I don't think it currently exists.

1 hour ago, jakesmalley said:

Because of the name, I expect it to display a cloud of words, not just a single word, and I am not seeing that behavior. 

it should do.

jc0EOaf.png

it might be worth noting the v7.7 changelog

Quote

CORE-8228 - Ensure ticket tag cloud aggregates regardless of status (Also known as: CORE-12894)

everything above that i'm doing is on v7.8.3, so that's probably why it's working for me and not you.

short of upgrading, I suspect the only other option would be a hook to rewrite that string - I imagine that it's count of the tbltickettags database table and then assigning font sizes based on the counts of each tag.

Edited by brian!
Link to comment
Share on other sites

I guess I didn't understand the changelog, but what you've mentioned is helpful.  In some template file there's a foreach ($something as $somethingelse), which I thought meant $string could be an array as well.

We have a lifetime license and updating isn't my call, unfortunately.  But, your suggestion at the end, I can work with that.  I didn't think about creating my own function to deal with it.

Thank you for the help.

 

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.

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated