Tag Archives: php

oAuth2 with symfony2

This is the second post in the series over oAuth with Symfony2, iOS and Android. All posts in this serie can be found here.

Creating a simple website with Symfony2 is actually very simple. Symfony2 is a popular framework, with a lot of available libraries/bundles for all kind of things.
Most of these bundles are pretty good documented, and due to that it is pretty easy to add a new functionality.

For this website I am going to use the next libraries, besides symfony2 itself:

Continue reading oAuth2 with symfony2

Oauth with iOS and android together with Symfony2

In a few projects I made in the last few months I wanted to use a method to login at a custom site within a app on Android or iOS. Using the username/password combination from the website itself didn’t seem to be a great idea, so that was scrapped directly.

I decided to look into using oAuth2 for accessing the API that was created on the website for authorisation. oAuth2 seems to be a commonly used, by companies like Google, Facebook and GitHub. Searching for simple implementation for both Android and iOS showed a few libraries, but all of them weren’t documented that well.

With this serie of blog posts I am going to try making a simple example website that contains a simple REST API written in symfony 2. This API will be called with 2 apps, 1 iOS app and 1 Android app. These apps are very simple, and have no other features/usages within this example. They are created just to show how to integrate the oAuth2 part into a app.

All code by used within this serie will be published at github, see the specific posts for the repository for that part of the project. The project is split up in 3 separate repositories.
While this project is ment to be a example for creating oAuth authorization, I still assume you have basic knowledge about both Symfony2, as iOS and Android programming. I won’t be explaining how to create a basic project for these three setup. All exampled that I publish are working and tested examples.

This serie is split up in more then one blogpost, in every blogpost I try to concentrate myself on one component in this project. Due too time constraints I won’t be able to publish all posts directly from the start, I will try to publish a post once every week.

In case of questions/mistakes/spelling errors/etc/ please leave a comment on the specific blog post. I will try to answer them as soon as possible.

php4

Why are hosts still using php4 on there new servers? I really dont understand that, as php5 is now released for several years, and more stable and secure as php5. Many users say that there scripts will not work on php5, but why? That much changes arent there between functions in php4 and php5, so a lot scripts will work perfectly.

Not migrating to php5 is for a lot scripters a big problem, as they want to use the features that php5 have, but they cant use them because hosters are still using php4. I really hope this is going to change soon, when php4 is really EOL.

Also, the same thing is for mysql4.0 (And maybe 4.1 but that iam not sure about :P), thats also EOL, but still a lot hosts are using it.