Ning

From JRapid

Jump to: navigation, search

Contents

About Ning Transformer

This transformer will help you integrating your forms and listings in ning apps, which are particularly, opensocial apps. You just need to indicate which listings you want to populate, and then publish your app in a public URL, so your Ning network can access the app URL and communicate freely.

As with other JRapid opensocial transformers do, you can interact with jropensocial object, as well as with the standard opensocial and gadgets objects that come from the standard.

About Ning

Ning networks allow you to create private social networks with some basic web 2.0 features that end up to be very helpful when starting these kind of sites, for example:

  • Users
  • Friends
  • Groups
  • Activites
  • Calendar
  • Blog
  • Photo sharing
  • Video sharing
  • Comment posting
  • Rating
  • Sharing contents in other networks

and so, but specially it provides opensocial integration as a feature. This means that we can create applications that add value to the network. These applications use existing network information (user name, picture, friends, etc) to fulfil its own purposes, but they also send valuable information back to the network as messages, notification or activities.

About OpenSocial

OpenSocial provides a common API for making easier the development of apps that will be integrated in social web sites. As the referenced site defines, A common API means you have less to learn to build for multiple websites. OpenSocial is currently being developed by a broad set of members of the web community. The ultimate goal is for any social website to be able to implement the API and host 3rd party social applications. There are many websites that support OpenSocial, including hi5, LinkedIn, MySpace, Netlog, Ning, orkut, and Yahoo! Full List

Transformer structure

Ning apps allow developers to send a list of links, which will be the Main Menu of the Ning application. In addition to this, they have a landing page, which will be shown when the application is accessed.

Ning apps also have views. At the current version, they have 2 different kind of views: Profile views and canvas views. They are used depending on the way the app was added. If the app was added to a profile, the profile view will be considered. Otherwise, the canvas view is used.

According to this structure, the transformer will have two sections:

  • links: will have link elements as children, specifying menu options pointing to listings or forms to be shown when clicked.
  • views: will specify the default listing or form to be shown when landing on the application. opensocial apps must have at least 1 view declared

Usage

<ning 
       label = LABEL
       url = URL
       author = AUTHOR
       author_email = AUTHOR
       description = DESCRIPTION
       thumbnail = THUMBNAIL
       screenshot = SCREENSHOT
      <views>
        (view)
      </views>
      <links>
        (link)
      </links>
/>
  • label will be used as ning app title
  • url is strongly important, representing the public URL to retrieve files such as forms and listings.
  • author, author_email, description, thumbnail and screenshot will be used for creating the About page.
Thumbnail size: 120x60px
Screenshot width: 502px
Screenshot maximum height: 1000px
Max file size: 150KB, non-transparent .gif/.jpg/.png

So let's analyze view and link elements, which are quite similar (just not to say that they have exactly the same structure)

<link or view>
       entity = ENTITY
       label = LABEL
       type = 'listing' | 'form'
       listing = LISTING
       subset = SUBSET
       subsetparams = SUBSETPARAMS (*)
       defaultset = DEFAULTSET
       defaultsetparams = DEFAULTSETPARAMS (*)
/>

(*) Here you have these extra objects: viewer and owner, where you can access properties id, displayName, and any opensocial implemented property (by now ning implements a few, see list)

The key value proposition

Some lines before we said that you may add value to social networks through your JRapid apps. Still it was not clear how. One of the most important ways of integration between ning networks and JRapid apps are the objects that can be passed as subsetparams and defaultsetparams, which are:

  • network.id
  • network.subdomain
  • network.domains
  • viewer.id
  • viewer.displayName
  • owner.id
  • owner.displayName

Sample opensocial fields:

  • viewer.opensocial.Person.Field.PROFILE_URL
  • viewer.opensocial.Person.Field.THUMBNAIL_URL
  • viewer.ning.Person.Field.ADMIN
  • viewer.ning.Person.Field.CREATOR

An example

    <ning label="Promos" name="Commerces" url="http://www1.jrapidcloud.com/quilmes-0.0.3/forms.Main/">
        <links>
            <link entity="Promotion" label="Promos" listing="icons" subset="forPublic" type="listing"/>
            <link entity="Commerce" label="Comercios" listing="icons" subset="forPublic" type="listing"/>
            <link defaultset="withParams" defaultsetparams="viewer.id,viewer.displayName,viewer.opensocial.Person.Field.PROFILE_URL,viewer.opensocial.Person.Field.THUMBNAIL_URL" entity="SignUpCommerce" label="Quiero Participar" type="form"/>
            <link defaultset="withParams" defaultsetparams="viewer.id" entity="ManagePromotions" label="Nueva Promo (*)" type="form"/>
            <link entity="Promotion" label="Mis Promos (*)" listing="forPerson" subset="forPersonId" subsetparams="viewer.id" type="listing"/>
        </links>
        <views>
            <view entity="Promotion" listing="icons" name="profile" subset="forPublic" type="listing"/>
            <view entity="Promotion" listing="icons" name="canvas" subset="forPublic" type="listing"/>
        </views>
    </ning>
    <ning label="Votos" name="Voting" url="http://www1.jrapidcloud.com/quilmes-0.0.3/forms.Main/">
        <links>
            <link entity="Candidate" label="Votar" listing="icons" subset="forPublic" type="listing"/>
            <link entity="Candidate" label="Resultados" listing="ranking" subset="forPublic" type="listing"/>
            <link defaultset="withParams" defaultsetparams="viewer.id,viewer.displayName,viewer.opensocial.Person.Field.PROFILE_URL,viewer.opensocial.Person.Field.THUMBNAIL_URL" entity="SignUpPerson" label="Quiero Participar" type="form"/>
            <link defaultset="withParams" defaultsetparams="viewer.id" entity="ProposeAsCandidate" label="Postularme (*)" type="form"/>
            <link defaultset="withParams" defaultsetparams="viewer.id" entity="EarnMerits" label="Hacer Merito (*)" type="form"/>
        </links>
        <views>
            <view entity="Candidate" listing="icons" name="profile" subset="forPublic" type="listing"/>
            <view entity="Candidate" listing="icons" name="canvas" subset="forPublic" type="listing"/>
        </views>
    </ning>
Personal tools