We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 53127
    • 15 Posts
    Sorry if this is in the wrong place but I need some help with images and the ampify extra...

    I have a site setup using ampify and a snippet to pull images out of content and re wrap them with the correct amp version img tags. That all works great and all pages show with text content correctly, however the image urls are "naked" and I assume because the amp page urls include /amp/ the image root is technically wrong.

    Anyone have this happen to them as well or have any idea how to fix/address it?


    You can see what I mean here: https://brooksvillewebdesign.com/amp/about-brooksville/

    Right above the text "At pure we dont play games" should be the image "/img/games.png" however instead of the url, https://brooksvillewebdesign.com/img/games.png it shows as https://brooksvillewebdesign.com/amp/about-brooksville/img/games.png

    That enough info? Can anyone help? Thank you.
      • 17301
      • 932 Posts
      Do you have this in your amp template?

      <link rel="canonical" href="[[~[[*id]]? &scheme=`full`]]" />
        ■ email: [email protected] | ■ website: https://alienbuild.uk

        The greatest compliment you can give back to us, is to spend a few seconds leaving a rating at our trustpilot: https://uk.trustpilot.com/review/alienbuild.uk about the service we provided. We always drop mention of services offered by businesses we've worked with in the past to those of interest.
        • 53127
        • 15 Posts
        I do. Actually a light bulb went off and I realized I didn't have the base meta set which fixed *some of the images!!! However now google amp says the base property is invalid!!? How do I get around that one?

        Thanks for the help.
          • 17301
          • 932 Posts
          That's ok but sorry if I'm not much help I investigated this when the extra was first released but it's the only time I've used it so my knowledge of it isn't great.

          I assume you're running in context mode though - do you have the system setting setup for amp_context and amp_url_param? Can you establish any pattern between the images that do work and the ones that don't?
            ■ email: [email protected] | ■ website: https://alienbuild.uk

            The greatest compliment you can give back to us, is to spend a few seconds leaving a rating at our trustpilot: https://uk.trustpilot.com/review/alienbuild.uk about the service we provided. We always drop mention of services offered by businesses we've worked with in the past to those of interest.
            • 53127
            • 15 Posts
            I do and again everything is working correctly apart from some images (within the [[*content]] call) showing correctly.
              • 17301
              • 932 Posts
              Any luck if you put /amp/ at the end of your base href?
                ■ email: [email protected] | ■ website: https://alienbuild.uk

                The greatest compliment you can give back to us, is to spend a few seconds leaving a rating at our trustpilot: https://uk.trustpilot.com/review/alienbuild.uk about the service we provided. We always drop mention of services offered by businesses we've worked with in the past to those of interest.
                • 53127
                • 15 Posts
                Seeing as you have to setup the context as {base_url}amp/ - I don't think that's possible...