Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2024-01-08 23:58:35

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

duplicate articles in admin page, not in mysql database. How to fix ?

As an example: one site it shows in my articles list in the admin area. txp version 4.8.8

article 10 FAQ

just below it

article 10 FAQ

Not all articles are duplicated. I downloaded the mysql file, went through it line by line, writing down the number of each entry as I slowly scrolled down.

No duplicates.

If I delete one of them, both go away.

Is there a way to fix this ? It is only happening on some of my installs/sub-domains.

Thank you.

Offline

#2 2024-01-09 21:32:41

etc
Developer
Registered: 2010-11-11
Posts: 5,157
Website GitHub

Re: duplicate articles in admin page, not in mysql database. How to fix ?

Weird. Might it be a plugin that interferes?

Offline

#3 2024-01-09 22:08:31

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: duplicate articles in admin page, not in mysql database. How to fix ?

Just checked, no plug-ins installed.

Offline

#4 2024-01-10 02:54:19

bici
Member
From: vancouver
Registered: 2004-02-24
Posts: 2,089
Website Mastodon

Re: duplicate articles in admin page, not in mysql database. How to fix ?

what happens if you create a new article.


…. texted postive

Offline

#5 2024-01-10 03:14:27

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: duplicate articles in admin page, not in mysql database. How to fix ?

I don’t think I’ve tried that. I’ll log into my desktop computer and check.

Offline

#6 2024-01-10 03:26:07

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: duplicate articles in admin page, not in mysql database. How to fix ?

It doesn’t create a duplicate.

I copied the FAQ article to another blank article, and it hasn’t duplicated.

But a quick look, I see about a hundred duplicates.

If I go to one that is a duplicate, and duplicate it, changing the title, it also has a duplicate.

Looks like I’ll have to copy and paste all of the duplicates into a write page, and see if that works. It will have to be Wednesday or Thursday to do that.

Last edited by JimJoe (2024-01-10 03:28:57)

Offline

#7 2024-01-10 03:31:26

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: duplicate articles in admin page, not in mysql database. How to fix ?

That’s strange, if I change the categories, 1 and 2, on one of the duplicates, one of them goes away. Only one now.

I tried this with two different articles that have duplicates, it worked.

edit: both category 1 and category 2 have to be changed to something else. Late here, so I’ll continue testing on Wednesday.

Thanks for the assist.

Last edited by JimJoe (2024-01-10 03:40:12)

Offline

#8 2024-01-10 03:53:19

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: duplicate articles in admin page, not in mysql database. How to fix ?

If I put the 2 categories back the way they were, I get duplicates again. I’m getting some sleep.

Offline

#9 2024-01-10 17:11:23

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: duplicate articles in admin page, not in mysql database. How to fix ?

I looked at my categories on the site, and noticed that over 90% of them were sub-categories under two of them.

I looked and saw I still have duplicates after I did a cpanel repair on the mysql database.

So at a wild guess, I changed the names of the two categories, shortening them. There must have been a cascade effect, or the repair finally took hold, the duplicates are gone.

I changed the two from 8 characters, to 5 characters. Northern Hemisphere to North Hemisphere. Southern Hemisphere to South Hemisphere. Both the names and the mysql entry using the Category listing in textpattern admin. Why that would get rid of duplicates, I have no idea.

Offline

#10 2024-01-10 17:30:39

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,436
Website GitHub

Re: duplicate articles in admin page, not in mysql database. How to fix ?

Sounds like the internal pointers got messed up somehow. When you make a change to any category field it rebuilds the entire tree, so that likely fixed it.

But quite why the articles were pointing to corrupt entries is the real mystery.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#11 2024-01-10 19:31:23

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: duplicate articles in admin page, not in mysql database. How to fix ?

I thought that is what happened.

Not sure why it was corrupted though.

Offline

#12 2024-01-10 21:24:42

etc
Developer
Registered: 2010-11-11
Posts: 5,157
Website GitHub

Re: duplicate articles in admin page, not in mysql database. How to fix ?

Bloke wrote #336337:

When you make a change to any category field it rebuilds the entire tree, so that likely fixed it.

That was true in 4.8.7, but took too much time (~1s per 1000 categories) on category-rich sites (some have >6000 categories). Now txp tries to modify only concerned nodes, which is much faster, but does not repair broken trees. One has to call rebuild_tree_full() php function to this end.

But quite why the articles were pointing to corrupt entries is the real mystery.

Absolutely.

Offline

Board footer

Powered by FluxBB