Welcome to GuardiansWorlds.com
 
 

  User Info Box

Anonymous
18.117.107.190
Nickname:

Password:

Security Code:
Security Code
Type Security Code:


User Stats:
Today: 0
Yesterday: 0
This Month: 0
This Year: 0
Total Users: 117
New Members:
Online Now:
  Guests: 29
18.117.xxx.xxx
172.69.xxx.xx
172.70.xx.xx
85.208.xx.xxx
143.110.xxx.xxx

  Total Online: 29
Server Time:
Apr 04, 2025
04:22 pm UTC
 

  Modules/Site Links

· Home
· Bible-MM
· Birds-MM
· Car_Show-MM
· Christmas-MM
· Content
· Domaining-MM
· Downloads
· Drugs-MM
· Event Calendar
· FAQ
· Feedback
· Fish-MM
· Gambling_Guide-MM
· Guardians Worlds Chat
· HTML_Manual
· Internet_Traffic_Report
· IP_Tracking Tool
· Journal
· Members List
· Movies-MM
· Music_Sound-MM
· NukeSentinel
· PHP-Nuke_Tools
· PHP_Manual-MM
· PING Tool
· Private Messages
· Recommend Us
· Reptiles-MM
· Search
· SEO_Tools
· Statistics
· Stories Archive
· Submit News
· Surveys
· Top 30
· Topics
· Visitor Mapping System
· Web Links
· Webcams
· Web_Development-MM
· YahooNews
· YahooPool
· Your Account
 

  Categories Menu

· All Categories
· Camaro and Firebird
· FTP Server
· New Camaro
· News
· Online Gaming
 

  Survey

Which is your favorite generation Camaro or Firebird?

1st Gen. 67-69 Camaro
2nd Gen. 70-81 Camaro
3rd Gen. 82-92 Camaro
4th Gen. A 93-97 Camaro
4th Gen. B 98-2002 Camaro
1st Gen. 67-69 Firebird
2nd Gen. 70-81 Firebird
3rd Gen. 82-92 Firebird
4th Gen. A 93-97 Firebird
4th Gen. B 98-2002 Firebird



Results
Polls

Votes: 66
Comments: 0
 

  Cluster Maps

Locations of visitors to this page
 

  Languages

Select Interface Language:

 

 
  swf_closefile

swf_closefile

(PHP 4, PECL)

swf_closefile -- Close the current Shockwave Flash file

Description

void swf_closefile ( [int return_file] )

Close a file that was opened by the swf_openfile() function. If the return_file parameter is set then the contents of the SWF file are returned from the function.

Example 1. Creating a simple flash file based on user input and outputting it and saving it in a database

<?php

// The $text variable is submitted by the
// user

// Global variables for database
// access (used in the swf_savedata() function)
$DBHOST = "localhost";
$DBUSER = "sterling";
$DBPASS = "secret";

swf_openfile("php://stdout", 256, 256, 30, 1, 1, 1);

    
swf_definefont(10, "Ligon-Bold");
        
swf_fontsize(12);
        
swf_fontslant(10);
    
    
swf_definetext(11, $text, 1);
    
    
swf_pushmatrix();
        
swf_translate(-50, 80, 0);
        
swf_placeobject(11, 60);
    
swf_popmatrix();

    
swf_showframe();
  
    
swf_startdoaction();
        
swf_actionstop();
    
swf_enddoaction();

$data = swf_closefile(1);

$data ?
  
swf_savedata($data) :
  die(
"Error could not save SWF file");

// void swf_savedata(string data)
// Save the generated file a database
// for later retrieval
function swf_savedata($data)
{
    global
$DBHOST,
           
$DBUSER,
           
$DBPASS;
    
    
$dbh = @mysql_connect($DBHOST, $DBUSER, $DBPASS);

    if (!
$dbh) {
        die (
sprintf("Error [%d]: %s",
                      
mysql_errno(), mysql_error()));
    }

    
$stmt = "INSERT INTO swf_files (file) VALUES ('$data')";

    
$sth = @mysql_query($stmt, $dbh);

    if (!
$sth) {
        die (
sprintf("Error [%d]: %s",
                      
mysql_errno(), mysql_error()));
    }

    @
mysql_free_result($sth);
    @
mysql_close($dbh);
}
?>

 
 


 
  Disipal DesignsAnti-Spam
All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest © 2002 by me.
You can syndicate our news using the file backend.php or ultramode.txt This site contains info,links,chat,message board/forum for online games,gaming,other features.Check out my servers and stats for Killing Floor, Quake3 Rocket Arenas & Deathmatch,Trade Wars 2002 & FTP server.Camaro/Firebirds, car info.