Source files of,,,,, and Contribute:
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

template.en.xhtml 17KB

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <html>
  3. <head>
  4. <title>Template article – Contribute – FSFE</title>
  5. </head>
  6. <body class="article" microformats="h-entry" id="the-template-2014">
  7. <p id="category" class="p-category">
  8. <a href="/contribute/contribute.html">Contribute</a>
  9. </p>
  10. <h1 class="p-name">A template article, to use the new webdesign</h1>
  11. <div class="e-content">
  12. <p class="p-summary">
  13. So, you are publishing an article on Let’s have a look at
  14. this <a href="/source/contribute/template.en.xhtml">template page source code</a> to see how you can make use of the many
  15. features at your disposal with this new design!
  16. <a class="fn" id="ref-name-that-footnote" href="#fn-name-that-footnote">1</a>
  17. All code samples are pasted directly from the source file of this page.
  18. </p>
  19. <p>
  20. Just like before, web pages are built from xml source files.
  21. You can actually see the source code directly by clicking on the link
  22. at <a href="#source">the bottom of each page</a>. So there’s no big
  23. change here, go on to read more about the website in genral if you want
  24. to know more (there’s a link in the sidebar, on the right).
  25. </p>
  26. <h2>Page styling and metadata</h2>
  27. <p>
  28. The first thing with the new design are the <code>&#60;body&#62;</code>
  29. attributes. This page has:
  30. </p>
  31. <pre><code>&#60;body class="article" microformats="h-entry" id="the-template-2014"&#62;</code></pre>
  32. <p>
  33. A file can have more than one class and more than one microformats
  34. (separated by a space), but a file can only have one id. These
  35. attributes are very useful to have different kinds of styling depending
  36. on what kind of content we’re showing.
  37. </p>
  38. <p>
  39. For instance, the page <a href="/about/">About FSFE</a> is not an
  40. article, but one of the four main sections of the website. It’s a way
  41. to get to other pages relating to what FSFE is about. For this kind of
  42. pages, there are some specific styling (using <code>&#60;body
  43. class="subsite"&#62;</code>). In doubt, it’s always useful to find a
  44. page that’s as close as possible to what you have to edit, and see how
  45. this one is made. And of course, you can always <a
  46. href="">get in touch
  47. with the web team</a>. What’s more, all pages which are on
  48. have the wiki class, all pages on have the
  49. planet class, etc.
  50. </p>
  51. <p>
  52. So, all articles should have an "article" class. However, it is
  53. optional for them to have an id. If you put an id, please choose it
  54. carefully. Id can be very useful to apply very specific styling. If you
  55. need to write new CSS style for a page, please make sure to put an id
  56. and then use that id for the rules in the CSS files.
  57. </p>
  58. <p>
  59. Microformats attributes are both about style and about metadata of a
  60. page. To learn what microformats are, please read <a
  61. href=""></a>.
  62. This page, as most articles, news entries, event items, should have
  63. proper metadata and use microformats.
  64. If you are <em>not</em> going to use microformats markup inside a
  65. source file, there’s no need to enable them, so remove the
  66. "microformats" information from the &#60;body&#62; element.
  67. </p>
  68. <p>
  69. Articles should use the <a
  70. href="">h-entry
  71. microformat</a>. This page has:
  72. </p>
  73. <pre><code>&#60;body class="article" <strong>microformats="h-entry"</strong> id="the-template-2014"&#62;
  74. &#60;p id="category" class="p-category"&#62;
  75. &#60;a href="/contribute/contribute.html"&#62;Contribute&#60;/a&#62;
  76. &#60;/p&#62;
  77. &#60;h1 class="p-name"&#62;A template article, to use the new webdesign&#60;/h1&#62;
  78. &#60;div class="e-content"&#62;
  79. &#60;p class="p-summary"&#62;So, you are…
  80. &#60;/div&#62;&#60;!--/e-content--&#62;
  81. </code></pre>
  82. <p>
  83. The rest of the metadata (author, date, etc.) should be taken care of.
  84. But do not hesitate to use other h-entry classes in the body of the
  85. article, and <a
  86. href="">check
  87. their validity</a>. If you want to know more about how
  88. deals with other metadata like tags, author, dates, etc. you can read
  89. the <a href="/source/contribute/template.en.xhtml">source code of this page</a>. You should also <a
  90. href="/contribute/web/">read the how-to on tagging
  92. </p>
  93. <h2>The sidebar</h2>
  94. <aside>
  95. <p>
  96. By the way, did you notice that, if you inspect the HTML of this page
  97. as rendered in your web browser, each title automatically gets an id?
  98. That way you can easily <a href="#id-the-sidebar">link to a specific
  99. part</a> of a page on by using anchors. For example, the title
  100. above probably has <code>&#60;h2 id="<a
  101. href="#id-the-sidebar">id-the-sidebar</a>"&#62;The
  102. sidebar&#60;h2&#62;</code>
  103. </p>
  104. </aside>
  105. <pre><code>&#60;sidebar news="ilovefs" promo="about-fsfe"&#62;
  106. &#60;div id="related-content"&#62;
  107. &#60;h3&#62;Get involved&#60;/h3&#62;
  108. &#60;ul&#62;&#60;li&#62;&#60;a href="/contribute/web/web.html"&#62;Webmastering&#60;/a&#62;&#60;/li&#62;
  109. &#60;li&#62;&#60;a href="/contribute/editors/editors.html"&#62;Information for editors&#60;/a&#62;&#60;/li&#62;
  110. &#60;li&#62;&#60;a href="/contribute/contribute.html"&#62;Contribute&#60;/a&#62;&#60;/li&#62;&#60;/ul&#62;
  111. &#60;h4&#62;Ongoing campaigns&#60;/h4&#62;
  112. &#60;ul&#62;&#60;li&#62;&#60;a href="//"&#62;Document Freedom Day!&#60;/a&#62;&#60;/li&#62;&#60;/ul&#62;
  113. &#60;/div&#62;
  114. &#60;/sidebar&#62;
  115. </code></pre>
  116. <p>
  117. The sidebar is what’s showing on the right side of this very page (if
  118. your screen is large enough!). Articles should really have a sidebar
  119. and we encourage you to add things in it. They are useful to provide
  120. context to an article, and to give more things to read if somebody’s
  121. interested. So you should show related articles, and/or related
  122. campaigns if that makes sense. See the code above: you can write
  123. directly inside the <code>&#60;sidebar&#62;</code> elements.
  124. </p>
  125. <p>
  126. However, the sidebar is not just another place to write, it’s also a
  127. useful tool where we can automatically put stuff. So if you are very lazy,
  128. or if there’s nothing to write in, just write
  129. <code>&#60;sidebar&#62;</code> without anything in it, and the build system
  130. will automatically decide what to show for you. Note: the sidebar
  131. element should be after the body element, not within. It’s at the same
  132. place that timestamp, tags and translator elements.
  133. </p>
  134. <h3>Sidebar options</h3>
  135. <p>You can also give parameters to your sidebar. This page has the following sidebar parameters:</p>
  136. <pre><code>&#60;sidebar news="ilovefs" promo="about-fsfe"&#62;</code></pre>
  137. <p>The news value is <a href="/contribute/web/tagging.html">a tag</a>.
  138. It’s going to fetch some news items that match the given tag and display
  139. them in the sidebar. For matter of demonstration, this page displays links
  140. to news items with the "ilovefs" tag.</p>
  141. <p><strong>Note:</strong> The news feature of the sidebar is disabled until
  142. Nicolas finds a better way of building the tag. Your help is welcome!</p>
  143. <p>The promo parameter is a paragraph promoting one important aspect of
  144. FSFE. This page promotes the "about-fsfe" paragraph, which is a general
  145. paragraph about FSFE which is going to invite the user to go read the
  146. about-page. If you don’t want to show any promotional paragraph, set
  147. <code>promo="none"</code>. If you do not choose which paragraph to promote in
  148. your sidebar, the build system is going to default to one paragraph for
  149. you.</p>
  150. <p>These paragraphs should already be ready for translation like other
  151. generic parts of the website. For now, you can choose to promote among:</p>
  152. <ul>
  153. <li>about-fsfe (default)</li>
  154. <li>our-work</li>
  155. <li>support</li>
  156. <li>donate</li>
  157. <li>More to come… Do not hesitate to ask the web team to add one.</li>
  158. </ul>
  159. <h3>Table of contents</h3>
  160. <p>Right now, it’s not automated. But the sidebar should be very a nice place
  161. to add a table of contents, especially if you wrote a long article. More to
  162. come on that.</p>
  163. <h2>The follow-up</h2>
  164. <p>It’s important to help people engage and support FSFE and to make it
  165. easy for them. This is why we have the "followup" box. This box is the
  166. second section of each page on, which you can see below the
  167. license information of this page. Why is it at the bottom? The idea is
  168. that, if somebody reaches the end of an article on, it’s probably
  169. a very good sign that this person is interested! So we should engage with
  170. them, give them a way to follow up on that enthusiasm! By default, if you
  171. don’t put anything, the build system is going to insert a followup box for
  172. you. If you don’t want to show a followup box for some reason, then please
  173. write <code>&#60;followup&#62;no&#60;/followup&#62;</code>.</p>
  174. <p>This page chooses to help people engage by subscribing to our monthly
  175. newsletter. So, after the body element, it has:</p>
  176. <pre><code>&#60;followup&#62;subscribe-nl&#60;/followup&#62;</code></pre>
  177. <p>These boxes should already be ready for translation like other generic
  178. parts of the website. For now, you can choose to follow up on:</p>
  179. <ul>
  180. <li>"subscribe-nl" to subscribe to the newsletter</li>
  181. <li>"support" to sign as a supporter</li>
  182. <li>"donate" to make a one-time or recurrent donation</li>
  183. <li>"join" to promote joining the fellowship</li>
  184. </ul>
  185. <h2>Misc</h2>
  186. <p>If you need to add a quote, proceed as follows:</p>
  187. <blockquote>
  188. <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante hendrerit. Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean ut gravida lorem. Ut turpis felis, pulvinar a semper sed, adipiscing id dolor. Pellentesque auctor nisi id magna consequat sagittis. Curabitur dapibus enim sit amet elit pharetra tincidunt feugiat nisl imperdiet. Ut convallis libero in urna ultrices accumsan. Donec sed odio eros. Donec viverra mi quis quam pulvinar at malesuada arcu rhoncus. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. In rutrum accumsan ultricies. Mauris vitae nisi at sem facilisis semper ac in est.</p>
  189. <footer>
  190. – <cite>Cicero</cite>
  191. </footer>
  192. </blockquote>
  193. <p>Alternative, you can also <q cite="">quote an example inline</q> (the quotation marks will vary depending on the language).</p>
  194. <h2>An article would not be complete without a picture!</h2>
  195. <figure>
  196. <img
  197. src=""
  198. alt="group picture!"/>
  199. <figcaption>
  200. This is a picture from the Group coordinators meeting<br/>
  201. Berlin, September 2013
  202. </figcaption>
  203. </figure>
  204. <p>This is the source code for the example picture above:</p>
  205. <pre><code>
  206. &lt;figure>
  207. &lt;img
  208. src=""
  209. alt="group picture!"/>
  210. &lt;figcaption>
  211. This is a picture from the Group coordinators meeting&lt;br/>
  212. Berlin, September 2013
  213. &lt;/figcaption>
  214. &lt;/figure>
  215. </code></pre>
  216. <p>
  217. For left aligned captions, just add <code>class="text-left"</code> to the <code>figcaption</code> element.
  218. </p>
  219. <figure class="float-right">
  220. <img
  221. src=""
  222. alt="group picture!" />
  223. </figure>
  224. <p>
  225. You can also have figures left or right within the text flow.
  226. Just apply the classes <code>float-right</code> or <code>float-right</code> on them.
  227. </p>
  228. <p>
  229. Code for the inline image above:
  230. </p>
  231. <pre><code>
  232. &lt;figure class="float-right">
  233. &lt;img
  234. src=""
  235. alt="group picture!" />
  236. &lt;/figure>
  237. </code></pre>
  238. <h2>General design</h2>
  239. <p>Please avoid adding inline css styles in your css. Use css classes
  240. instead. If you need new classes, create new classes, or try to see if the
  241. current design does not already solve what you want to do! Also check with
  242. bootstrap if there’s not something standard to use. To understand how to
  243. edit the stylesheets of the new design, <a
  244. href="/contribute/web/css.html">head to the documentation</a>.</p>
  245. <p>The new design uses bootstrap. Visit <a
  246. href=""></a> for more
  247. information about that. This should allow you to have some nice things on
  248. pages now! However if you are doing something a bit out of the
  249. ordinary or if you are not sure of yourself, do not hesitate to <a
  250. href="">get in touch
  251. with the web team</a>.</p>
  252. <h2>Some notes on typography</h2>
  253. <p>Typography matters. Please, if you share my love for typography, letters, spaces and symboles, try to use curly quotes and real apostrophes. I know this article did not respect that rule and used "stright quotes" instead of “curly quotes” because I needed to imitate the source code in order not to confuse anyone. However, for most articles on there’s no need for this. Especially, since we use utf-8, there’s no reason not to put some utf-8 in our pages! ☺ </p>
  254. <h2>Other examples to take inspiration from</h2>
  255. <p>This template should get you going for most articles, i.e. pages which
  256. are mostly about “content”. However, not all pages are like that. So here’s
  257. a selection of well designed pages that should help you to get some
  258. inspiration from.</p>
  259. <p>
  260. If you have trouble producing the correct quotation marks for your language on your keyboard, look up the html escapes in
  261. <a href="">the wikipedia article</a> (or <a href="">unicode table</a>).
  262. </p>
  263. <ul>
  264. <li><a href="">Subsite pages</a> for navigating to different parts of the website.</li>
  265. <li><a href="">Press Releases</a></li>
  266. <li><a href="">Newsletters</a></li>
  267. <li><a href="">Personal Bio pages</a></li>
  268. <li><a href="">Country page</a></li>
  269. <li><a href="">Fellowship page</a> (You might also want to edit <code>/tools/menu-global.xml</code> and <code>/tools/texts-**.xml</code>)</li>
  270. </ul>
  271. <h2 id="fn">Footnotes</h2>
  272. <ol>
  273. <li id="fn-name-that-footnote">
  274. This is just a footnote! Please read <a href="/source/template.en.xhtml">the source code of this page</a> to see
  275. how footnotes should be made.
  276. <a href="#ref-name-that-footnote" class="ref">&#8617;</a></li>
  277. </ol>
  278. </div><!--/e-content-->
  279. </body>
  280. <tags>
  281. <tag>webmaster</tag>
  282. </tags>
  283. <sidebar news="ilovefs" promo="about-fsfe">
  284. <div id="related-content">
  285. <h3>Get involved</h3>
  286. <ul><li><a href="/contribute/web/web.html">Webmastering</a></li>
  287. <li><a href="/contribute/editors/editors.html">Information for editors</a></li>
  288. <li><a href="/contribute/contribute.html">Contribute</a></li></ul>
  289. <h4>Ongoing campaigns</h4>
  290. <ul><li><a href="//">Document Freedom Day!</a></li></ul>
  291. </div>
  292. </sidebar>
  293. <followup>subscribe-nl</followup>
  294. <timestamp>$Date: 2013-12-31 13:55:36 +0100 (Tue 31 Dec 2013) $ $Author: hugo $</timestamp>
  295. <date>
  296. <original content="2014-01-05" />
  297. <revision content="2014-01-06" />
  298. <revision content="2014-01-07" />
  299. </date>
  300. <!--Please help FSFE make the switch to Creative Commons: use this license for your publication:-->
  301. <legal type="cc-license">
  302. <license></license>
  303. <notice>This work is licensed under a Creative Commons Attribution 4.0 International License.</notice>
  304. </legal>
  305. <author id="roy" />
  306. <translator>Hugo Roy</translator>
  307. </html>