Go Back   CodingForums.com > :: Server side development > PHP

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-12-2013, 07:44 PM   PM User | #1
d'Anconia
Regular Coder

 
d'Anconia's Avatar
 
Join Date: Jan 2010
Location: Tempe, AZ
Posts: 142
Thanks: 15
Thanked 5 Times in 5 Posts
d'Anconia is an unknown quantity at this point
PHP and API's: Need a Decent Tutorial

At this point I am relatively familiar with PHP and using it within the same domain / server, but I want to start learning how to work with API's so that I can increase the capabilities of my websites. Can anyone give me a good starting point for learning this stuff? Will I have to learn Zend Framework (because it seems that several API's or tutorials use it? Will I have to learn cURL first?

Also will I be able to implement this stuff if my website is on a shared server? Because on some tutorials it looked like I'd have to tamper with Linux / Unix stuff.

Any help would be great. A sort of "API's for Dummies" would be great (assuming it was well-written). Thank you.
__________________
Powerful ideas for all lovers of personal and political freedom:
Freedomain Radio
Free Talk Live
d'Anconia is offline   Reply With Quote
Old 03-12-2013, 08:09 PM   PM User | #2
tangoforce
Senior Coder

 
tangoforce's Avatar
 
Join Date: Feb 2011
Location: Your Monitor
Posts: 3,516
Thanks: 45
Thanked 440 Times in 429 Posts
tangoforce will become famous soon enoughtangoforce will become famous soon enough
I don't think there is any such tutorial on APIs. Most external websites (eg paypal) offer their own custom API and instructions on how to use it. This is different for any company that has its own API so you're not going to find a one-size-fits-all tutorial. Most of these companies will offer you an example of how to use their API though.

As for cURL, yes you'll probably need to learn to use it but it really isn't that hard. If you're able to use and understand the php.net manual, then the php.net cURL manual is just as easy to understand. It's about calling a few functions, passing the correct parameters (which php.net has a list of) and then executing the request. There is nothing overly complex about it but if you don't get to grips with it easily, there are always user comments on php.net and plenty of samples on google!
__________________
Please wrap your code in [php] tags. It is a sticky topic and it HELPS us to HELP YOU!
TIP: Coding styles and $end errors :::::::::: TIP: Warning: Cannot modify header information - headers already sent :::::::::: TIP: Quotes / Parse error: syntax error, unexpected T_..
PHP Code:
//Please don't use this for your form processing:
if (isset($_POST['submit']))
//Internet explorer has a bug and does not always send the submit value. 
Explanation: The IE if(isset($_POST['submit'])) bug explained.
tangoforce is offline   Reply With Quote
Users who have thanked tangoforce for this post:
d'Anconia (03-15-2013)
Reply

Bookmarks

Tags
api, curl, php, zend framework

Jump To Top of Thread


Thread Tools
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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 05:16 AM.


Advertisement
Log in to turn off these ads.