Beefy Boxes and Bandwidth Generously Provided by pair Networks RobOMonk
more useful options
 
PerlMonks  

[OT] Update data file on accessing sound file

by jonnyfolk (Vicar)
on May 08, 2010 at 17:01 UTC ( #839032=perlquestion: print w/ replies, xml ) Need Help??
jonnyfolk has asked for the wisdom of the Perl Monks concerning the following question:

I've written a script which updates a data file then prints a web page with an embedded sound file. However it seems that the iphone won't directly play an embedded sound file.

I'm wondering if I call the sound file directly how I might generate the change to the data file as the sound file is accessed. Perhaps I could use .htaccess?

I'd br grateful for any ideas

Comment on [OT] Update data file on accessing sound file
Re: [OT] Update data file on accessing sound file
by Anonymous Monk on May 08, 2010 at 17:04 UTC
    I'd br grateful for any ideas

    Take it to an iphone forum, thanks ;)

      If it was a question about the iphone that would indeed be a good thing to do. However it's a question about updating files on a server, of which there is much expertise on this forum...

        iphone won't directly play an embedded sound file.

        Iphone is a kind of server?

Re: [OT] Update data file on accessing sound file
by amedico (Sexton) on May 09, 2010 at 17:28 UTC
    You could serve the sound file through a CGI script (e.g. "http://myserver/cgi-bin/getfile.pl?file=sound.mp3") and have the script increment some persistent counter every time it serves the file.
Re: (no longer [OT]) Update data file on accessing sound file
by ww (Bishop) on May 09, 2010 at 21:54 UTC
    Yup, gotta' agree with amedico!

    Forget embedding.

    Put the music file on the server, use cgi to start it playing and to "generate the change to the data file...."

    And now a question back: is this "change to the data file" something more complex than incrementing a counter and perhaps tracking user info (like IP, browser, etc)?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://839032]
Approved by planetscape
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (8)
As of 2014-04-20 11:08 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (485 votes), past polls