'Issues when using w3data.js
I'm trying to use w3data.js for an all html website. The goal is to limit copy/paste from page to page by adding html includes.
In my case I've created an index.html
who looks like this:
<!DOCTYPE html>
<html lang="fr">
<meta http-equiv="content-type" content="text/html;charset=UTF-8" />
<head>
<script src="http://www.w3schools.com/lib/w3data.js"></script>
</head>
<body id="home">
<div w3-include-html="header-home.html"></div>
<!-- to call a bootstrap navbar -->
<script>
w3IncludeHTML();
</script>
</body>
I followed the W3 how to: http://www.w3schools.com/howto/howto_html_include.asp but it doesn't work for me.
In my console, I have an error. My website https://minutedrone.com
is secure (HTTPS), but w3schools.com is not, so I can't change the script.
It works when I go on the HTTP version of my website (www.w3schools.com don't have a HTTPS version).
What can I do to fix this issue, or is there another way to do what I want?
Please help. Thanks !!
Solution 1:[1]
You can:
- Host the JS file yourself
- Find a different third party host that supports HTTPS
- Use a better method for including shared metacontent
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Community |