19 messages in com.googlegroups.adwords-apiAdWords API Re: Get the zipped file b...| From | Sent On | Attachments |
|---|---|---|
| dyuti | 18 Apr 2008 06:16 | |
| Jan | 18 Apr 2008 10:23 | |
| dshevnock | 18 Apr 2008 11:06 | |
| Dyutiman Chaudhuri | 21 Apr 2008 22:40 | |
| Dyutiman Chaudhuri | 21 Apr 2008 22:44 | |
| Tomac | 21 Apr 2008 23:43 | |
| Dyutiman Chaudhuri | 22 Apr 2008 00:24 | |
| Dyutiman Chaudhuri | 24 Apr 2008 04:16 | |
| Dyutiman Chaudhuri | 24 Apr 2008 04:22 | |
| Jan | 24 Apr 2008 05:40 | |
| Dyutiman Chaudhuri | 24 Apr 2008 07:14 | |
| Jan | 24 Apr 2008 08:49 | |
| dyuti | 29 Apr 2008 00:43 | |
| Dyutiman Chaudhuri | 29 Apr 2008 00:48 | |
| Jan | 29 Apr 2008 01:10 | |
| Dyutiman Chaudhuri | 29 Apr 2008 02:45 | |
| Jan | 29 Apr 2008 03:08 | |
| Dyutiman Chaudhuri | 29 Apr 2008 04:48 | |
| Jan | 29 Apr 2008 05:40 |
| Subject: | AdWords API Re: Get the zipped file by url![]() |
|---|---|
| From: | Dyutiman Chaudhuri (dyut...@gmail.com) |
| Date: | 04/24/2008 04:22:16 AM |
| List: | com.googlegroups.adwords-api |
Hi,
Look at my code which uses fopen(); <?php .... .... $handle = fopen($reportUrl['get'.$zipOrNot.'ReportDownloadUrlReturn'], "r"); $content = fread($handle, filesize($reportUrl['get'.$zipOrNot.'ReportDownloadUrlReturn'])); $handle1 = fopen('test.zip', "w+"); fwrite($handle1, $content); fclose($handle); fclose($handle1); ?>
And when I run the script I get
*Warning*: fopen( https://adwords.google.com/api/adwords/ReportDownload?t=AAAAABTiC4MAAAEZgCm3BAEAAAAARSRCr8R-nIxAlNTNZgCy-EtIBh1FMRYw) [function.fopen <http://localhost/adwords/function.fopen>]: failed to open stream: Invalid argument in *d:\wamp\www\adwords\get_zipped_report.php* on line *44*
*Warning*: filesize() [function.filesize<http://localhost/adwords/function.filesize>]: stat failed for https://adwords.google.com/api/adwords/ReportDownload?t=AAAAABTiC4MAAAEZgCm3BAEAAAAARSRCr8R-nIxAlNTNZgCy-EtIBh1FMRYwin *d:\wamp\www\adwords\get_zipped_report.php* on line *45*
*Warning*: fread(): supplied argument is not a valid stream resource in * d:\wamp\www\adwords\get_zipped_report.php* on line *45*
*Warning*: fclose(): supplied argument is not a valid stream resource in * d:\wamp\www\adwords\get_zipped_report.php* on line *48
*Does anybody has any idea??
- Dyutiman
On Fri, Apr 18, 2008 at 10:53 PM, Jan <piot...@gmail.com> wrote:
How does your url look like?
I would just use fopen() to open and read the file, then fwrite() to write it locally to my harddisc. Then extract the file in it (use some library like pclzip.lib.php) and analyze the result (xml, csv, ...).
Or did I miss something that makes it complicated?
- Jan
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"AdWords API Forum" group.
To post to this group, send email to adwo...@googlegroups.com
To unsubscribe from this group, send email to
adwo...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
-~----------~----~----~----~------~----~------~--~---




