Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Some images on a webpage do not want to be saved.

1 view
Skip to first unread message

R.Wieser

unread,
Sep 23, 2021, 8:01:33 AM9/23/21
to
Hello all,

Under Windows using FF 52 (last one for XP) I tried to save the below
webpage :

https://lkubaski.wordpress.com/2012/06/29/adding-lxde-start-menu-and-desktop-shortcuts/

I found that a few images (starting with the second one, "properties.png")
where absent. No problem ofcourse, just drag-and drop it into a folder ...

And that is where it became strange : although the filename on disk was
"properties.png", its contents was a full webpage. <whut?>

The same happened when I tried to save the image thru rightclick -> "view
image info".

Looking at the page source and grabbing the image link from there did not
work either. Nor did rightclick -> "view image" and than any of the above.


In cases like this, what do I need to do to actually save those images ?

Regards,
Rudy Wieser


Balaco ocalaB

unread,
Sep 23, 2021, 8:00:00 PM9/23/21
to
Try to save them with a command line program like lynx, and be sure to
send a referer header with the request.

As a proof of concept, change your normal browser settings to *never*
send a referer header, and reload the page again. If it does not work, i
think you found the problem.

😉👍🏾

R.Wieser

unread,
Sep 24, 2021, 4:38:32 AM9/24/21
to
Balaco,

> Try to save them with a command line program like lynx,

:-) You're mentioning the very thing I wanted to forgo : to /reload/ the
image from its server. The browser already has the image somewhere,
otherwise it would not be able to display it.

What I'm currently aiming/asking for is (a configuration setting) to /grab
that cached image/ and save it to a folder of my choosing.

Regards,
Rudy Wieser

P.s.
I found the problematic images in the "profiles\...\cache2\doomed" folder.
Alas, with random numbers as the filename, and lots of stuff embedded in the
image file for caching purposes.


Sailfish

unread,
Oct 2, 2021, 12:21:47 PM10/2/21
to
R.Wieser graced us with on 9/23/2021 5:01 AM:
Your understanding is correct. Although it is named using the .png
extension it is really a WordPress (WP) link. Looking at the link via
Page Source, this is what it looks like:
***************
<p>
<a href="https://lkubaski.files.wordpress.com/2012/06/properties.png">
<img loading="lazy" data-attachment-id="219"
data-permalink="https://lkubaski.wordpress.com/2012/06/29/adding-lxde-start-menu-and-desktop-shortcuts/properties/"
data-orig-file="https://lkubaski.files.wordpress.com/2012/06/properties.png"
data-orig-size="450,286"
data-comments-opened="1"
data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,

&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,

&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,
&quot;title&quot;:&quot;&quot;}" data-image-title="properties"
data-image-description="" data-image-caption=""
data-medium-file="https://lkubaski.files.wordpress.com/2012/06/properties.png?w=300"
data-large-file="https://lkubaski.files.wordpress.com/2012/06/properties.png?w=450"
class="alignnone size-medium wp-image-219" title="properties" alt=""
src="https://lkubaski.files.wordpress.com/2012/06/properties.png?w=300&#038;h=190"
width="300" height="190"
srcset="https://lkubaski.files.wordpress.com/2012/06/properties.png?w=300&amp;h=190
300w,
https://lkubaski.files.wordpress.com/2012/06/properties.png?w=150&amp;h=95
150w,
https://lkubaski.files.wordpress.com/2012/06/properties.png 450w"
sizes="(max-width: 300px) 100vw, 300px" />
</a>
</p>
*****************

Without spending too much time on analyzing it, it looks like WP defines
it as a set of images, each with varying sizes, depending on the
"width/height" defined in the link and then uses that to serve the image
that matches that size. In this case,
"https://lkubaski.files.wordpress.com/2012/06/properties.png?w=300&h=190"

The best you can do is to screenshot the displayed images and save them
as simple .png files and then text-editing the .html source and remove
the anchor tag "<a>...</a> and leaving just the html <img> tag.

--
Sailfish
CDC Covid19 Trends: https://www.facebook.com/groups/624208354841034
Rare Mozilla Stuff: http://tinyurl.com/z86x3sg

R.Wieser

unread,
Oct 2, 2021, 3:44:40 PM10/2/21
to
Sailfish,

> Your understanding is correct. Although it is named using the .png
> extension it is really a WordPress (WP) link.

AFAICT its not the link that is the problem, but how its interpreted by the
webserver. Somehow it knows when it requested by the to-be-displayed
webpage itself, and than returns the actual image. In all other cases it
returns a webpage. I'm guessing that its a kind of anti-copy protection.

> Looking at the link via Page Source, this is what it looks like:

I know, I did the same. :-)

> The best you can do is to screenshot the displayed images and save them as
> simple .png files

As it turned out FF temporarily saved those actual images it displayed into
the "Profiles\default\cache2\doomed" folder. Just with a bit more info
injected and appended in/onto the image than I would want, but the image
itself displays fine.

IOW, no screenshotting and subsequent clipping necessary.

Thanks for the suggestion though.

Regards,
Rudy Wieser


Sailfish

unread,
Oct 2, 2021, 10:18:41 PM10/2/21
to
R.Wieser graced us with on 10/2/2021 12:44 PM:
+1

T

unread,
Oct 3, 2021, 5:48:16 AM10/3/21
to
Hi Rudy,

I come across similar things like that
all the time. I use Windows Snipping Tool
or Linux xfce4-screenshooter and just make
up my own image.

-T

R.Wieser

unread,
Oct 3, 2021, 3:38:38 PM10/3/21
to
T,

> I use Windows Snipping Tool or Linux xfce4-screenshooter and just make up
> my own image.

Thanks. And yes, if all else fails than I could do that I suppose. It
sounds too much like work though. :-)

What I was hoping for was some kind of FF setting (about:config ?) which
would tell the browser to retrieve the resource from its cache, instead of
re-downloading it.

Regards,
Rudy Wieser


T

unread,
Oct 3, 2021, 8:41:14 PM10/3/21
to
I have xfce4-screenshooter on my panel 1 bar. To save a screen shot is
four clicks and a drag. Way easier that about:/config (especially since
I misspell it a lot).

In Windows the worst part is finding snipping tool.

T

unread,
Oct 3, 2021, 11:05:55 PM10/3/21
to
On 10/3/21 12:38, R.Wieser wrote:
Just out of curiosity, why did you not
try to save the graphic from a different
browser?

R.Wieser

unread,
Oct 4, 2021, 2:35:02 AM10/4/21
to
T,

> Way easier that about:/config (especially since I misspell it a lot).

I disagree. about:config would be "apply once, use forever" type of
solution.

And cutting out stuff that way has got a few drawbacks. Its not all that
easy to /exactly/ outline the image (resulting in cutting away to much or
leaving a, most alway ugly, border). Also, if the origional image is partly
transparent (as often happens on the edges of PNG images) the result looses
that transparency, instead returning a mix with whatever was in the
background.

> Just out of curiosity, why did you not try to save the graphic from a
> different browser?

Outof curiosity, why should I be using or just have multiple browsers
installed ? I have no wish to manage multiple of them - all with their
own problems regarding security and privacy.

Regards,
Rudy Wieser


T

unread,
Oct 4, 2021, 4:25:22 AM10/4/21
to
I use xfce4-screenshooter multiples times a day
writing directions and manuals for my customers that
it is second nature. I do have to say that Windows'
snipping tool is a bit weird and cumbersome.


On 10/3/21 23:34, R.Wieser wrote:
> Outof curiosity, why should I be using or just have multiple browsers
> installed ? I have no wish to manage multiple of them - all with their
> own problems regarding security and privacy.


I pretty much need to see everything my customers see.

Have you tried opening the web page in Firefox, then
going to tools, Browser tools, Web Page and
looking for the png in question?

R.Wieser

unread,
Oct 4, 2021, 8:52:19 AM10/4/21
to
T,

> I pretty much need to see everything my customers see.

In that case I understand you need to use multiple. In my case I've got
only myself to consider, and I'm definitily not a WYSIWYG acolyte in regard
to HTML.

> Have you tried opening the web page in Firefox, then going to tools,
> Browser tools, Web Page andlooking for the png in question?

I don't have that choice in FF v52. The nearest I get is tools -> web
developer -> browser toolbox (ctrl-alt-shift-I) and browser console
(ctrl-shift-J). The latter doesn't seem to offer any kind of image view
(its just a logger), the former causes alarm bells to go off.

Regards,
Rudy Wieser


T

unread,
Oct 4, 2021, 9:47:04 PM10/4/21
to
On 10/4/21 05:52, R.Wieser wrote:

>
>> Have you tried opening the web page in Firefox, then going to tools,
>> Browser tools, Web Page andlooking for the png in question?
>
> I don't have that choice in FF v52. The nearest I get is tools -> web
> developer -> browser toolbox (ctrl-alt-shift-I) and browser console
> (ctrl-shift-J). The latter doesn't seem to offer any kind of image view
> (its just a logger), the former causes alarm bells to go off.
>
> Regards,
> Rudy Wieser
>

52. Hmmmm.

You could always download the web page into a
text file with "curl", then dig out the png's
address.

If you would like, you can give me the web site
and tell me which png you are after and I
will see it I can find the direct link for you.
I do that kind of thing all the time. (And it
I owe you a bunch for helping me with dll
programming)


R.Wieser

unread,
Oct 5, 2021, 4:24:47 AM10/5/21
to
T,

> You could always download the web page into a text file with "curl", then
> dig out the png's
> address.

I had no problem digging out the URL using the "view page source" option.
But alas, after pasting it into FFs URL bar I again got a full webpage.

HOLD THE PRESSES ! ...

I most always double-check what I did just before posting about it, and now
is no exception. I grabbed the URL, dropped it into a "curl" like Windows
program, and got the actual image back. WTF? After that I dropped into
FFs URL bar and /again/ got that actual image back. Double WTF.


Some checking-and-testing later I've got the answer : When drag-and-dropping
didn't work I opened the pages source and grabbed the image URL from there.
This time I was a bit too hasty and mistakingly grabbed the URL from the
link around it.

The difference ? The images "src=" URL has (size defining) arguments
following the path, while the links "href=" doesn't. Thats all.

IOW, grabbing the image link (rightclick -> copy image location) and than
removing the arguments gives the origional image (instead of a webpage).

Sigh ... If only I had followed the link / clicked on those images ...
than again, I had no reason to do so ...

> If you would like, you can give me the web site
> and tell me which png you are after and I
> will see it I can find the direct link for you.

Thanks for thet offer. But as you can see, my immediate problem [1] seems
to have been solved.

[1] would have liked to hear about a possible "save from cache" setting for
FF, but you can't have everything. :-)

> And it I owe you a bunch for helping me with dll
> programming

As far as I remember all I did was giving a bit of information and advice.
You had to do all the hard work.

But you're welcome. :-)

Regards,
Rudy Wieser



0 new messages