Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

404 to Archive Redirecter #26

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

404 to Archive Redirecter #26

wants to merge 1 commit into from

Conversation

DanzHD
Copy link

@DanzHD DanzHD commented Jan 7, 2024

A greasemonkey/tampermonkey script to, when detecting a page that says "404" or "Not Found" on it, automatically redirect to that page in the Internet Archive.

Can be installed here https://greasyfork.org/en/scripts/484103-404pagerevival

@DanzHD
Copy link
Author

DanzHD commented Feb 1, 2024

@Divide-By-0 sorry, were there any issues that you wanted me to fix?

@Divide-By-0
Copy link
Owner

Divide-By-0 commented Feb 6, 2024

@Divide-By-0 sorry, were there any issues that you wanted me to fix?

Hey sorry I haven't been as responsive. Just installed, will try out for a week. One quick nit is that the serif font is sort of ugly, and it should automatically check archive.org instead of asking me to click the button first.

Also, https://login.live.com/login.srf seems to trigger this extension even though it's not a 404.

@DanzHD
Copy link
Author

DanzHD commented Feb 6, 2024

@Divide-By-0 sorry, were there any issues that you wanted me to fix?

Hey sorry I haven't been as responsive. Just installed, will try out for a week. One quick nit is that the serif font is sort of ugly, and it should automatically check archive.org instead of asking me to click the button first.

Also, https://login.live.com/login.srf seems to trigger this extension even though it's not a 404.

I can definitely change the font style and make it check archive.org on initial load but I don't think I can do anything else to prevent false positives due to the fact that I'm using the page's response status code to detect a 404 page which can be incorrect.

@Divide-By-0
Copy link
Owner

@Divide-By-0 sorry, were there any issues that you wanted me to fix?

Hey sorry I haven't been as responsive. Just installed, will try out for a week. One quick nit is that the serif font is sort of ugly, and it should automatically check archive.org instead of asking me to click the button first.
Also, https://login.live.com/login.srf seems to trigger this extension even though it's not a 404.

I can definitely change the font style and make it check archive.org on initial load but I don't think I can do anything else to prevent false positives due to the fact that I'm using the page's response status code to detect a 404 page which can be incorrect.

From what I understand of that link, it gives a 404 then redirects automatically to a non-404, but your script doesn't seem to pick up the redirect.

@DanzHD
Copy link
Author

DanzHD commented Feb 6, 2024

@Divide-By-0 sorry, were there any issues that you wanted me to fix?

Hey sorry I haven't been as responsive. Just installed, will try out for a week. One quick nit is that the serif font is sort of ugly, and it should automatically check archive.org instead of asking me to click the button first.
Also, https://login.live.com/login.srf seems to trigger this extension even though it's not a 404.

I can definitely change the font style and make it check archive.org on initial load but I don't think I can do anything else to prevent false positives due to the fact that I'm using the page's response status code to detect a 404 page which can be incorrect.

From what I understand of that link, it gives a 404 then redirects automatically to a non-404, but your script doesn't seem to pick up the redirect.

Yep, you're right. I've uploaded a new update that should fix the issues and changes the font to Arial.

@Divide-By-0
Copy link
Owner

CNAME redirects still fail with your tool i.e. https://tool.zkregex.com/ or https://zkregex.com/tool.

@Divide-By-0
Copy link
Owner

Not sure Arial fits well with Chrome, can you try Segoe UI? Also can you make the button less tall?

@DanzHD
Copy link
Author

DanzHD commented Feb 7, 2024

CNAME redirects still fail with your tool i.e. https://tool.zkregex.com/ or https://zkregex.com/tool.

Thanks for letting me know.

It seems that the final page from the redirect always sends back a 404 status code as the response. I checked with a redirect tool and it also gets a 404 status code back from the final page. Do you have any suggestions for potential fixes?

Not sure Arial fits well with Chrome, can you try Segoe UI? Also can you make the button less tall?

Yep, I can do that.

@Divide-By-0
Copy link
Owner

CNAME redirects still fail with your tool i.e. https://tool.zkregex.com/ or https://zkregex.com/tool.

Thanks for letting me know.

It seems that the final page from the redirect always sends back a 404 status code as the response. I checked with a redirect tool and it also gets a 404 status code back from the final page. Do you have any suggestions for potential fixes?

Not sure Arial fits well with Chrome, can you try Segoe UI? Also can you make the button less tall?

Yep, I can do that.

These don't 404 for me, can you figure out how to differentiate incorrect 404s from real 404s? It's a 404 on https but not on http I believe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants