Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

PHP 

Can websites detect if you open their html from localhost?

Apologies if this is in the wrong section, I tried to search for this but couldn't actually get a straight answer

Say you have a website where you track visitors and how long they use your site, and you have a tally/summation for the number of unique visitors, how many times they open the page, and how long each person has spent on your site.

If somebody saves a page on the site as .html and opens if from their harddrive, does the website detect this?

I would assume it does not since you can open the file without an internet connection, but if you click links in the downloaded file, it opens the pages from the actual site, on the internet.


Sorry if this is a stupid question. I have no knowledge of websites or networking.


Thanks!
Yes and no. The main way websites generate analytics is with JavaScript. If you download the script with the HTML or script reference, it will potentially still fire the different events. However, you can circumvent this by disabling your network as mentioned.

When you download the source code, I'm fairly certain your browser will not make another network request for the HTML file, I think it just uses the current rendered page. Even then, a server (unless the browsers leaves an indication that it's downloading the source) will not know that you're downloading the file.

PS, web development section would've been better.

Je t'aime
[Image: fpZ5a5g.png]

(Apr 22, 2022 04:39 PM)-Scrub Wrote:  Jokes on you, I'm not smart enough to know what he's talking about.
(Apr 21, 2020 03:12 PM)The One Who Knocks Wrote:  Apologies if this is in the wrong section, I tried to search for this but couldn't actually get a straight answer

Say you have a website where you track visitors and how long they use your site, and you have a tally/summation for the number of unique visitors, how many times they open the page, and how long each person has spent on your site.

If somebody saves a page on the site as .html and opens if from their harddrive, does the website detect this?

I would assume it does not since you can open the file without an internet connection, but if you click links in the downloaded file, it opens the pages from the actual site, on the internet.


Sorry if this is a stupid question. I have no knowledge of websites or networking.


Thanks!

What Nach said. But just to expand a bit more-

No, the website isn't going to "detect" it per se. If the scripts are written in a way to not respond to differing referers (really unlikely) then functionality may be broken or different. But, unlikely that there's any detection happening. Their servers will log your referer as localhost, so I suppose if they're looking there they will see that you've done so.
<Disease />
if u saved all the files locally, and removed all external references to their JS, Images, ETC and if their code was done properly then no,

Otherwise yes


Possibly Related Threads...
Thread / Author Replies Views Last Post
[PHP] by NickyDevApr 16, 2024 05:49 AM 10 353 Apr 16, 2024 05:49 AM
Last Post: DynamicW
[Javascript]  by flexing_99Apr 29, 2023 12:02 AM 3 269 Apr 29, 2023 12:02 AM
Last Post: Zgh600
[Node.JS] by Reiss0101Nov 20, 2022 06:01 AM 1 149 Nov 20, 2022 06:01 AM
Last Post: Oxycodone