Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion PHP-Counter resettet immer wieder
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Dr. Franz-Josef Huecker  
View profile   Translate to Translated (View Original)
 More options Feb 25 2011, 8:44 am
Newsgroups: de.comp.lang.php.misc
From: i...@huecker.com (Dr. Franz-Josef Huecker)
Date: Fri, 25 Feb 2011 13:44:20 GMT
Local: Fri, Feb 25 2011 8:44 am
Subject: Re: PHP-Counter resettet immer wieder
At Fri, 25 Feb 2011 11:33:22 +0100, Jens Fittig <invali...@gmx.de>
wrote:

> Hallo, ich nutze folgenden Code für einen Counter:

> function increase_save_count() {
>   if (!file_exists(PFAD."counter_files/count.txt")) {
>     error("no_counter_file");
>   } elseif (!is_writable(PFAD."counter_files/count.txt")) {
>     error("count_unwriteable");
>   } else {
>     $counts = file(PFAD."counter_files/count.txt");
>     $count  = trim($counts[0]);
>     $count++;
>     $fh = fopen(PFAD."counter_files/count.txt","wb");
>     flock($fh, LOCK_EX);
>     fwrite($fh, $count);
>     fclose($fh);

Hi Jens

Schau dir mal den Counter (siehe Link unten) an (Code und Beispiel).
Mit dem gab es nach meinem Kenntnisstand bisher noch keine Probleme
und vielleicht bekommst du dort eine Idee, wie du deinen Counter
optimieren kannst oder ersetzen.

Der aelteste Counter, den ich verwende - freilich in TCL, steht jetzt
bei 187095 (siehe Link unten) und ist durchaus vergleichbar, weil er
einen vergleichbaren Code verwendet..

Franz-Josef    

http://www.huecker.com/msw/php/php_man_f.shtml

http://www.nlp.de/exp_com/

--
 Dr. Franz-Josef Huecker
W3: http://www.huecker.com
 Email: i...@huecker.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.