]> git.mxchange.org Git - friendica.git/blobdiff - doc/BBCode.md
Fix formatting in mod/help
[friendica.git] / doc / BBCode.md
index aeb5e06c95cfecf8282b5598c7a8bc79f819de0b..946c61f247402448427399d479465cb66e00193d 100644 (file)
@@ -12,21 +12,22 @@ table.bbcodes {
     border: 1px solid #aaa;
     border-collapse: collapse;
     color: #000;
-       width: 100%;
+    width: 100%;
 }
 
 table.bbcodes > tr > th,
 table.bbcodes > tr > td,
 table.bbcodes > * > tr > th,
 table.bbcodes > * > tr > td {
-       border: 1px solid #aaa;
-       padding: 0.2em 0.4em
+    border: 1px solid #aaa;
+    padding: 0.2em 0.4em
 }
 
 table.bbcodes > tr > th,
 table.bbcodes > * > tr > th {
-       background-color: #f2f2f2;
-       text-align: center
+    background-color: #f2f2f2;
+    text-align: center;
+    width: 50%
 }
 </style>
 
@@ -60,17 +61,17 @@ table.bbcodes > * > tr > th {
   <td><span style="color:  red;">red</span></td>
 </tr>
 <tr>
-  <td>[url=http://www.friendica.com]Friendica[/url]</td>
-  <td><a href="http://www.friendica.com" target="external-link">Friendica</a></td>
+  <td>[url=http://friendi.ca]Friendica[/url]</td>
+  <td><a href="http://friendi.ca" target="external-link">Friendica</a></td>
 </tr>
 <tr>
-  <td>[img]http://friendica.com/sites/default/files/friendika-32.png[/img]</td>
-  <td><img src="http://friendica.com/sites/default/files/friendika-32.png" alt="Immagine/foto"></td>
+  <td>[img]https://raw.githubusercontent.com/friendica/friendica/master/images/friendica-32.jpg[/img]</td>
+  <td><img src="https://raw.githubusercontent.com/friendica/friendica/master/images/friendica-32.jpg" alt="Immagine/foto"></td>
 </tr>
 <tr>
-  <td>[img=64x32]http://friendica.com/sites/default/files/friendika-32.png[/img]<br>
+  <td>[img=64x32]https://raw.githubusercontent.com/friendica/friendica/master/images/friendica-32.jpg[/img]<br>
 <br>Note: provided height is simply discarded.</td>
-  <td><img src="http://friendica.com/sites/default/files/friendika-32.png" style="width: 64px;"></td>
+  <td><img src="https://raw.githubusercontent.com/friendica/friendica/master/images/friendica-32.jpg" style="width: 64px;"></td>
 </tr>
 <tr>
   <td>[size=xx-small]small text[/size]</td>
@@ -81,7 +82,7 @@ table.bbcodes > * > tr > th {
   <td><span style="font-size: xx-large;">big text</span></td>
 </tr>
 <tr>
-  <td>[size=20]exact size[/size] (size can be any number, in pixel)</td>
+  <td>[size=20]exact size[/size] (size can be any number, in pixels)</td>
   <td><span style="font-size: 20px;">exact size</span></td>
 </tr>
 <tr>
@@ -98,23 +99,23 @@ table.bbcodes > * > tr > th {
   <th>Result</th>
 </tr>
 <tr>
-  <td>[url]http://friendica.com[/url]</td>
-  <td><a href="http://friendica.com">http://friendica.com</a></td>
+  <td>[url]http://friendi.ca[/url]</td>
+  <td><a href="http://friendi.ca">http://friendi.ca</a></td>
 </tr>
 <tr>
-  <td>[url=http://friendica.com]Friendica[/url]</td>
-  <td><a href="http://friendica.com">Friendica</a></td>
+  <td>[url=http://friendi.ca]Friendica[/url]</td>
+  <td><a href="http://friendi.ca">Friendica</a></td>
 </tr>
 <tr>
-  <td>[bookmark]http://friendica.com[/bookmark]<br><br>
-#^[url]http://friendica.com[/url]</td>
-  <td><span class="oembed link"><h4>Friendica: <a href="http://friendica.com" rel="oembed"></a><a href="http://friendica.com" target="_blank">http://friendica.com</a></h4></span></td>
+  <td>[bookmark]http://friendi.ca[/bookmark]<br><br>
+#^[url]http://friendi.ca[/url]</td>
+  <td><span class="oembed link"><h4>Friendica: <a href="http://friendi.ca" rel="oembed"></a><a href="http://friendi.ca" target="_blank">http://friendi.ca</a></h4></span></td>
 </tr>
 <tr>
-  <td>[bookmark=http://friendica.com]Bookmark[/bookmark]<br><br>
-#^[url=http://friendica.com]Bookmark[/url]<br><br>
-#[url=http://friendica.com]^[/url][url=http://friendica.com]Bookmark[/url]</td>
-  <td><span class="oembed link"><h4>Friendica: <a href="http://friendica.com" rel="oembed"></a><a href="http://friendica.com" target="_blank">Bookmark</a></h4></span></td>
+  <td>[bookmark=http://friendi.ca]Bookmark[/bookmark]<br><br>
+#^[url=http://friendi.ca]Bookmark[/url]<br><br>
+#[url=http://friendi.ca]^[/url][url=http://friendi.ca]Bookmark[/url]</td>
+  <td><span class="oembed link"><h4>Friendica: <a href="http://friendi.ca" rel="oembed"></a><a href="http://friendi.ca" target="_blank">Bookmark</a></h4></span></td>
 </tr>
 <tr>
   <td>[url=/posts/f16d77b0630f0134740c0cc47a0ea02a]Diaspora post with GUID[/url]</td>
@@ -164,7 +165,7 @@ line
 code</code></td>
 </tr>
 <tr>
-  <td>[code=php]function text_highlight($s,$lang)[/code]</td>
+  <td>[code=php]function text_highlight($s,$lang)[/code]<sup><a href="#supported-code">1</a></sup></td>
   <td><code><div class="hl-main"><ol class="hl-main"><li><span class="hl-code">&nbsp;</span><span class="hl-reserved">function</span><span class="hl-code"> </span><span class="hl-identifier">text_highlight</span><span class="hl-brackets">(</span><span class="hl-var">$s</span><span class="hl-code">,</span><span class="hl-var">$lang</span><span class="hl-brackets">)</span></li></ol></div></code></td>
 </tr>
 <tr>
@@ -207,6 +208,27 @@ code</code></td>
 </tr>
 </table>
 
+<a name="supported-code">1</a>: Supported language parameter values for code highlighting:
+- abap
+- avrc
+- cpp
+- css
+- diff
+- dtd
+- html
+- java
+- javascript
+- js
+- mysql
+- perl
+- php
+- python
+- ruby
+- sh
+- sql
+- vbscript
+- xml
+
 ### Titles
 
 <table class="bbcodes">
@@ -472,6 +494,10 @@ You can embed video, audio and more in a message.
   <td>[vimeo]Vimeo video ID[/vimeo]</td>
   <td>Vimeo player iframe embed.</td>
 </tr>
+<tr>
+  <td>[embed]URL[/embed]</td>
+  <td>Embed OEmbed rich content.</td>
+</tr>
 <tr>
   <td>[iframe]URL[/iframe]</td>
   <td>General embed, iframe size is limited by the theme size for video players.</td>
@@ -485,8 +511,8 @@ Page title with a link to *url* will be shown.</td>
 
 ## Map
 
-This require "openstreetmap" addon version 1.3 or newer. If the addon isn't activated,
-the raw coordinates are shown instead.
+This requires "openstreetmap" or "Google Maps" addon version 1.3 or newer.
+If the addon isn't activated, the raw coordinates are shown instead.
 
 <table class="bbcodes">
 <tr>
@@ -509,10 +535,10 @@ the raw coordinates are shown instead.
 
 ## Abstract for longer posts
 
-If you want to spread your post to several third party networks you can have the problem that these networks have a length limitation like on Twitter.
+If you want to spread your post to several third party networks you may have the problem that these networks have a length limitation like on Twitter.
 
-Friendica is using a semi intelligent mechanism to generate a fitting abstract.
-But it can be interesting to define a custom abstract that will only be displayed on the external network.
+Friendica uses a semi-intelligent mechanism to generate a fitting abstract.
+But it can be useful to define a custom abstract that will only be displayed on the external network.
 This is done with the [abstract]-element.
 <table class="bbcodes">
 <tr>
@@ -522,8 +548,8 @@ This is done with the [abstract]-element.
 <tr>
   <td>[abstract]Totally interesting! A must-see! Please click the link![/abstract]<br>
 I want to tell you a really boring story that you really never wanted to hear.</td>
-  <td>Twitter would display the text "Totally interesting! A must-see! Please click the link!".
-On Friendica you would only see the text after "I want to tell you a really ..."</td>
+  <td>Twitter would display the text <blockquote>Totally interesting! A must-see! Please click the link!</blockquote>
+On Friendica you would only see the text after <blockquote>I want to tell you a really ...</blockquote></td>
 </tr>
 </table>
 
@@ -543,7 +569,7 @@ pictures?[/abstract]<br>
 that I wanted to share with you.[/abstract]<br>
 Today I was in the woods and took some real cool pictures ...</td>
   <td>For Twitter and App.net the system will use the defined abstracts.<br>
-For other networks (e.g. when you are using the "statusnet" connector that is used to post to GNU Social) the general abstract element will be used.</td>
+For other networks (e.g. when you are using the "statusnet" connector that is used to post to your GNU Social account) the general abstract element will be used.</td>
 </tr>
 </table>
 
@@ -561,7 +587,7 @@ Instead you have to name the explicit network:
 <tr>
   <td>
 [abstract]These days I had a strange encounter...[/abstract]<br>
-[abstract=goog]Helly my dear Google+ followers. You have to read my newest blog post![/abstract]<br>
+[abstract=goog]Hello my dear Google+ followers. You have to read my newest blog post![/abstract]<br>
 [abstract=face]Hello my Facebook friends. These days happened something really cool.[/abstract]<br>
 While taking pictures in the woods I had a really strange encounter...</td>
   <td>Google and Facebook will show the respective abstracts while the other networks will show the default one.<br>
@@ -569,7 +595,8 @@ While taking pictures in the woods I had a really strange encounter...</td>
 </tr>
 </table>
 
-The [abstract] element isn't working with the native OStatus connection or with connectors where we post the HTML like Tumblr, Wordpress or Pump.io.
+The [abstract] element is not working with connectors where we post HTML directly, like Tumblr, Wordpress or Pump.io.
+For the native connections--that is to e.g. Friendica, Hubzilla, Diaspora or GNU Social--the full posting is used and the contacts instance will display the posting as desired.
 
 ## Special
 
@@ -579,7 +606,7 @@ The [abstract] element isn't working with the native OStatus connection or with
   <th>Result</th>
 </tr>
 <tr>
-  <td>If you need to put literal bbcode in a message, [noparse], [nobb] or [pre] are used to escape bbcode:<br>
+  <td>If you need to put literal bbcode in a message, [noparse], [nobb] or [pre] are used to escape bbcode:
     <ul>
       <li>[noparse][b]bold[/b][/noparse]</li>
       <li>[nobb][b]bold[/b][/nobb]</li>
@@ -608,4 +635,3 @@ The [abstract] element isn't working with the native OStatus connection or with
   <td><pre>&lt;span class="custom"&gt;If the class exists,<br> this block will have the custom class<br> style applied.&lt;/span&gt;</pre></td>
 </tr>
 </table>
-