ID to the tag assignment

Post Reply
mahmut
Ssr. Bludit
Posts: 24
Joined: Fri Feb 12, 2016 2:27 pm

Hello , how can you do want to assign to the tag ID ?
User avatar
diego
Site Admin
Posts: 773
Joined: Sat May 16, 2015 2:53 pm
Been thanked: 1 time
Contact:

This is a question or an idea ?
mahmut
Ssr. Bludit
Posts: 24
Joined: Fri Feb 12, 2016 2:27 pm

diego wrote:This is a question or an idea ?
Thank you. This is a question .
User avatar
Edi
Site Admin
Posts: 3121
Joined: Sun Aug 09, 2015 5:01 pm
Location: Zurich
Has thanked: 54 times
Been thanked: 77 times
Contact:

What exactly do you want to do? Can you please give an example.
Clickwork - Websites mit Bludit | Planet Bludit - Tipps und Snippets
mahmut
Ssr. Bludit
Posts: 24
Joined: Fri Feb 12, 2016 2:27 pm

Edi wrote:What exactly do you want to do? Can you please give an example.
Oky,

I want to assign CSS was created to each tag.

Example:

Code: Select all

<div class="tag-id-1"><li><a href="#">Example tags 1</a></li></div>
<div class="tag-id-2"><li><a href="#">Example tags 2</a></li></div>
<div class="tag-id-3"><li><a href="#">Example tags 3</a></li></div>
Thanks.
User avatar
Edi
Site Admin
Posts: 3121
Joined: Sun Aug 09, 2015 5:01 pm
Location: Zurich
Has thanked: 54 times
Been thanked: 77 times
Contact:

If you want add a class for example to the plugin Tags list why not like this (line 73):

Code: Select all

		foreach($tagArray as $tagKey=>$fields)
		{
			// Print the parent
			$html .= '<div class="tag-'.$fields['tagKey'].'"><li><a href="'.HTML_PATH_ROOT.$filter.'/'.$fields['tagKey'].'">'.$fields['name'].' ('.$fields['count'].')</a></li></div>';
		}
By the way: I would a class not give a name with "id". ;-)
Clickwork - Websites mit Bludit | Planet Bludit - Tipps und Snippets
mahmut
Ssr. Bludit
Posts: 24
Joined: Fri Feb 12, 2016 2:27 pm

Edi wrote:If you want add a class for example to the plugin Tags list why not like this (line 73):

Code: Select all

		foreach($tagArray as $tagKey=>$fields)
		{
			// Print the parent
			$html .= '<div class="tag-'.$fields['tagKey'].'"><li><a href="'.HTML_PATH_ROOT.$filter.'/'.$fields['tagKey'].'">'.$fields['name'].' ('.$fields['count'].')</a></li></div>';
		}
By the way: I would a class not give a name with "id". ;-)
You 're a great brother! Thank you. So how can you answer my other question?

viewtopic.php?f=6&t=629
Post Reply