Adding anchors and links to Wordpress

Discussion in 'Wordpress Support' started by Justin Smith, Oct 9, 2019.

  1. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    I have started transferring my site from Webplus to Wordpress and it`s a MASSIVE job, as I exected it to be. I`ve migrated nearly all the content and have just started reapplying all the links (same page, different page and external), it`s an absolute nightmare, and there are literally thousand of links, because Wordpress doesn`t seem to have method of easily finding an anchor which I have previously added.
    With Webplus you just highlighted the link text, clicked add link, it`d then bring up a list of pages, you choose the page you want to go to and it lists all the anchors on that page, you just click on the wanted link and it does all the rest. But Wordpress doesn`t seem to have anything like that, in fact I`ve been told that I have to manually add all the anchors then separately copy them somewhere (like a link database) and manually paste them in when I want to create a link, is that really the best I can hope for ? ! ?
     
    Posted: Oct 9, 2019 By: Justin Smith Member since: Jun 6, 2012
    #1
  2. fisicx

    fisicx It's Major Clanger! Staff Member

    32,360 9,573
    Wordpress does it in a similar way.

    highlight the anchor, click the link icon and enter the page title to find the link.

    But I’d run a database search and replace and do everything automatically
     
    Posted: Oct 9, 2019 By: fisicx Member since: Sep 12, 2006
    #2
  3. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    Thanks for that, but the problem I have is not linking to another page, it`s linking to an anchor on that page.
    Say I want to link to an anchor "Orange" which is half way down the page "Fruit", if I click on a term I want to convert to a link Wordpress, as you say, does bring up a potential list of pages, but not the anchors on that page. The only way I can do it is to select the page then manually add an anchor "#orange" to the end of it, having earlier created an ID for the widget (under attributes) and using that as the anchor. It`s that addition (#orange) which I`ve been advised I should store somewhere else so as to relatively quickly access it (by copy and paste). This is possible and does work but takes an absolute age compared to Webplus, where you could find any anchor (provided you know the page its on) and insert the link to it all in about 10 seconds.

    Or am I doing something wrong ?
     
    Posted: Oct 9, 2019 By: Justin Smith Member since: Jun 6, 2012
    #3
  4. Darren_Ssc

    Darren_Ssc UKBF Enthusiast Free Member

    861 228
    Yes, you have to add the anchors manually. Doing it in code view is easier but, with any new system, it'll take you a while to get used to it.

    Simpler answer is avoid using anchors if at all possible. :)
     
    Posted: Oct 9, 2019 By: Darren_Ssc Member since: Mar 1, 2019
    #4
  5. fisicx

    fisicx It's Major Clanger! Staff Member

    32,360 9,573
    If these anchors were already there when you imported the content there should be no need to add anything - the ID and links will not need to change. So I'm probably a bit confused about how you migrated from the old site to the new.

    Worth noting that if you have thousands in named anchors on the site the structure is probably wrong.

    I'd still run a script to automate at much as possible.
     
    Posted: Oct 9, 2019 By: fisicx Member since: Sep 12, 2006
    #5
  6. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    So you have to add the anchors manually, but is there then a quick way to find them when wanting to link you to them ?
     
    Posted: Oct 9, 2019 By: Justin Smith Member since: Jun 6, 2012
    #6
  7. fisicx

    fisicx It's Major Clanger! Staff Member

    32,360 9,573
    Not really.

    How did they get lost when you imported the data? If you dumped the old page content into a WP page/post it should all still be there.
     
    Posted: Oct 9, 2019 By: fisicx Member since: Sep 12, 2006
    #7
  8. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    The text was manually imported via a Word document to purposely remove all the HTML and start again. I would obviously have preferred not to have to have put all the anchors back in but, particularly as I`ve split many of the pages that was to be expected. What I didn`t expect was that there appears to be no easy way to make links to those anchors. If you have literally hundreds on your site you can`t possibly remember where they all are and Word doesn`t seem to have any way of making them easily accessible. Unless I`ve got this wrong Wordpress, even with the TinyMCE plugin, only seems designed to put in a link at the same time you`ve put the anchor in. That really surprises me.
    Surely I must be doing something wrong.......
     
    Posted: Oct 9, 2019 By: Justin Smith Member since: Jun 6, 2012
    #8
  9. fisicx

    fisicx It's Major Clanger! Staff Member

    32,360 9,573
    There was no need to do that. You could have just copied the content from the old site to the new then run some cleanup tools the clear out all the caggage.

    In fact there a lots of ways to automate the whole thing. Rather than spends days and days rebuilding everything, why not use an importer tool to do all the heavy lifting for you.
     
    Posted: Oct 9, 2019 By: fisicx Member since: Sep 12, 2006
    #9
  10. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    I`m unsure how much that would have helped as all eth text had to be moved about and many of the images adapted, that was the thing which took the time, as opposed to copying and pasting the text in which, relatively speaking, didn`t take that long.
    The big problem I have, and never expected to have, is linking to anchors, and you seem to be saying there is no answer to that, which surprises me greatly. There have got to be loads of crosslinks, that's one of the reasons the site is so popular, it's a bit like Wikipedia in that regard.
     
    Posted: Oct 10, 2019 By: Justin Smith Member since: Jun 6, 2012
    #10
  11. UKSBD

    UKSBD Not a real duck Staff Member

    9,964 1,942
    just because the place you want to link to isn't in the drop down of pages doesn't mean you can't still link there.
     
    Posted: Oct 10, 2019 By: UKSBD Member since: Dec 30, 2005
    #11
  12. fisicx

    fisicx It's Major Clanger! Staff Member

    32,360 9,573
    Not sure Wikipedia does have lots of anchors. There are menus but these are auto generated (you can do this with Wordpress) but very few anchors on the content.

    PS: auto generating page menus needs a script but it’s a simple task for a developer.
     
    Posted: Oct 10, 2019 By: fisicx Member since: Sep 12, 2006
    #12
  13. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    But how do you find the anchor and then enter it into the link ?
     
    Posted: Oct 10, 2019 By: Justin Smith Member since: Jun 6, 2012
    #13
  14. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    It isn`t a page menu I need.
    Say I write a new page, and on that page I want to put a load of links in the text (to explain terms I feel readers may be interested in, just like Wikipedia) how do I easily find where the anchors are and add them to the link.
     
    Posted: Oct 10, 2019 By: Justin Smith Member since: Jun 6, 2012
    #14
  15. fisicx

    fisicx It's Major Clanger! Staff Member

    32,360 9,573
    Wikipedia links externally. Very few links in the content are to on-page anchors.

    However....

    To do what you want you have to insert the links by hand.

    Or import the pages with all the anchors intact. It's still going to be the quickest way to do this. Once imported you can update images and split the content as necessary. As I said in an earlier posts, it's not difficult to do - just need a bit of preparation. For example, you can load the whole site into a CSV, edit and import to wordpress. This will create all your posts and pages with all the links intact.
     
    Posted: Oct 10, 2019 By: fisicx Member since: Sep 12, 2006
    #15
  16. UKSBD

    UKSBD Not a real duck Staff Member

    9,964 1,942
    Are you talking about on-page jump links?
    If so, you must know the text you used for them, so just add them manually
     
    Posted: Oct 10, 2019 By: UKSBD Member since: Dec 30, 2005
    #16
  17. fisicx

    fisicx It's Major Clanger! Staff Member

    32,360 9,573
    If you look at his site there are thousands of them. I could take weeks to manually create them all. Or an hour if you run an importer.
     
    Posted: Oct 10, 2019 By: fisicx Member since: Sep 12, 2006
    #17
  18. UKSBD

    UKSBD Not a real duck Staff Member

    9,964 1,942
    He said when he writes a new page.

    It sounds like he's just stripped the text and used that, a good opportunity to tidy things up and strip out 95% of them rather than just importing as it is.

    Almost defeats the object of updating if he's going to leave it as it is.
     
    Posted: Oct 10, 2019 By: UKSBD Member since: Dec 30, 2005
    #18
  19. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    I've also asked this question on the Wordpress forum and pretty much got the same answer, i.e. there is no easy way to add links to anchors in Wordpress. Someone did recommend a "plug in" link checker which I`d have thought is well worthwhile. You can use Xenu of course, but only (I think) after the website is published.
    The only positive I can think of is that adding links to anchors, esp on a large website, is so awkward that I don`t think many people would bother, thus my site will probably stay the best aerial information website !
     
    Posted: Oct 20, 2019 By: Justin Smith Member since: Jun 6, 2012
    #19
  20. Justin Smith

    Justin Smith UKBF Enthusiast Free Member

    613 61
    I tried the plug in link checker and it doesn`t work, certainly for anchors on a page, as opposed to links to a page. I deliberately put an incorrect anchor address in and the checker didn`t spot it.
     
    Posted: Nov 4, 2019 By: Justin Smith Member since: Jun 6, 2012
    #20