Advertisement

Tags: What is contentitem_tag_map field core_content_id ?

Need help with the Administration of your Joomla! 3.x site? This is the spot for you.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Locked
User avatar
phidias81
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Thu Dec 15, 2011 11:44 pm
Contact:

Tags: What is contentitem_tag_map field core_content_id ?

Post by phidias81 » Wed Nov 19, 2014 10:16 am

Hello, I have to export the tags from a previous component to the standard joomla 3.3 tags system. When I use the script to export the tags, all of the core_content_id inside contentitem_tag_map has empty value, so that I'm filling it manually. I've tried to understand the logic behing this value, but I couldn't completely. I just see that they are consecutive numbers, and that tags in the same article get the same number. But this is not all, because if I fill consecutive numbers in consecutive rows theorugh phpmyadmin, in example 1,2,3,4....X if then I insert a new tag from joomla in a article and I verify for the new line created in the database, I would expect it to be a new number, but instead the number (in my case 4) is the same as one already assigned to a different article (not same article ID).
So how should I fill this field not to create problems?

Also if I fill the numbers as I did, and then from the frontpage I click on a tag X, the tag search result is giving wrong result, in example article Y, that doesn't have Tag x. But if I click on article Y, then it is actually opening article Z that is containing Tag X.
I guess it might be related to the wrong filling of the field.
At Nomad Travellers you find my travel stories, unusual places and amazing photos: visit my new website and travel from your chair! Make yourself comfortable and start your Nomad Travel! http://www.nomadtravellers.com/

Advertisement
User avatar
phidias81
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Thu Dec 15, 2011 11:44 pm
Contact:

Re: Tags: What is contentitem_tag_map field core_content_id

Post by phidias81 » Fri Nov 21, 2014 5:33 am

Any help?
At Nomad Travellers you find my travel stories, unusual places and amazing photos: visit my new website and travel from your chair! Make yourself comfortable and start your Nomad Travel! http://www.nomadtravellers.com/

SharkyKZ
Joomla! Virtuoso
Joomla! Virtuoso
Posts: 3131
Joined: Fri Jul 05, 2013 10:35 am
Location: Parts Unknown

Re: Tags: What is contentitem_tag_map field core_content_id

Post by SharkyKZ » Fri Nov 21, 2014 7:54 am

Don't know how to explain it clearly, but it goes something like this:

core_content_id is assigned to an item when you use tags on it. The same item has the same core_content_id, regardless of how many tags you use.

For example. If you have an article with 2 tags, it will have two rows in the table. core_content_id will be the same, but tag_id will be different depending on the tags.

Another example. Let's say you have 3 articles (ids 1,2,3), one has 2 tags (ids 1 and 4), another has no tags and the third has 2 tags (ids 1 and 6). The table will look like this:

core_content_id | content_item_id | tag_id

1 | 1 | 1
1 | 1 | 4
2 | 3 | 1
2 | 3 | 6

User avatar
phidias81
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Thu Dec 15, 2011 11:44 pm
Contact:

Re: Tags: What is contentitem_tag_map field core_content_id

Post by phidias81 » Fri Nov 21, 2014 11:05 am

Thank you for the explanation! My problem is actually at the next step. Because if I fill in the field core_content_id respecting this correlation, it is still not enough. In example after filling in the field in the database, I inserted new tags in an article through joomla, and it used the same core_content_id as a different article. And also the tag search results are wrong. There are probably other criteria, but I don't know where to find them
At Nomad Travellers you find my travel stories, unusual places and amazing photos: visit my new website and travel from your chair! Make yourself comfortable and start your Nomad Travel! http://www.nomadtravellers.com/

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Tags: What is contentitem_tag_map field core_content_id

Post by sovainfo » Fri Nov 21, 2014 2:18 pm

Suggest to have a look at the #__ucm_* tables. As soon as you add a tag to an article that article is referenced in #__ucm_content, the core_content_id it gets there needs to be used in contentitem_tag_map.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

User avatar
NosyWeb
Joomla! Apprentice
Joomla! Apprentice
Posts: 28
Joined: Fri Nov 12, 2010 3:05 pm
Contact:

Re: Tags: What is contentitem_tag_map field core_content_id

Post by NosyWeb » Thu Mar 24, 2016 4:08 pm

Hello phidias81,

From which component you had to export tags to the standard Joomla ?
I need to do it from PowerTags, not easy... :-(

Thanks for your help.

Regards.
My french Joomla! Magazine : http://www.nosyweb.fr

User avatar
phidias81
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Thu Dec 15, 2011 11:44 pm
Contact:

Re: Tags: What is contentitem_tag_map field core_content_id

Post by phidias81 » Sun Mar 27, 2016 10:45 am

Hello, I sincereley don't remember anything because it was a very specific thing, and 2 years ago!
I just remember I had to do everything manually I couldn't manage to fully automate the thing
At Nomad Travellers you find my travel stories, unusual places and amazing photos: visit my new website and travel from your chair! Make yourself comfortable and start your Nomad Travel! http://www.nomadtravellers.com/

User avatar
NosyWeb
Joomla! Apprentice
Joomla! Apprentice
Posts: 28
Joined: Fri Nov 12, 2010 3:05 pm
Contact:

Re: Tags: What is contentitem_tag_map field core_content_id

Post by NosyWeb » Mon Mar 28, 2016 8:54 am

Hello,

OK, thanks for your reply :-)
My french Joomla! Magazine : http://www.nosyweb.fr

Advertisement

Locked

Return to “Administration Joomla! 3.x”