Prefer textile over markup because markup doesn't support any tables. bähh.

This commit is contained in:
Benjamin Meichsner 2009-05-20 13:03:58 +02:00
parent 7de45543c4
commit d371839eba
3 changed files with 11 additions and 9 deletions

View file

@ -1,7 +1,7 @@
module PagesHelper
def wikified_body(body)
r = BlueCloth.new(body)
r = RedCloth.new(body)
r.gsub!(/\[\[(.*?)(\|(.*?))?\]\]/) { wiki_link($1, $3) }
sanitize r.to_html
r.to_html

View file

@ -8,14 +8,16 @@
%br/
:plain
[[interner Link]]<br />
[externer Link](http://addresse.net)<br />
*kursiv*<br />
**Fett**<br />
* erster Listenpunkt<br />
* zweiter Listenpunkt<br />
"externer Link":http://addresse.net<br />
h1. Erste Überschrift<br />
h2. Unterüberschrift<br />
_kursiv_<br />
*Fett*<br />
# erster Listenpunkt<br />
# zweiter Listenpunkt<br />
## Unterpunkt<br />
%p
Übersicht über alle Formatierungen:
= link_to "Markdown Cheatsheet", "http://packetlife.net/static/cheatsheets/markdown.pdf", :target => '_blank'
= link_to "Tabellen, Styling, etc..", "http://hobix.com/textile/quick.html", :target => '_blank'
- form_for @page do |f|
= f.error_messages

View file

@ -68,7 +68,7 @@ Rails::Initializer.run do |config|
config.gem "fastercsv"
config.gem "prawn"
config.gem "haml", :version => '>=2.0.6'
config.gem 'BlueCloth', :lib => 'bluecloth'
config.gem 'RedCloth', :lib => 'redcloth'
# The internationalization framework can be changed to have another default locale (standard is :en) or more load paths.
# All files from config/locales/*.rb,yml are added automatically.