Support for adding dynamic flash files to php4

Source: Internet
Author: User
Source: wangzy, have you ever imagined to dynamically generate flash animations on your website? This article introduces you to the exciting age of php + flash. Php is really a good thing. it cannot be predicted what will happen tomorrow... Now let's get down to the point. next we will introduce how to implement this function. 1. required software swf support Library reality. sgi. comgraficaflashdist Source: wangzy
Have you ever imagined how to dynamically generate flash animations on your website? This article introduces you to the exciting age of php + flash.
Php is really a good thing. it cannot be predicted what will happen tomorrow... Okay, let's get down to the truth. below
Describes how to implement this function.

I. required software

Swf support Library
Http://reality.sgi.com/grafica/flash/dist.99.linux.tar.Z
There is a document in this package. you can use it in c. His example is.
This guy is great, but it would be better if he provided the source code.


And of course php4 got it from http://www.php.net

II. Installation

1. install libswf.
# Cp dist.99.linux.tar. Z/usr/local
# Tar xvzf dist.99.linux.tar. Z
# Cd dist
# Make
You will see the image.swfand test.swf files generated by the C program. you can view the results in the browser.
If it comes out, you will be half done.
You still need to do something
Add in/etc/profile
SWFBINPATH =/usr/local/dist/bin
Export SWFBINPATH
SWFFONTPATH =/usr/local/dist/fonts
Export SWFFONTPATH

2. compile php4
Compile and add
-- With-swf =/usr/local/dist
The swf. h error cannot be found during compilation.
# Cp/usr/local/dist/swf. h/php/src/directory/ext/swf solve the problem
After installation, make the following script (example in the php document). Note that the swf directory under the current directory must be
Write, or apache will go wrong and you will not be able to get anything



After the execution, use the browser to call the test.swf file. you will be surprised by the power of php.
I have no artistic mind :-(
There are two programs in/usr/local/dist/bin. imgtofi is used to convert rgb, gif, and jpg files to libswf..
Graph Format. pstoff converts the ps font to the available font of libswf. a. I have converted an English font and can
But it has not been converted into a Chinese font. I don't know which prawns have been successfully converted. can you tell me.
For the description of swf php functions, go to php.net to find the latest manual.

Source: e868
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: info-contact@alibabacloud.com 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.