Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <link href="https://fonts.googleapis.com/css?family=Bungee|Open+Sans|Roboto|Dancing+Script" rel="stylesheet">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css">
<div class="wrap">
  <div class="box">
    <div class="row left">

      <i class=" fa fa-quote-left" aria-hidden="true"></i>

      <h2 class="title textbox"></h2>
      <div class=" fa fa-quote-right" aria-hidden="true"></div>

      <div class="author" </div> </div>
      <div class=icons>

        <a href="" class="btn btn-twitter text-center" id="twitter-button"> <span class="fa fa-twitter fa-2x"></span>
        </a>
        <a href="https://uk.linkedin.com/in/kaedi-harris-64284573" class="btn text-center btn-linkedin">
          <span class="fa fa-linkedin fa-2x"></span>
        </a>
        <button class="newQuote btn btn-primary" id="newQuote">New Quote</button>
      </div>
    </div>
    </div>
 <footer class="footer text-center">
   <div class="container">
     <span class="text-muted">
       <p> CREATED BY KD HARRIS</p> 
     </span></div>
</footer>
  
              
            
!

CSS

              
                body {
  font-family: arial, sans-serif;
  background-color: black;
  overflow:auto;

}
.wrap {
   min-height: 100%;
}

.icons {
  text-align: center; 
}
.box {
  width: 25%;
  background-color: grey;
  margin-top: 100px;
  margin-right: auto;
  margin-left: auto;
  margin-bottom: 70px;
  text-align: center;
  padding: 100px 70px 40px 50px;
  border-radius: 2.5px;
  overflow:auto;
  padding-bottom:50px; 

}
.text {
  family-font: Roboto;
  text-align: left;
}

.textbox {
  text-align: right;
  font: italic, bold;
  font-size: 12px;
}
.left {
  text-align: left;
}
.fa-quote-right {
  float: right;
}
.fa-quote-left {
  padding-left: 15px;
}

.row {
  padding: 0px, 0px, 30px, 20px;
  margin-bottom: 60px;
}

.btn-primary {
  padding: 10px 20px 10px 20px;
  font-colour: black;
}
.title {
  font-style: italic;
  font-family: 'Dancing Script', cursive;
  font-size: 30px;
  padding: 0px 0px 0px 0px;
  text-align: center; 
 }
.author {
  font-family: "Times New Roman", Times, serif;
  float: center;
  font-style: oblique;
  text-align: center;
  font-size: 25px;
  padding: 50px 0px 50px 0px;
}

.footer{ 
  background-color: grey; 
  padding: 20px 20px 20px 20px;
  padding-bottom: 10px;
}

.text-muted {
  color: white;
  font-style: italic;
  font-family: 'Roboto', sans-serif;
  margin-top: -50px;
 
}
              
            
!

JS

              
                $(document).ready(function() {
  
  function getQuote() {
    $.ajax({
      url: "https://api.forismatic.com/api/1.0/",
      jsonp: "jsonp",
      dataType: "jsonp",
      data: {
        method: "getQuote",
        format: "jsonp",
        lang: "en"
      },
      success: function(quotes) {
        $(".title").html(quotes.quoteText);
        $(".author").html(quotes.quoteAuthor);
      }
    });
  }

  getQuote();

  $("#newQuote").on("click", function(event) {
    event.preventDefault();
    getQuote();
  });

  $("#twitter-button").on("click", function(event) {
         event.preventDefault();
    var texttotweet ="Just another motivational quote to share by";
  var TwitterLink="https://twitter.com/intent/tweet?text=";
  
 window.open(TwitterLink + encodeURIComponent(texttotweet +" " + $('.author').text() + " " + $('.title').text() +  " " ));
    
  });
    
});


 
              
            
!
999px

Console