Upload
skyingblogger
View
1.362
Download
0
Embed Size (px)
DESCRIPTION
http://Skyingblogger.Com brings you a project for engineering students on social programming.
Citation preview
Seminar onSOCIAL PROGRAMMING
Guided By: By:
Mrs. Pooja Singh DEV KUMAR
0211042708
Introduction• The development of
SNS’s• Content Management• Application
development on Open Platforms
• Protocols for• Security• Privacy• Serving Business Logics• Promotion over the Globe
Open Graph Protocol (OGP) Integrate web pages into social graph Currently used for representing profiles of real world
things like movies, celebrities ,restaurants, bands for business promotion
The website appears in the likes and interests of the user enabling enhanced traffic to the site.
Enables targeted ads to people who likes your page.
Creating OGP Object
1. Adding Metadata Tags allow you to specify structured
information about your web pages.2. Adding the “Like” Button
A connection is made between your page and the user.
You have the ability to publish updates to the user
OGP Properties 1. og:title
the title of the object as it should appear within the graph
2. og:type The type of your object, e.g., "movie"
3. og:image An image URL which should represent
your object within the graph4. og:url
URL of your object that will be used as its permanent ID in the graph
Adding Meta tags
<meta property="og:title" content=“ASET"/> <meta property="og:type”content=“Institute"/>
<meta property="og:url” content="http://www.amity.edu/aset/"/>
<meta property="og:image" content="http://www.amity.edu/aset.jpg"/>
<meta property="og:site_name" content=“Edu"/> <meta property="fb:admins”content="USER_ID"/>
Adding a Like Button Once meta tags are configured on web
page a like button can be associated with it.
The like button can be added as: <fb:like href="https://developers.facebook.com/"
width="450" height="80"/> Appears in user profile as
OGP Objects and Connections
Advantages
Attract users sharing some common interest with the user liking your page, hence serving business interests.
Assist in increasing Google Page Rank , promoting ads and traffic to the website.
Narrowing the ad selection for the particular user.
Demo OGP
STEP 1: Adding to <html><html
xmlns="http://www.w3.org/1999/xhtml" xmlns:og="http://ogp.me/ns#"xmlns:fb="https://www.facebook.com/2008/fbml">
These lines of <html> code specifies the namespace to use for the code to be embedded.
Demo OGP (Contt..)
STEP 2 : Adding Structured Meta<head> <title>CSE 2012</title><meta property="og:title" content=“ASET"/> <meta property="og:type”content=“Institute"/><meta property="og:url” content="http://www.amity.edu/aset/"/> <meta property="og:image“
content="http://www.amity.edu/aset.jpg"/> <meta property="og:site_name" content=“/aset"/> <meta property="fb:admins”content="604735984"/>……</head>
Demo OGP (Contt..)
STEP 3 : Debugging Debugging tools for different tools are available
e.g. , “Linter” tool in Facebook platform. Go to http://developers.facebook.com/tools/lint/ Paste the URL of the object from your website Hit Enter and FB will return the information it can
fetch from your website. It returns information like Admins, app_id, image,
title etc.
Linter at Facebook
Addressing Security Issues in Social Programming
With the increasing number of third party apps and involvement of developers in social programming ,security issues are raised , which are required to prevent unauthorized use of user’s personal data.
These protocols are also referred to as AAA protocols, stands for 1. Authentication2. Authorization &3. Accounting
OAuth OAuth (Open Authorization)
is an open standard for authentication.
Allow secure API authorization in a simple and standard method for third party applications.
OAuth is currently used for API authorization for : Twitter Facebook Google Friend Connect
OAuth Flow
OAuth 2.0 On April 23, 2009, a security flaw in the 1.0
protocol was announced, to resolve the issue Oauth 1.0a was announced but was then upgraded to OAuth 2.0
OAuth 2.0 is the next evolution of the OAuth protocol and is not backward compatible with OAuth 1.0 .
Facebook's new Graph API only supports OAuth 2.0 and is the largest implementation of the emerging standard .
Social Programming on Facebook
Learn developing application on the Facebook Platform
Benefits of social programming on Facebook User management is done by
Facebook Most popular SNS in the world
having largest number of users Viral Marketing Easy to develop, promote and
monetize Support for different for different
languages Bring an existing app and brand into
FB.
Getting Started
FB Application Structure
Browser makes request
FB server calls application server
App calls FB API App returns FBML Facebook renders
FBML to HTML
Getting started at…..HTTP://DEVELOPERS.FACEBOOK.COM/APP
Create an application
Configuration [Canvas]
Code & Setup [at app Server] Download FB-PHP
Client Library from http://developers.facebok.com/get_started.php
Extract & save the facebook.php file in the app root directory
Make index.php file & include facebook.php file and start the coding part.
localhost
Fbapp directory
facebook.php Index.php
The Actual php code(index.php)
The Result is:
Important Components on FB FBML
Its Just like any other Markup Language. Just it comes with a namespace “fb”
FQL Facebook Query Language Provides user friendly interface to FB data
FBJS A subset of Regular Javascript Excellent support for AJAX Works via getter & setter methods
References
[1] Social Programming.[Online].Available: http://www.socialprogramming.info/ [2] FB Development.[Online].Available:
http://www.sitepoint.com/developing-facebook-platform/ [3] Graph API.[Online].Available : http://wiki.developers.facebook.com [4] OGP.[Online].Available: http://developers.facebook.com/docs/ogp