• I had a website with all the links working, but I wanted to change domains and I was getting interference from the domain registrars so I worked on other things for about 10 weeks, then when they fixed their end and I went back it was difficult to recall just how all the options were set. I had using Libre Writer to export .docx files for text and the Mammoth plugin to convert them to HTML which had been working great, put a bunch of paragraphs over a cover block with an image. When I went back the external links were still working fine but every time I clicked on an internal link it would “throw me into edit mode” (which of course means my customers were being asked to log into my site to continue which of course they couldn’t do, making me look like a total doofus). When I looked at the link structure for the internal links they actually looked like a full URL with “action=edit” inside them. Why would the anchor links have a full URL when all they need is the name of the target, and just stay totally inside the HTML structure? No wonder the customer was being thrown somewhere they didn’t want to be! The documentation strongly SUGGESTS to fix this I should edit the URL, but why would it be creating a structure that is going beyond HTML at all? Can anyone answer what’s going ape at the system level so I’m not futilely trying to fix a string that’s encoded at a level where it doesn’t belong to begin with, and probably gets the offensive parts of the string put back relentlessly as soon as I think I might have fixed it? (Please don’t say “clean the cache” or something, I already nailed all the obvious bits.) Is this issue somewhere I’m not even thinking of looking like inside the theme or something? Remember I wasn’t changing all that much here…

Viewing 9 replies - 1 through 9 (of 9 total)
  • When I went back the external links were still working fine but every time I clicked on an internal link it would “throw me into edit mode” (which of course means my customers were being asked to log into my site to continue which of course they couldn’t do, making me look like a total doofus). When I looked at the link structure for the internal links they actually looked like a full URL with “action=edit” inside them. Why would the anchor links have a full URL when all they need is the name of the target, and just stay totally inside the HTML structure??

    Hi, it is very likely the internal URL added to the article is of the editor page of that article ( it may also have a /wp-admin within it), instead of the actual page.

    If you authored that article, make sure you open the actual page in an incognito window ( to be safe you are not accessing an edit page ) , and then copy that URL to use within the link.

    Thread Starter jefflawton

    (@jefflawton)

    Sorry not close. I didn’t “edit the links in” from the internal editor. There shouldn’t be a full URL anywhere near anchor links created like that, the link exists inside the file when it’s in .docx and they should (and do) get properly translated into HTML. It’s only when the document is copied into the cover block and made into individual paragraphs and then the document goes online that the URLs for anchor links come into the picture, and I don’t know why or where they are coming from.

    Thread Starter jefflawton

    (@jefflawton)

    OK let me reconsider my previous post, there’s a pile of Github bug reports about the Gutenberg editor and regex bugs, apparently it “feels obligated to” convert internal HTML anchor links to full-throated URLs, which would be fine if it didn’t stumble all over the place adding all manner of extra pieces in there about wp-admin, edit mode etc. So I finally figured out how to invoke the HTML-mode editor, and somehow I can’t quite get away just editing them down to simple anchor links, nor can I just “throw away” what look to be the non-essential pieces because edit mode isn’t the same as display. I wind up with the puzzle of figuring out what the exact path for a full URL has to look like and letter-for-letter “getting it right” or all I get for my trouble is “there doesn’t seem to be anything where your link is pointing to”. Can anyone please get me a “cheat sheet” for EXACTLY what the full path of the URL equivalent of a simple anchor link for a particular page in WordPress looks like before I go stark raving crazy here? Thank you!

    Sorry for not understanding this adequately earlier. From what I see, the internal links created within the Libre office document are not translating to correct internal links within a WordPress block where you copy the content. Am I right?

    You may need to create these internal anchor links using the steps here .

    Can anyone please get me a “cheat sheet” for EXACTLY what the full path of the URL equivalent of a simple anchor link for a particular page in WordPress looks like

    Once the link is created it would look like https://yourwebsite.com/page-name#anchor-link-name

    • This reply was modified 1 year, 1 month ago by Nagesh Pai.
    • This reply was modified 1 year, 1 month ago by Nagesh Pai.
    Thread Starter jefflawton

    (@jefflawton)

    I’m really confused now, “anchor links” (strictly internal) as documented SHOULD work but for some reason they don’t, please does anyone know why that is? Also if you just wanted to “link” to the actual page with a full URL OUTSIDE OF edit mode you can’t actually do that directly, since the individual pages aren’t really part of the file structure, they’re really sitting INSIDE the database…now there MIGHT be a “stunt” that would make that work but I certainly don’t know what that stunt is…I even put in the plugin “Broken link checker” and it says all these “edit mode” links are just FINE mode 200 links, but they’re actually USELESS if you’re not an admin! I guess there’s supposed to be a way to delete my links and recreate them, but I think that just recreates the “edit mode” links all over again, and I can’t seem to identify the editing mode that’s supposed to recreate the “make a full URL anchor link” solution CORRECTLY…am I REALLY the only person having this problem??

    In other words at the heart of all this is, am I expected to “fix” all these “edit mode” links MANUALLY and not simply recreate them, or is it that this OUGHT to work but somehow I’ve done something that’s “activating this bug” and there’s a need to fix THAT? Please give this a bit of thought, I’m trying everything I can find and so far I am finding no practical solution at all for fixing on-page links, thank you!!

    • This reply was modified 1 year, 1 month ago by jefflawton.
    • This reply was modified 1 year, 1 month ago by jefflawton.
    Thread Starter jefflawton

    (@jefflawton)

    I’m reading as much about this as I can, with the help of Google Search. It’s well-known that in some circumstances JavaScript routines (particularly those using jQuery) have been known to break anchor links (usually trying to make smooth scroll work), and SOMETIMES these are invoked from inside various themes. My default theme was “Hello Elementor” (no I wasn’t using Elementor itself), but I’ve tried a few of the “Twenty” themes and no luck yet. My “block stack” is pretty sparse, I just have a cover block into which I “poured” (copy/pasted) the output of Mammoth and it created a bunch of blocks for paragraphs and headings and a few lists, I didn’t precede all that with a “columns” block because it didn’t seem necessary. My plugins are also pretty minimal, it’s the current versions of coming soon page, duplicate page, Jetpack, Mammoth, WPTouch and 3 Siteground plugins. Isn’t there some fairly simple way to at least figure out what broke the actual anchor links, which I would have fairly quickly edited back in if they had been working, and not bother trying to figure out where the “edit mode” stuff came from? It doesn’t seem like trying to make URLs work as page links is likely to work if the pages aren’t actually present in the file structure, but maybe that makes sense to someone who understands the whole picture better than I do.

    • This reply was modified 1 year, 1 month ago by jefflawton.
    • This reply was modified 1 year, 1 month ago by jefflawton.
    Thread Starter jefflawton

    (@jefflawton)

    FWIW when I manually edit both the link and the target header I look in the lower left corner and as I hover over the link I see the site URL and a slash followed directly by the tag name, but clicking on the link creates no motion or indication at all, I don’t know what’s missing!

    Thread Starter jefflawton

    (@jefflawton)

    Also all the links that I “try to fix” as normal anchor links result in no motion and are reported by Broken Link Checker as broken, but the ones that only force me (and my viewers) into edit mode according to BLC are all FINE. Isn’t that, uh, just about totally backwards, or doesn’t anyone else think so??

    Thread Starter jefflawton

    (@jefflawton)

    OK I don’t really care for its format, I had a great deal more control of THAT in the original Libre Office Writer, but since there just isn’t any support of the .docx -> HTML (via Mammoth) “anchor links” premise any more, I “caved in”, went over to the dark side and am using “Easy TOC”, because outside of the 3 common plugins it’s just not possible to make anything else work anymore…

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Trouble with internal links’ is closed to new replies.