SingleFile
SingleFile copied to clipboard
SingleFile and SingleFileZ both have problem when saving a webpage tool based on Bootstrap.
Describe the bug I want to save this webpage tool for offline use. Its format is based on Bootstrap: https://wxlzmt.github.io/pages/simple/calc.html
Because I want to run the functions in the offline webpage, I unchecked all the blocked resources. However, the calculating function of this page don't work in the saved webpage.
Then I unchecked all the checkboxes that have word "remove" and saved the page, Though the function works, the webpage format becomes abnormal.
To Reproduce Steps to reproduce the behavior:
- Reset SingleFile or SingleFileZ's Settings
- Go to https://wxlzmt.github.io/pages/simple/calc.html
- Change SingleFile or SingleFileZ's Settings like "Describe the bug"
- Save this webpage by SingleFile or SingleFileZ.
- Open the saved file.
- See error
Expected behavior
To reserve the webpage's original format and functions, only uncheck all the blocked resources is enough. This will do help to many pages based on Bootstrap. Thank you!
Environment
- OS: Win11 Pro
- Browser: Edge
- Version: 124.0.2478.67
Additional context
-
The webpage's function is simple, Its' only function is to divide two numbers into two coprime integers, and find the value of multiplying the two coprime integers by 1-any number. It can be used offline.
-
The translation of this page in English is shown below:
- The webpages are saved in InPrivate mode, No other extension block the saving process.
Can you please try to enable the option HTML content > save raw page
?
I tried. But the situation become worse.
It looks to work for me with HTML content > save raw page
enabled (and the other options you mentioned) but the page displays two alerts and the form is not filled with the default values. However, it is functional.
Your program is really great. I tried several other pages with offline scripts, most of them can be saved correctly with scripts inside, In the case of only unchecking the Network > block xxx
with the default settings.
I wonder why this page cannot be saved normally, but I feel it is really a good example for you to improve your program.
Note: I tried your option again (Though it is relatively troublesome). The saved webpage's script can work, but the initial value is lost.
Thanks, the problem was that SingleFile was overwriting the values of some fields when “save raw page” was enabled. I've fixed the bug, the fix will be available in the next version.