Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to apply CSS and JavaScript from dropbox folder (For using it in blogger)

I want to add dropbox url in the below link tags and script tags,so that I can use this template in my blog. I tried it, but the themes are not being applied. Please help. My common dropbox folder: https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM contains css and js files.

<head>
    <title>Tessellate by HTML5 UP</title>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
    <meta name="description" content="" />
    <meta name="keywords" content="" />
    <link href="http://fonts.googleapis.com/css?family=Roboto:100,100italic,300,300italic,400,400italic" rel="stylesheet" type="text/css" />
    <!--[if lte IE 8]><script src="https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM/html5shiv.js"></script><![endif]-->
    <script src="https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM/jquery.min.js"></script>
    <script src="https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM/skel.min.js"></script>
    <script src="js/init.js"></script>
    <noscript>
        <link rel="stylesheet" href="https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM/skel-noscript.css" />
        <link rel="stylesheet" href="https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM/style.css" />
        <link rel="stylesheet" href="https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM/style-wide.css" />
    </noscript>
    <!--[if lte IE 8]><link rel="stylesheet" href="https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM/v8.css" /><![endif]-->
    <!--[if lte IE 9]><link rel="stylesheet" href="https://www.dropbox.com/sh/b7bqyva7pz39nx1/QIGR6hJpkM/v9.css" /><![endif]--
like image 259
user3309671 Avatar asked Feb 14 '14 09:02

user3309671


People also ask

How do I link CSS and JavaScript files?

To link a CSS file with your HTML file, you have to write the next script on your HTML file inside the head tag. To link a Js file with your HTML, you only have to add the source of the script inside the body tag or outside; it doesn't matter.

How do I put HTML CSS and JavaScript in one file?

We can link JavaScript to HTML by adding all the JavaScript code inside the HTML file. We achieve this using the script tag which was explained earlier. We can put the <script></script> tag either inside the head of the HTML or at the end of the body.

How do I embed a Dropbox folder on my website?

Embedding Files or Folders using anchor tags One way to embed content is using an anchor tag ( <a> ). Anchor tags with class=dropbox-embed and an href attribute set to a shared link will automatically expand the link into embedded content.


3 Answers

Replace www. with dl. is what worked for me.

Something like this: https://dl.dropbox.com/s/...

like image 55
user3389566 Avatar answered Nov 08 '22 05:11

user3389566


Copy the link by Clicking on "Share" and add ?raw=1 after every JS and CSS file or other files that you want to host on Dropbox.

<script src='https://www.dropbox.com/s/example.js?raw=1' type='text/javascript'></script>
like image 21
Kuwar Dheeraj Srivastava Avatar answered Nov 08 '22 04:11

Kuwar Dheeraj Srivastava


Reference: https://docs.helpscout.net/article/92-stylesheet-dropbox

Copy the public link of your file and then replace www with dl and it should work. I tried it, its working, here is the JS file link with the code -

<script src='https://dl.dropboxusercontent.com/s/au8i66el92duxdm/homeslider.js'></script>
like image 38
Faiz Sheikh Avatar answered Nov 08 '22 03:11

Faiz Sheikh