实例介绍
我在是网上下载的dompdf,然后自己安装了一个msyh中文字体, 并且,在encoding_unicode.html文件里面,body的样式,里面加上了msyh字体 编码不变,还是utf8编码 现在在Examples里面的 [HTML] [PDF] unicode 实例中,可以实现中文了, 如果你想在demo里面实现自定义的中文,请将浏览器的网页编码改成utf8,我的网页好似默认是gbk的,现在好了
【实例截图】
【核心代码】
dompdf.rar
└── dompdf
├── changelog.txt
├── docblox.dist.xml
├── dompdf_config.custom.inc.php
├── dompdf_config.inc.php
├── dompdf.php
├── include
│ ├── absolute_positioner.cls.php
│ ├── abstract_renderer.cls.php
│ ├── attribute_translator.cls.php
│ ├── autoload.inc.php
│ ├── block_frame_decorator.cls.php
│ ├── block_frame_reflower.cls.php
│ ├── block_positioner.cls.php
│ ├── block_renderer.cls.php
│ ├── cached_pdf_decorator.cls.php
│ ├── canvas.cls.php
│ ├── canvas_factory.cls.php
│ ├── cellmap.cls.php
│ ├── cpdf_adapter.cls.php
│ ├── css_color.cls.php
│ ├── dompdf.cls.php
│ ├── dompdf_exception.cls.php
│ ├── dompdf_image_exception.cls.php
│ ├── file.skel
│ ├── fixed_positioner.cls.php
│ ├── font_metrics.cls.php
│ ├── frame.cls.php
│ ├── frame_decorator.cls.php
│ ├── frame_factory.cls.php
│ ├── frame_reflower.cls.php
│ ├── frame_tree.cls.php
│ ├── functions.inc.php
│ ├── gd_adapter.cls.php
│ ├── image_cache.cls.php
│ ├── image_frame_decorator.cls.php
│ ├── image_frame_reflower.cls.php
│ ├── image_renderer.cls.php
│ ├── inline_frame_decorator.cls.php
│ ├── inline_frame_reflower.cls.php
│ ├── inline_positioner.cls.php
│ ├── inline_renderer.cls.php
│ ├── javascript_embedder.cls.php
│ ├── line_box.cls.php
│ ├── list_bullet_frame_decorator.cls.php
│ ├── list_bullet_frame_reflower.cls.php
│ ├── list_bullet_image_frame_decorator.cls.php
│ ├── list_bullet_positioner.cls.php
│ ├── list_bullet_renderer.cls.php
│ ├── null_frame_decorator.cls.php
│ ├── null_frame_reflower.cls.php
│ ├── null_positioner.cls.php
│ ├── page_cache.cls.php
│ ├── page_frame_decorator.cls.php
│ ├── page_frame_reflower.cls.php
│ ├── pdflib_adapter.cls.php
│ ├── php_evaluator.cls.php
│ ├── positioner.cls.php
│ ├── renderer.cls.php
│ ├── style.cls.php
│ ├── stylesheet.cls.php
│ ├── table_cell_frame_decorator.cls.php
│ ├── table_cell_frame_reflower.cls.php
│ ├── table_cell_positioner.cls.php
│ ├── table_cell_renderer.cls.php
│ ├── table_frame_decorator.cls.php
│ ├── table_frame_reflower.cls.php
│ ├── table_row_frame_decorator.cls.php
│ ├── table_row_frame_reflower.cls.php
│ ├── table_row_group_frame_decorator.cls.php
│ ├── table_row_group_frame_reflower.cls.php
│ ├── table_row_group_renderer.cls.php
│ ├── table_row_positioner.cls.php
│ ├── tcpdf_adapter.cls.php
│ ├── text_frame_decorator.cls.php
│ ├── text_frame_reflower.cls.php
│ └── text_renderer.cls.php
├── index.php
├── lib
│ ├── class.pdf.php
│ ├── fonts
│ │ ├── 2357f5ae6680924965fce5756011a117.ttf
│ │ ├── 2357f5ae6680924965fce5756011a117.ufm
│ │ ├── 63868d4e96cf0832d1bdb902e8abe5f8.ttf
│ │ ├── 63868d4e96cf0832d1bdb902e8abe5f8.ufm
│ │ ├── 63868d4e96cf0832d1bdb902e8abe5f8.ufm.php
│ │ ├── b80bb7b119bc77901b3629cc1f40a68c.ttf
│ │ ├── b80bb7b119bc77901b3629cc1f40a68c.ufm
│ │ ├── b80bb7b119bc77901b3629cc1f40a68c.ufm.php
│ │ ├── c130fcbbad0837c4642a3d90f7c971c2.ttf
│ │ ├── c130fcbbad0837c4642a3d90f7c971c2.ufm
│ │ ├── ce19c941412056a3e1058ee2f06740de.ttf
│ │ ├── ce19c941412056a3e1058ee2f06740de.ufm
│ │ ├── Courier.afm
│ │ ├── Courier-Bold.afm
│ │ ├── Courier-BoldOblique.afm
│ │ ├── Courier-Oblique.afm
│ │ ├── d25acc09bd0952bc15fcc35d363ee13a.ttf
│ │ ├── d25acc09bd0952bc15fcc35d363ee13a.ufm
│ │ ├── DejaVuSans-BoldOblique.ttf
│ │ ├── DejaVuSans-BoldOblique.ufm
│ │ ├── DejaVuSans-Bold.ttf
│ │ ├── DejaVuSans-Bold.ufm
│ │ ├── DejaVuSansCondensed-BoldOblique.ttf
│ │ ├── DejaVuSansCondensed-BoldOblique.ufm
│ │ ├── DejaVuSansCondensed-Bold.ttf
│ │ ├── DejaVuSansCondensed-Bold.ufm
│ │ ├── DejaVuSansCondensed-Oblique.ttf
│ │ ├── DejaVuSansCondensed-Oblique.ufm
│ │ ├── DejaVuSansCondensed.ttf
│ │ ├── DejaVuSansCondensed.ufm
│ │ ├── DejaVuSans-ExtraLight.ttf
│ │ ├── DejaVuSans-ExtraLight.ufm
│ │ ├── DejaVuSansMono-BoldOblique.ttf
│ │ ├── DejaVuSansMono-BoldOblique.ufm
│ │ ├── DejaVuSansMono-Bold.ttf
│ │ ├── DejaVuSansMono-Bold.ufm
│ │ ├── DejaVuSansMono-Oblique.ttf
│ │ ├── DejaVuSansMono-Oblique.ufm
│ │ ├── DejaVuSansMono.ttf
│ │ ├── DejaVuSansMono.ufm
│ │ ├── DejaVuSans-Oblique.ttf
│ │ ├── DejaVuSans-Oblique.ufm
│ │ ├── DejaVuSans.ttf
│ │ ├── DejaVuSans.ufm
│ │ ├── DejaVuSerif-BoldItalic.ttf
│ │ ├── DejaVuSerif-BoldItalic.ufm
│ │ ├── DejaVuSerif-Bold.ttf
│ │ ├── DejaVuSerif-Bold.ufm
│ │ ├── DejaVuSerifCondensed-BoldItalic.ttf
│ │ ├── DejaVuSerifCondensed-BoldItalic.ufm
│ │ ├── DejaVuSerifCondensed-Bold.ttf
│ │ ├── DejaVuSerifCondensed-Bold.ufm
│ │ ├── DejaVuSerifCondensed-Italic.ttf
│ │ ├── DejaVuSerifCondensed-Italic.ufm
│ │ ├── DejaVuSerifCondensed.ttf
│ │ ├── DejaVuSerifCondensed.ufm
│ │ ├── DejaVuSerif-Italic.ttf
│ │ ├── DejaVuSerif-Italic.ufm
│ │ ├── DejaVuSerif.ttf
│ │ ├── DejaVuSerif.ufm
│ │ ├── dompdf_font_family_cache.dist.php
│ │ ├── Helvetica.afm
│ │ ├── Helvetica.afm.php
│ │ ├── Helvetica-Bold.afm
│ │ ├── Helvetica-BoldOblique.afm
│ │ ├── Helvetica-Oblique.afm
│ │ ├── log.htm
│ │ ├── mustRead.html
│ │ ├── Symbol.afm
│ │ ├── Times-Bold.afm
│ │ ├── Times-BoldItalic.afm
│ │ ├── Times-Italic.afm
│ │ ├── Times-Roman.afm
│ │ ├── Times-Roman.afm.php
│ │ └── ZapfDingbats.afm
│ ├── html5lib
│ │ ├── Data.php
│ │ ├── InputStream.php
│ │ ├── named-character-references.ser
│ │ ├── Parser.php
│ │ ├── Tokenizer.php
│ │ └── TreeBuilder.php
│ ├── php-font-lib
│ │ ├── classes
│ │ │ ├── adobe_font_metrics.cls.php
│ │ │ ├── encoding_map.cls.php
│ │ │ ├── font_binary_stream.cls.php
│ │ │ ├── font.cls.php
│ │ │ ├── font_eot.cls.php
│ │ │ ├── font_header.cls.php
│ │ │ ├── font_opentype.cls.php
│ │ │ ├── font_opentype_table_directory_entry.cls.php
│ │ │ ├── font_table.cls.php
│ │ │ ├── font_table_cmap.cls.php
│ │ │ ├── font_table_directory_entry.cls.php
│ │ │ ├── font_table_glyf.cls.php
│ │ │ ├── font_table_head.cls.php
│ │ │ ├── font_table_hhea.cls.php
│ │ │ ├── font_table_hmtx.cls.php
│ │ │ ├── font_table_kern.cls.php
│ │ │ ├── font_table_loca.cls.php
│ │ │ ├── font_table_maxp.cls.php
│ │ │ ├── font_table_name.cls.php
│ │ │ ├── font_table_name_record.cls.php
│ │ │ ├── font_table_os2.cls.php
│ │ │ ├── font_table_post.cls.php
│ │ │ ├── font_truetype.cls.php
│ │ │ ├── font_truetype_collection.cls.php
│ │ │ ├── font_truetype_header.cls.php
│ │ │ ├── font_truetype_table_directory_entry.cls.php
│ │ │ ├── font_woff.cls.php
│ │ │ ├── font_woff_header.cls.php
│ │ │ └── font_woff_table_directory_entry.cls.php
│ │ └── maps
│ │ ├── adobe-standard-encoding.map
│ │ ├── cp1250.map
│ │ ├── cp1251.map
│ │ ├── cp1252.map
│ │ ├── cp1253.map
│ │ ├── cp1254.map
│ │ ├── cp1255.map
│ │ ├── cp1257.map
│ │ ├── cp1258.map
│ │ ├── cp874.map
│ │ ├── iso-8859-11.map
│ │ ├── iso-8859-15.map
│ │ ├── iso-8859-16.map
│ │ ├── iso-8859-1.map
│ │ ├── iso-8859-2.map
│ │ ├── iso-8859-4.map
│ │ ├── iso-8859-5.map
│ │ ├── iso-8859-7.map
│ │ ├── iso-8859-9.map
│ │ ├── koi8-r.map
│ │ └── koi8-u.map
│ └── res
│ ├── broken_image.png
│ └── html.css
├── LICENSE.LGPL
├── load_font.php
├── readme.html
└── www
├── controller.php
├── cssSandpaper
│ ├── css
│ │ └── reset.css
│ └── js
│ ├── cssQuery-p.js
│ ├── cssSandpaper.js
│ ├── EventHelpers.js
│ └── jcoglan.com
│ └── sylvester.js
├── debugger.php
├── demo.php
├── examples.php
├── fonts.php
├── foot.inc
├── functions.inc.php
├── head.inc
├── images
│ ├── arrow_01.gif
│ ├── arrow_02.gif
│ ├── arrow_03.gif
│ ├── arrow_04.gif
│ ├── arrow_05.gif
│ ├── arrow_06.gif
│ ├── css2.png
│ ├── dompdf_simple.png
│ ├── favicon.ico
│ ├── favicon.png
│ ├── h_bar.gif
│ ├── left_arrow.gif
│ ├── logo.png
│ ├── logo.xcf
│ ├── php5-power-micro.png
│ ├── small_logo.png
│ ├── star_01.gif
│ ├── star_02.gif
│ ├── star_03.gif
│ ├── star_04.gif
│ ├── star_05.gif
│ ├── title.gif
│ ├── v_bar.gif
│ └── xhtml10.png
├── index.php
├── jquery-1.4.2.js
├── setup.php
├── style.css
└── test
├── backgroundcolor_fontdecoration_pageborder.html
├── css
│ ├── common.css
│ ├── importabs.css
│ ├── importall.css
│ ├── importdisplay.css
│ ├── importprint.css
│ ├── importsub.css
│ ├── linkall.css
│ ├── linkdefault.css
│ ├── linkdisplay.css
│ ├── linkprint.css
│ └── print_static.css
├── css_2d_transforms.html
├── css_at_font_face.html
├── css_baseline.html
├── css_border.html
├── css_color_cmyk.html
├── css_content.html
├── css_float.html
├── css_font_selection.html
├── css_important_flag.html
├── css_letter_spacing.html
├── css_line_height.html
├── css_margin.html
├── css_media.html
├── css_multiple_class.html
├── css_nth_child.html
├── css_opacity.html
├── css_outline.html
├── css_overflow_hidden.html
├── css_position_absolute.html
├── css_position_all.html
├── css_position_fixed.html
├── css_selectors.html
├── css_table_height.html
├── css_text_align.html
├── css_vertical_align.html
├── css_vertical_align_w3.html
├── css_whitespace.html
├── css_word_wrap.html
├── css_z_index.html
├── demo_01.html
├── dom_anchor_link.html
├── dom_br.html
├── dom_large_table.html
├── dom_long_table.php
├── dom_nbsp.html
├── dom_nested_table.html
├── dom_ol.html
├── dom_simple_ul.html
├── dom_table.html
├── dom_table_image.html
├── dom_ul.html
├── encoding_entities.html
├── encoding_latin1.html
├── encoding_special.html
├── encoding_symbols.html
├── encoding_unicode.html
├── encoding_unicode_wrapping.html
├── encoding_utf-8_all.html
├── encoding_utf-8.html
├── encoding_utf-8_w3.html
├── image_background.html
├── image_basic.html
├── image_bmp.html
├── image_datauri.html
├── image_dimensions.html
├── image_gif.html
├── image_remote.html
├── images
│ ├── bmp
│ │ ├── test16bf555.bmp
│ │ ├── test16bf555.png
│ │ ├── test16bf565.bmp
│ │ ├── test16bf565.png
│ │ ├── test16.bmp
│ │ ├── test16.png
│ │ ├── test1.bmp
│ │ ├── test1.png
│ │ ├── test24.bmp
│ │ ├── test24.png
│ │ ├── test32bf.bmp
│ │ ├── test32bf.png
│ │ ├── test32bfv4.bmp
│ │ ├── test32bfv4.png
│ │ ├── test32.bmp
│ │ ├── test32.png
│ │ ├── test32v5.bmp
│ │ ├── test32v5.png
│ │ ├── test4.bmp
│ │ ├── test4os2v2.bmp
│ │ ├── test4os2v2.png
│ │ ├── test4.png
│ │ ├── test8.bmp
│ │ ├── test8os2.bmp
│ │ ├── test8os2.png
│ │ ├── test8.png
│ │ ├── testcompress4.bmp
│ │ ├── testcompress4.png
│ │ ├── testcompress8.bmp
│ │ ├── testcompress8.png
│ │ ├── trans.bmp
│ │ └── trans.png
│ ├── cmyk_test2.jpg
│ ├── dokuwiki-128.png
│ ├── dompdf_simple.png
│ ├── goldengate.jpg
│ ├── green.gif
│ ├── grid-36.gif
│ ├── html.png
│ ├── no_extension
│ ├── pdf.png
│ ├── php.gif
│ ├── png
│ │ ├── gray16a_bk.png
│ │ ├── gray16a.png
│ │ ├── gray16b_bk.png
│ │ ├── gray16b.png
│ │ ├── gray8a_bk.png
│ │ ├── gray8a.png
│ │ ├── gray8b_bk.png
│ │ ├── gray8b.png
│ │ ├── pal_bk_notrns.png
│ │ ├── pal_bk.png
│ │ ├── palb.png
│ │ ├── pal.png
│ │ ├── result_16ns.gif
│ │ ├── result_1trns.gif
│ │ ├── resultb_bla.gif
│ │ ├── resultb_bug.gif
│ │ ├── result_bla.gif
│ │ ├── resultb_mag.gif
│ │ ├── resultb_moz2.gif
│ │ ├── resultb_no.gif
│ │ ├── resultb_ok.gif
│ │ ├── resultb_whi.gif
│ │ ├── resultb_yel.gif
│ │ ├── result_dith.gif
│ │ ├── resultga.gif
│ │ ├── resultgb_dgr.gif
│ │ ├── resultgb.gif
│ │ ├── resultg_bla.gif
│ │ ├── resultgb_no.gif
│ │ ├── resultg_dgr.gif
│ │ ├── resultg_lgr.gif
│ │ ├── resultg_no.gif
│ │ ├── result_gra.gif
│ │ ├── result_mag.gif
│ │ ├── result_magthr1.gif
│ │ ├── result_no.gif
│ │ ├── result_nsbug.gif
│ │ ├── result_ok.gif
│ │ ├── result_oprbug.gif
│ │ ├── resultpb_no.gif
│ │ ├── result_thr128.gif
│ │ ├── result_thr1.gif
│ │ ├── result_thr255.gif
│ │ ├── result_whi.gif
│ │ ├── result_yel.gif
│ │ ├── result_yelthr1.gif
│ │ ├── rgb16_t_bk.png
│ │ ├── rgb16_t.png
│ │ ├── rgb8_t_bk.png
│ │ ├── rgb8_t.png
│ │ ├── rgba16_bk.png
│ │ ├── rgba16.png
│ │ ├── rgba8_bk.png
│ │ ├── rgba8.png
│ │ └── stripe.gif
│ ├── png.png
│ ├── smiley.png
│ ├── unknown_extension.foo
│ ├── vblank.gif
│ └── what_ordered.gif
├── image_transparent_gif.html
├── image_transparent_png.html
├── image_variants.html
├── page_pages.html
├── quirks_center_table.html
├── quirks_font_tag.html
├── quirks_html_attributes.html
├── script_javascript.html
└── script_php.php
20 directories, 434 files
标签:
小贴士
感谢您为本站写下的评论,您的评论对其它用户来说具有重要的参考价值,所以请认真填写。
- 类似“顶”、“沙发”之类没有营养的文字,对勤劳贡献的楼主来说是令人沮丧的反馈信息。
- 相信您也不想看到一排文字/表情墙,所以请不要反馈意义不大的重复字符,也请尽量不要纯表情的回复。
- 提问之前请再仔细看一遍楼主的说明,或许是您遗漏了。
- 请勿到处挖坑绊人、招贴广告。既占空间让人厌烦,又没人会搭理,于人于己都无利。
关于好例子网
本站旨在为广大IT学习爱好者提供一个非营利性互相学习交流分享平台。本站所有资源都可以被免费获取学习研究。本站资源来自网友分享,对搜索内容的合法性不具有预见性、识别性、控制性,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,平台无法对用户传输的作品、信息、内容的权属或合法性、安全性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论平台是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二与二十三条之规定,若资源存在侵权或相关问题请联系本站客服人员,点此联系我们。关于更多版权及免责申明参见 版权及免责申明
网友评论
我要评论