Baidu Library Solution

Source: Internet
Author: User

To meet the company's needs, we need to implement something similar to Baidu Library.

The key technology lies in converting documents into swf and displaying

I found a lot of references on the Internet and summarized several feasible solutions:

1. Print2flash commercial software. Features are very powerful, customizable, and stable. You can directly convert documents such as office and PDF into swf files with browser frameworks. The only drawback is that it is charged, and no cracking method is found. There is a serial number, but the serial number version function is limited. It is not suitable for document conversion through code.

2. FlashPaper. Same as above, you can directly convert documents such as office and PDF into swf files with browser frameworks. It's just that you cannot create skin, watermarks, and other things. The speed is slow and unstable.

3. The final solution is to convert the office document to PDF, convert it to swf through pdf, and use flex to create a swf file for browsing the framework.

The required environment is:

1. adobe acrobat 9. Convert to PDF File

2. office2007. When converting an office file to a pdf file, the office functions are indispensable except for acrobat.

3. swftools. Open-source tools that Convert PDF files into SWF files

4. In the vs2010 development environment, develop a command tool through. net, call the function of the acrobat library, and convert the office using the command line method. The code is actually implemented in 10 or more lines.



1. install adobe acrobat 9, office2007, swftools, and other software

2. Use vs2010 to develop a command line tool and call acrobat's mongomakerapi. dll for conversion.

3. upload documents on the PHP page and perform conversion in the background. A problem occurs here. If the developed tool is called in windows cmd window, it can be converted correctly. However, it cannot generate the target pdf by using the exec command of php. According to the analysis, PHP has insufficient permissions. Modify the user who started the apache service to have high permissions. The conversion is successful.

4.swf tools to Convert pdf to swf. Note that you need to add the-T 9 parameter. Otherwise, the generated SWF format will be in AVM1Movie format, which cannot be controlled through swfloader in flex.

5. using flex to develop a loading framework swf, this swf can customize the appearance, watermark, etc. The key technology is to load the content swf through swfloader, and then gotoAndStop () each frame, move the content of each frame to a container, which is a page. That is, each frame generates a page, adds it to a VGroup, and puts it in a scroler to implement scrolling.


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.