Home > database >  Published Google Sheet not showing in embedded iframe
Published Google Sheet not showing in embedded iframe

Time:03-23

I have published a Google Sheet and have modified the iframe embedded on my website to show a certain range of cells only. I am pretty sure the modification has been done correctly, yet when the iframe is embedded, I am getting the error seen in the screenshot Google Sheet. The iframe used is the following:

<iframe src="https://docs.google.com/spreadsheets/d/e/xxxxx-1vTvQphG_8AomL4TacudrbUYMRlWuL_nITRnPMBeVEOz8bJ6y-3DXFdCqmZ7io9wgyvi6eEBl7Dju2qT/pubhtml?gid=1922308330$amp;widget=true&amp;headers=true&amp;chrome=false&amp;range=A1:B1" style="border:1px solid gray;" width="500" height="600"></iframe>

What am I doing wrong?

CodePudding user response:

There is $ between gid and amp in the link, it should be &

Change your code from:

<iframe src="https://docs.google.com/spreadsheets/d/e/xxxxx-1vTvQphG_8AomL4TacudrbUYMRlWuL_nITRnPMBeVEOz8bJ6y-3DXFdCqmZ7io9wgyvi6eEBl7Dju2qT/pubhtml?gid=1922308330$amp;widget=true&amp;headers=true&amp;chrome=false&amp;range=A1:B1" style="border:1px solid gray;" width="500" height="600"></iframe>

To:

<iframe src="https://docs.google.com/spreadsheets/d/e/xxxxx-1vTvQphG_8AomL4TacudrbUYMRlWuL_nITRnPMBeVEOz8bJ6y-3DXFdCqmZ7io9wgyvi6eEBl7Dju2qT/pubhtml?gid=1922308330&amp;widget=true&amp;headers=true&amp;chrome=false&amp;range=A1:B1" style="border:1px solid gray;" width="500" height="600"></iframe>

Reference:

  • Related