We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

curl error with CSVGrab

Development and Programming

peredur's avatar
peredur
6 posts
16 years ago
peredur's avatar peredur

Hmmm….I’m getting this error (and no entries are loading):

Warning: curl_setopt() [function.curl-setopt]: the provided file handle is not writable in […]/pi.csvgrab.php on line 157

I’m on a Mac, but I think I’ve got the right line endings.

Any clues?

[Mod Edit: Modified title for clarity]

(Sorry….meant to post this to the csvgrab thread. Too fried to manage it.)

       
Dan Halbert's avatar
Dan Halbert
93 posts
16 years ago
Dan Halbert's avatar Dan Halbert

At the line in question, the PHP code has created a tmpfile and then pass it to curl. Either tmpfile() returned a non-writable file or returned an error value. It is very odd this is not working. It may mean there is something broken with your hosting setup.

Having said that, the workaround is not to use a URL to specify your .csv file. So instead of:

http://yoursite.com/yourcsvfile.csv

you need something like:

/users/yourlogin/public_html/yourcsvfile.csv

The exact path you need varies from webhost to webhost, and if you are not sure, ask your webhost how to specify a file in your directory tree.

       
peredur's avatar
peredur
6 posts
16 years ago
peredur's avatar peredur

Thank you! That did it.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.