AaronForce1 / cartopress

CartoDB Plugin for Wordpress
6 stars 2 forks source link

Trouble connecting to cartodb account #1

Closed kappa44 closed 8 years ago

kappa44 commented 8 years ago

Very excited about this project because I wanted to integrate CartoDB to wordpress myself. Opened a test cartodb account yesterday. Created a new install of WP 4.4.2 on localhost (an xampp stack on my laptop). Then downloaded the plugin from the wordpress repository and activated. Created a couple of posts - everything looks great. However, when I try to connect to my CartoDB account I keep getting the following error message in a drop down dialog:

"CartoPress could not connect to your CartoDB account. Please verify that your user name is correct."

I logged into my new CartoDB account to check my username. Tried uppercase, lowercase, regenerated a new API key -- I did every variation I could think of and still got the same error.

One quirky behavior to report. One of things I tried was to save the edit screen after I filled in the CartoDB API and username and BEFORE I tried to connect to CartoDB. When I did that, those two fields were populated with the saved data. Then I tried to connect to CartoDB. I still got the same error message but after the error message appeared, the username field was then blank as if the data for that field had not been saved. I don't know if this is relevant but there may be some issue with how the plugin is reading and/or saving the username field.

The bottom line is that after multiple attempts I have not been able to connect the plugin to my CartoDB account. Any assistance would be welcomed. This is a great project. So Thank you for your work so far.

kappa44 commented 8 years ago

I think I solved my own problem. I tried the plugin on a live site and it worked perfectly. There must be some issue with using the plugin on a demo site on my laptop.

hallisey commented 8 years ago

Hi there, I am glad that were able to work it out. I was testing on a local demo site (using MAMP) and didn't run into any issues. Right now, it is using cURL directly to make HTTP requests to the CartoDB API, so maybe that was not enabled or configured on your localhost? We are planning on changing the the HTTP request process to use the WP HTTP API in an upcoming release (I just have to get the time to do it :), so hopefully that might resolve that issue. Let me know if you find anything else. Thanks for the feedback.

kappa44 commented 8 years ago

Thanks for the fast response. I checked php.ini and I think cURL is enabled but it's OK. I've got a work around for now. I'm going to be building a prototype site using the plugin over the next couple of days so I'll let you know if I come across anything else. Again, thanks for the effort.