Patching Vivaldi with batch scripts
-
@luetage said in Patching Vivaldi with batch scripts:
Thatβs the mistake, the script tags have to go into the body tag, as described in the first post.
Oh my bad
I've updated my previous code. It now adds the script before</body>
Wasn't it in the previous version also in the
HEAD
? -
-
@luetage i found out myself:
<!-- Vivaldi window document --> <!DOCTYPE html> <html> <head> <!-- Keep the styling in sync with ./browser.html --> <meta charset="UTF-8" /> <title>Vivaldi</title> <link rel="stylesheet" href="style/common.css" /> <link rel="stylesheet" href="chrome://vivaldi-data/css-mods/css" /> </head> <body> </body> <script src="custom.js"></script> </html>
I am very happy about that.
-
@stardepp As custom mods are not "offically supported" by Vivaldi, I have moved your posts here, hope that's OK
-
@Pathduck said in Patching Vivaldi with batch scripts:
@stardepp As custom mods are not "offically supported" by Vivaldi, I have moved your posts here, hope that's OK
Yes, you got that so right.
-
@stardepp
Good job! -
I don't see the difference. Please clarify.
This is my window.html file:
<!-- Vivaldi window document --> <!DOCTYPE html> <html> <head> <!-- Keep the styling in sync with ./browser.html --> <meta charset="UTF-8" /> <title>Vivaldi</title> <link rel="stylesheet" href="style/common.css" /> <link rel="stylesheet" href="chrome://vivaldi-data/css-mods/css" /> </head> <body> </body> <script src="custom.js"></script> </html>
Is it Ok?
-
@barbudo2005 Just copy my code and use it.
-
@stardepp The
script
element is not allowed inside thehtml
element. It needs to go inside thebody
element. What you're doing is not valid HTML code.It might work (browsers do some "fool proofing", but is not the correct way to add scripts
-
So mine is Ok?
-
@barbudo2005 No, yours is the exact same code
-
@barbudo2005 your file has to look like this:
<!-- Vivaldi window document --> <!DOCTYPE html> <html> <head> <!-- Keep the styling in sync with ./browser.html --> <meta charset="UTF-8" /> <title>Vivaldi</title> <link rel="stylesheet" href="style/common.css" /> <link rel="stylesheet" href="chrome://vivaldi-data/css-mods/css" /> </head> <body></body> <script src="custom.js"></script> </html>
-
@Pathduck But for me all JavaScript modifications work like this with this code.
-
@oudstand said in Patching Vivaldi with batch scripts:
<body></body>
<script src="custom.js"></script>
</html>Does it really work? Placing your
<script>
element like that is not valid HTML - it should go inside the body as stated in the guide.https://forum.vivaldi.net/topic/10549/modding-vivaldi#:~:text=inside the body element
But if it works, I guess it's fine ...
-
@barbudo2005 Itβs not. Your script is below the body closing tag
</body>
-
-
<body><script src="test.js"></script></body>
You should look into HTML basics. Will only take you 20 minutes, it is useful to know a little about it.
-
Don't be a bad person, give me the whole bar of chocolate, not just a square. LOL.
Please post the complete file detail.
-
-