get-started.html 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. {% capture stripe_ad_content %}
  2. <p class="lead">
  3. Setting up Font Awesome can be as simple as adding two lines of code to your website, or you can be a pro and
  4. customize the LESS yourself! Font Awesome even plays nicely with
  5. <a href="{{ site.bootstrap.url }}">Bootstrap</a>!
  6. </p>
  7. {% endcapture %}
  8. {% include stripe-ad.html %}
  9. <div id="bootstrapcdn">
  10. <h2 class="page-header">EASIEST: <a href="http://www.bootstrapcdn.com/#tab_fontawesome">BootstrapCDN</a></h2>
  11. <p>Add Font Awesome + Bootstrap into your website with two lines of code. You don't even have to download or install anything!</p>
  12. <ol>
  13. <li>
  14. Paste the following code into the <code>&lt;head&gt;</code> section of your site's HTML.
  15. {% highlight html linenos %}
  16. <link href="//netdna.bootstrapcdn.com/twitter-bootstrap/{{ site.bootstrap.version }}/css/bootstrap-combined.no-icons.min.css" rel="stylesheet">
  17. <link href="//netdna.bootstrapcdn.com/font-awesome/{{ site.font_awesome.version }}/css/font-awesome.css" rel="stylesheet">
  18. {% endhighlight %}
  19. <div class="alert alert-info margin-top">
  20. <i class="icon-info-sign"></i> Want to use Font Awesome by itself without Bootstrap? Just don't include the first line.
  21. </div>
  22. </li>
  23. <li>
  24. Pat yourself on the back for your scalable-vector-icons-on-the-website
  25. <a href="http://37signals.com/svn/posts/312-lingo-judo">judo solution</a> in two lines of code.
  26. </li>
  27. <li>
  28. Check out the <a href="{{ page.relative_path }}examples/">examples</a> to start using Font Awesome!
  29. </li>
  30. </ol>
  31. </div>
  32. <section id="default-css">
  33. <h2 class="page-header">EASY: Default CSS</h2>
  34. <p>Use this method to get the default Font Awesome CSS with the default Bootstrap CSS.</p>
  35. <ol>
  36. <li>Copy the <code>font-awesome</code> directory into your project.</li>
  37. <li>
  38. In the <code>&lt;head&gt;</code> of your html, reference the location to your font-awesome.min.css.
  39. {% highlight html linenos %}
  40. <link rel="stylesheet" href="path/to/bootstrap/css/bootstrap.min.css">
  41. <link rel="stylesheet" href="path/to/font-awesome/css/font-awesome.min.css">
  42. {% endhighlight %}
  43. </li>
  44. <li>Check out the <a href="{{ page.relative_path }}examples/">examples</a> to start using Font Awesome!</li>
  45. </ol>
  46. </section>
  47. <section id="custom-less">
  48. <h2 class="page-header">PRO: Custom LESS</h2>
  49. <p>Use this method to customize Font Awesome and Bootstrap {{ site.bootstrap.version }} using LESS.</p>
  50. <ol>
  51. <li>Copy the <code>font-awesome</code> directory into your project.</li>
  52. <li>Open bootstrap.less and replace <code>@import "sprites.less";</code> with <code>@import "path/to/font-awesome/less/font-awesome.less";</code></li>
  53. <li>
  54. Open your project's font-awesome.less and edit the <code>@FontAwesomePath</code> variable to point to your font directory.
  55. {% highlight html linenos %}
  56. @FontAwesomePath: "../font";
  57. {% endhighlight %}
  58. <p class="alert alert-info"><i class="icon-info-sign"></i> The font path is relative from your compiled CSS directory.</p>
  59. </li>
  60. <li>Re-compile your LESS if using a static compiler. Otherwise, you should be good to go.</li>
  61. <li>Check out the <a href="{{ page.relative_path }}examples/">examples</a> to start using Font Awesome!</li>
  62. </ol>
  63. </section>
  64. <section id="not-using-bootstrap">
  65. <h2 class="page-header">Not using Bootstrap?</h2>
  66. <p>Font Awesome works just as well without Bootstrap.</p>
  67. <ol>
  68. <li>Copy the <code>font-awesome</code> directory into your project.</li>
  69. <li>Follow the above directions and skip the Bootstrap parts.</li>
  70. <li>Open your project's font-awesome.less or font-awesome.min.css and edit the font location to point it to your font directory (see above examples).</li>
  71. <li>Check out the <a href="{{ page.relative_path }}examples/">examples</a> to start using Font Awesome!</li>
  72. </ol>
  73. </section>
  74. <section class="need-ie7">
  75. <h2 class="page-header">Need IE7 Support?</h2>
  76. <p>Font Awesome supports IE7. If you need it, you have my condolences.</p>
  77. <ol>
  78. <li>Get Font Awesome working properly in a modern browser.</li>
  79. <li>Copy font-awesome-ie7.min.css into your project.</li>
  80. <li>
  81. In the <code>&lt;head&gt;</code> of your html, reference the location to your font-awesome-ie7.min.css.
  82. {% highlight html linenos %}
  83. <link rel="stylesheet" href="path/to/bootstrap/css/bootstrap.min.css">
  84. <link rel="stylesheet" href="path/to/font-awesome/css/font-awesome.min.css">
  85. <!--[if IE 7]>
  86. <link rel="stylesheet" href="path/to/font-awesome/css/font-awesome-ie7.min.css">
  87. <![endif]-->{% endhighlight %}
  88. </li>
  89. <li>Go complain to whoever decided your project needs IE7 support.</li>
  90. </ol>
  91. </section>