PHP Coding
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Codewalkers ForumsPHP RelatedPHP Coding

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Codewalkers Forums Sponsor:
  #1  
Old September 4th, 2002, 05:59 PM
jaming jaming is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: brooklyn, New York, United States
Posts: 1 jaming User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via ICQ to jaming Send a message via AIM to jaming Send a message via Yahoo to jaming
adding data from the web browsers address bar to a .csv file

Hi I am looking for help with a script and have no idea where to start.

it's a simple script:

in a web browser address bar
you would type in something like http://site.com/script.php?release;user;files;bits;genre;size;date
and it would add a line to a comma delimited text file from the entry
at the bottom of the file


If anyone could write a quick script that does this or has seen one please let me know. -thx

Reply With Quote
  #2  
Old September 4th, 2002, 06:22 PM
Matt Matt is offline
Contributing User
Codewalkers Specialist (4000 - 4499 posts)
 
Join Date: Apr 2007
Location: Florida
Posts: 4,158 Matt User rank is Private First Class (20 - 50 Reputation Level)Matt User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 4 h 10 m 20 sec
Reputation Power: 6
RE: adding data from the web browsers address bar to a .csv file

php Code:
Original - php Code
  1. <?
  2. /* call with:
  3. http://site.com/script.php?data=release;user;files;bits;genre;size  ;date
  4. */
  5.  
  6. $data = str_replace (';',',',$_GET['data']) . "n";
  7.  
  8. $fp = fopen ('data.csv','a');
  9. fwrite ($fp,$data);
  10. fclose($fp);
  11. ?>


Reply With Quote
  #3  
Old September 4th, 2002, 08:02 PM
Nimco Nimco is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Posts: 132 Nimco User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 2
Send a message via AIM to Nimco
RE: RE: adding data from the web browsers address bar to a .csv file

or if you don't want to call with 'data='

php Code:
Original - php Code
  1. <?
  2. /* call with:
  3. http://site.com/script.php?release;user;files;bits;genre;size;date 
  4. */
  5.  
  6. $data = str_replace (';',',',$_SERVER["QUERY_STRING"]) . "n";
  7.  
  8. $fp = fopen ('data.csv','a');
  9. fwrite ($fp,$data);
  10. fclose($fp);
  11. ?>

Reply With Quote
Reply

Viewing: Codewalkers ForumsPHP RelatedPHP Coding > adding data from the web browsers address bar to a .csv file


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
Stay green...Green IT