You are here: Browse Railsplugins Svn
If you are using HTML, it is recommended you install:
gem install -r htmlentities
TCPDF Documentation located at:
http://phpdocs.moodle.org/com-tecnick-tcpdf/TCPDF.html
Example of simple use in .rhtml:
<% @pdf = TCPDF.new() @pdf.SetMargins(15, 27, 15); @pdf.AddPage(); text_options = {:font => “freeserif”} @pdf.draw_text(15, 10, “text”, {:font_size => 12, :font => “freeserif”}) ><=@pdf.Output()%>
See the following files for sample of useage:
test_unicode.rfpdf utf8test.txt logo_example.png
FPDF users can migrate to TCPDF by changing the following from:
pdf = FPDF.new
to:
pdf = TCPDF.new
ENJOY!
NOTE: This description has been extracted from the Plugin README and so the formatting may need updating to make browser friendly