In using the wget
command below,
$ wget \
--recursive \
--no-clobber \
--page-requisites \
--html-extension \
--convert-links \
--restrict-file-names=windows \
--domains grantmlong.com \
--no-parent \
grantmlong.com/teaching/index.html
I have been trying to download all content from a professor's course page. For some reason, while much of the image content for the remainder of the site is being downloaded correctly, the images for the reveal.js lecture slides are not being downloaded.
For example, if, on my local computer, I navigate to grantmlong.com/teaching/lectures/
and open lecture1.html
, what appears for the third slide is
On the website, I find that the image is located at https://grantmlong.com/teaching/lectures/img/hbr.png
. If I navigate to the local img
folder downloaded by wget
, I see
cd grantmlong.com/teaching/lectures/img
ls -1
l10_f0.png
l10_f1.png
l10_f2.png
l10_f3.png
l10_f4.png
l10_f5b.png
l10_f5.png
l10_f6.png
l10_f7.png
l10_p1.png
l10_p2.png
l11_p1.png
l11_p2.png
l11_p3.png
l11_p4.png
l11_p5.png
l11_p6.png
l12_p1.png
l12_p2.png
l5_e1.png
l5_e2.png
l5_e3.png
l5_e4.png
l5_glm.png
l5_logreg.png
l5_p10.png
l5_p11.png
l5_p1a.png
l5_p1b.png
l5_p2.png
l5_p3.png
l5_p4.png
l5_p5.png
l5_p6.png
l5_p7.png
l5_p8.png
l5_p9.png
l5_reg_output_1.png
l5_reg_output_2.png
l5_reg_output_3.png
l5_reg_output_4.png
l5_reg_output.png
l6_accuracy.png
l6_confusion.png
l6_p1.png
l6_precision.png
l6_recall.png
l9_p1.png
l9_p2.png
l9_p3.png
l9_p4.png
l9_t1.png
l9_t2.png
l9_t3.png
l9_t4.png
l9_t5.png
hbr.png
is nowhere to be found, which shows that the images in these reveal.js slides are not considered "page requisites" and are not being downloaded by wget
.
What can I do to ensure these images are downloaded? Also, note that some of the images on the reveal.js slides come from 3rd party sites like giphy. How can I ensure that this external content is downloaded while keeping the option --domains grantmlong.com
true for all pages that aren't reveal.js slides?