You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by Steven Shearer <st...@gmail.com> on 2009/06/25 04:49:42 UTC

using ifr url technique to load gadget in iframe has no user prefs control?

If a gadget is loaded via JavaScript as with the samples and sample
container, the client side container scripts render a title bar with options
to edit the user preferences for said gadget.

If, however, a gadget is loaded via the ifr url technique, there's no
immediate access to user preferences.  Is this by design?

Just to be clear I'm referring to using the following approach:

http://localhost:8080/gadgets/ifr?url=spec.xml

I'm attempting to embed Google and OpenSocial gadgets in an existing site
but without the user preferences being accessible when using the ifr url
technique this approach is pretty a non-starter for me -- and for various
reasons I'd actually prefer to use this approach over embedding via
JavaScript.

Thanks for the assistance.

Steve

Re: using ifr url technique to load gadget in iframe has no user prefs control?

Posted by Hafiz A Haq <ha...@gmail.com>.
As far as I understood, the preferences rendering has to be done by writing
code at your end. Even the implementation in the sample codes is making use
of google infrastructure to generate the UI for preferences managment. I am
not sure if it would be ok for your use.

I bleieve Shindig only provides the infrastructure for iframe generation ,
that is, to render the gadget alone, with a given set of preferences, not a
facility to render the preferences management.

Thanks and Regards,
Hafiz

2009/6/25 Steven Shearer <st...@gmail.com>

> If a gadget is loaded via JavaScript as with the samples and sample
> container, the client side container scripts render a title bar with
> options
> to edit the user preferences for said gadget.
>
> If, however, a gadget is loaded via the ifr url technique, there's no
> immediate access to user preferences.  Is this by design?
>
> Just to be clear I'm referring to using the following approach:
>
> http://localhost:8080/gadgets/ifr?url=spec.xml
>
> I'm attempting to embed Google and OpenSocial gadgets in an existing site
> but without the user preferences being accessible when using the ifr url
> technique this approach is pretty a non-starter for me -- and for various
> reasons I'd actually prefer to use this approach over embedding via
> JavaScript.
>
> Thanks for the assistance.
>
> Steve
>



-- 
He who asks is a fool for five minutes, but he who does not ask remains a
fool forever.

Re: using ifr url technique to load gadget in iframe has no user prefs control?

Posted by Steven Shearer <st...@gmail.com>.
Thanks for the feedback.  My suspicions are correct then.  I still plan to
leverage Shindig to one degree or another but these answers are a huge help
in deciding where to take my thought process next.

Steve

On Thu, Jun 25, 2009 at 6:58 AM, Chris Chabot <ch...@google.com> wrote:

> Hey Steven,
>
> Ah yes this has lead to confusion before, mostly due to our lack of
> documentation ;/
>
> The javascript sample container is mainly meant as a quick-and-dirty out of
> the box example, and not as an exampe for how you should build a
> container..
> It's important to note that shindig is not a social container (website),
> but
> simply put, just the engine that will render gadgets for you and provide
> the
> OpenSocial API to those gadgets.
>
> So to use it you'd have to do things like creating iframe url's, including
> view-params, security tokens, user preferences etc; Deal with security
> tokens in general, implement the Social API by extending the People,
> Activities and AppData classes, and indeed a UI for setting user
> preferences
> too.
>
> The best practical example of what needs to be done and how to do that is a
> PHP project called Partuza (http://code.google.com/p/partuza), if however
> reading PHP is not your thing, you could also check out SocialSite, however
> the project is in the middle of migrating from Sun to Apache, and I'm
> unable
> to open their original website and their new apache site isn't up yet
> (anyone know what's up with that btw?) however I think this code should
> probably still be somewhat up to date:
> https://socialsite.dev.java.net/source/browse/socialsite/
>
> Hope that helps & please don't hesitate to send any questions you may run
> into to this list!
>
>   -- Chris
>
> On Thu, Jun 25, 2009 at 4:49 AM, Steven Shearer <st...@gmail.com>
> wrote:
>
> > If a gadget is loaded via JavaScript as with the samples and sample
> > container, the client side container scripts render a title bar with
> > options
> > to edit the user preferences for said gadget.
> >
> > If, however, a gadget is loaded via the ifr url technique, there's no
> > immediate access to user preferences.  Is this by design?
> >
> > Just to be clear I'm referring to using the following approach:
> >
> > http://localhost:8080/gadgets/ifr?url=spec.xml
> >
> > I'm attempting to embed Google and OpenSocial gadgets in an existing site
> > but without the user preferences being accessible when using the ifr url
> > technique this approach is pretty a non-starter for me -- and for various
> > reasons I'd actually prefer to use this approach over embedding via
> > JavaScript.
> >
> > Thanks for the assistance.
> >
> > Steve
> >
>

Re: using ifr url technique to load gadget in iframe has no user prefs control?

Posted by Chris Chabot <ch...@google.com>.
Hey Steven,

Ah yes this has lead to confusion before, mostly due to our lack of
documentation ;/

The javascript sample container is mainly meant as a quick-and-dirty out of
the box example, and not as an exampe for how you should build a container..
It's important to note that shindig is not a social container (website), but
simply put, just the engine that will render gadgets for you and provide the
OpenSocial API to those gadgets.

So to use it you'd have to do things like creating iframe url's, including
view-params, security tokens, user preferences etc; Deal with security
tokens in general, implement the Social API by extending the People,
Activities and AppData classes, and indeed a UI for setting user preferences
too.

The best practical example of what needs to be done and how to do that is a
PHP project called Partuza (http://code.google.com/p/partuza), if however
reading PHP is not your thing, you could also check out SocialSite, however
the project is in the middle of migrating from Sun to Apache, and I'm unable
to open their original website and their new apache site isn't up yet
(anyone know what's up with that btw?) however I think this code should
probably still be somewhat up to date:
https://socialsite.dev.java.net/source/browse/socialsite/

Hope that helps & please don't hesitate to send any questions you may run
into to this list!

   -- Chris

On Thu, Jun 25, 2009 at 4:49 AM, Steven Shearer <st...@gmail.com> wrote:

> If a gadget is loaded via JavaScript as with the samples and sample
> container, the client side container scripts render a title bar with
> options
> to edit the user preferences for said gadget.
>
> If, however, a gadget is loaded via the ifr url technique, there's no
> immediate access to user preferences.  Is this by design?
>
> Just to be clear I'm referring to using the following approach:
>
> http://localhost:8080/gadgets/ifr?url=spec.xml
>
> I'm attempting to embed Google and OpenSocial gadgets in an existing site
> but without the user preferences being accessible when using the ifr url
> technique this approach is pretty a non-starter for me -- and for various
> reasons I'd actually prefer to use this approach over embedding via
> JavaScript.
>
> Thanks for the assistance.
>
> Steve
>