WeberDev.com PHP and MySQL Code

LOG IN
BEGINNER GUIDES  |  PHP CLASSES  |  CODE SEARCH  |  ARTICLES SEARCH  |  PHP FORUMS  |  PHP MANUAL  |  PHP FUNCTIONS LIST  |  WEB SITE TEMPLATES
Start typing to search for PHP and MySQL Code Snippets and Articles Search
Submit a code Example / Snippet Submit Your Code
Search Engine Optimization Monitor SEO Monitor
Web Site UpTime Monitor UpTime Monitor
WeberDev's Monthly code contest PHP Code Contest
Your Personal Examples List My Favorite Examples
Your Personal Articles List My Favorite Articles
Edit Account Info Update Your Profile
PHP Code Search
Web Development Forums
Learn MySQL Playing Trivia
PHPBB2 Templates
Web Development Index
PHP Web Logs (BLogs)
Web Development Resources
Web Development Content
PHPClasses
PHP Editor
PHP Jobs
Vision.To Design
Ajax Tutorials
PHP Programming Help
PHP/MySQL Programming
Webmaster Resources
Webmaster Forum
XML meta language
website builder
Submit Site
Forex Trading Online forex trading platform

Go Back Add a Comment Send this example to a friend Add this Article to your personal favoritest for easy future access to your favorite Code Examples and Articles. Submit a code example Print this code example.
BACK ADD A COMMENT SEND TO A FRIEND ADD TO MY FAVORITES ADD CODE EXAMPLES PRINT
Title : phpflashcounter a php counter with flash as output
Categories : PHP, Flash Update Picture
idban secandri
Date : Aug 25th 2000
Grade : 2 of 5 (graded 4 times)
Viewed : 4582
File : No file for this code example.
Images : No Images for this code example.
Search : More code by idban secandri
Action : Grade This Code Example
Tools : My Examples List

  Submit your own code examples 
 

how it work?
first the counter run us usual, using a php script, i use my old simple text counter with litle
modification.

We got two php script to make this possible, one counting other showing, you can put it on
one file even on spreaded files.

Below this is the script that have function to add out counter;
<?
if (!$phpcounter) {
//set cookies, so our counter isnt growing, at last 1 hour
setcookie("phpcounter",lock,time()+3600);

//open out flat data counter
$file = fopen("/location/of/our/flat/data/count.txt","r+");

//read it
$count = fread($file, filesize("/location/of/our/flat/data/count.txt"));

//close the file
fclose($file);

//set variable to add 1
$count +=1;

//open again to add 1
$file = fopen("/location/of/our/flat/data/count.txt","w+");
fputs($file, $count);
fclose($file); }
?>

now we going to script that have function to show our counter let name it flacounter.php3
<?
$filename = "/home/idban/count.txt";

//open out flat data counter
$fd = fopen ($filename, "r");

//read it
$counter = fread ($fd, filesize ($filename));

//close the file
fclose ($fd);

//set variable to flacounter
$flacounter = "counter=";

//set variable flacounter as rawdata
$flacounter .= rawurlencode($counter);

//print it, you will got counter=number..
echo "$flacounter";
?>

After making that scripts, now stating to make the fla file
A. select your text, then...right klik
B. select properties


then make sure you name your text property same as variable that you had chosse on your script, we
use counter= ; so .. we name it counter


now go to action/frame, pointing to your text ( counter ) layer, as you know out layer named
guestnum, so we pick the guestnum, next step, just right klik on it
and select properties

A. select action,
B. push + simbol, ( C ) select Load Variable, fill with location of your script that showing the
counter, mine is http://php.klik.or.id/fla/flaconter.php3 so, put it on the URL ( E )
D. push + simbol, once again and add play
F. change variable to GET

Credits:
- Rasmus, Julie, Desy fatmawati,


Jakarta, 21 Agustus 2000, copyleft by idban secandri <idban@nospam.satunet.com>
sample and complete documentation available on http://php.klik.or.id/fla




Database Independent User Maintenance
Categories : PHP, Flash
Classic guest book made with PHP and Flash
Categories : PHP, Flash, Java Script
Query2Report : Generating Html, Pdf and Csv Reports from SQL Query
Categories : PHP, PHP, HTML, PDF, Excel
PHP Script to find url links in a page
Categories : PHP, URLs, Regexps, Arrays
Using $PHP_AUTH_USER and $PHP_AUTH_PW to authenticate.
Categories : Authentication, PHP
very simple ftp class
Categories : PHP, PHP Classes, FTP
PHP Paypal IPN Integration Class v1.0.0
Categories : PHP, PHP Classes, Payment Gateways
Function to remember password
Categories : PHP, Authentication, Personalization and Membership
Create Thumbnails - resize an image - jpeg, jpg, gif, png to the specifed width and height in proportion without loosing out on pixcel quality.
Categories : PHP, GD image library, Graphics
recode -- Recode a string according to a recode request
Categories : PHP, PHP Functions, Recode
a function that builds an HTML select list from any mysql table.
Categories : PHP, MySQL, HTML and PHP
Math operations on big numbers
Categories : PHP, Math.
phpAds, a complete banner and ad management system with detailled tracking and stats.
Categories : MySQL, Complete Programs, Ecommerce, PHP, Databases
Point and Click Interface ala MS Access for creating SQL statements.
Categories : MySQL, Complete Programs, General SQL, PHP, Databases
Tag content retrieval from websites with preg_match
Categories : PHP, Regexps, Arrays, HTML and PHP
 idban secandri wrote :450
http://php.klik.or.id cant resolve
u can use
http://klik.php.or.id/
http://phpklik.org/
http://php.linux.web.id/