I'm trying to import a MediaWiki table from here:
Is there anything I can do here? I would be alright if, at the very least, I could pull the link to the photo to put there if I can't pull the photos themselves.
CodePudding user response:
In this case IMPORTHTML can't access links or images that's why the images are not retrieved when calling the function, a solution could be that you call the image directly by using the
to get whole table use:
=INDEX({SUBSTITUTE(ARRAY_CONSTRAIN(
IMPORTHTML(A1, "table", 1), 9^9, 4), "*", ),
ARRAY_CONSTRAIN({"Photo"; IMAGE(QUERY(
IMPORTXML(A1, "//a/@href"),
"where Col1 contains 'images'"))}, 448, 1)})