You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by "Jacobsen, Jasen" <ja...@mitre.org> on 2009/10/29 17:35:21 UTC

Trouble with UserPrefs and samplecontainer

I'm trying to write a simple gadget that uses some user prefs. I'm copying the examples from here: http://code.google.com/apis/gadgets/docs/reference.html#Userprefs_Ref

But when I load my gadget (or any other gadget) into the sample container, and click the "settings" link, all that is displayed are the "Save" and "Cancel" buttons. No preferences are rendered.

When using container/sample1.html, the preferences for the horoscope gadget are rendered. Can anyone explain why these two containers are behaving differently?

Also, I can't find any documentation on gadgets.UserPrefStore. There's no mention of it in the spec that I can find. Is it deprecated?

- Jasen.

Re: Trouble with UserPrefs and samplecontainer

Posted by Il...@Metavante.com.
Jasen,

Shindig - being a reference implementation - uses gModules (
http://gmodules.com/ig/gadgetsettings) to parse User Preferences from the
gadget XML. In order for the gModule parser to see your gadget's XML and
generate the HTML for it, the gadget must be accessible from gModules (i.e.
hosted at a public URL). Otherwise, you only get the empty dialog you're
seeing.
You can use the Google Gadget Editor to edit and save your gadget and get a
"semi-public" URL for it if you want to just test your gadget. Otherwise,
parsing user prefs is a responsibility of the container (i.e. your portal
application), not of Shindig, so you will need to write your own parser
(which is really not that difficult given the limited number of types
available for UserPref).

Hope this helps.
Ilya


                                                                                                                              
  From:       "Jacobsen, Jasen" <ja...@mitre.org>                                                                           
                                                                                                                              
  To:         "shindig-dev@incubator.apache.org" <sh...@incubator.apache.org>                                           
                                                                                                                              
  Date:       10/29/2009 03:29 PM                                                                                             
                                                                                                                              
  Subject:    Trouble with UserPrefs and samplecontainer                                                                      
                                                                                                                              





I'm trying to write a simple gadget that uses some user prefs. I'm copying
the examples from here:
http://code.google.com/apis/gadgets/docs/reference.html#Userprefs_Ref

But when I load my gadget (or any other gadget) into the sample container,
and click the "settings" link, all that is displayed are the "Save" and
"Cancel" buttons. No preferences are rendered.

When using container/sample1.html, the preferences for the horoscope gadget
are rendered. Can anyone explain why these two containers are behaving
differently?

Also, I can't find any documentation on gadgets.UserPrefStore. There's no
mention of it in the spec that I can find. Is it deprecated?

- Jasen.


---------------------------------------------------------------------
The information contained in this message is proprietary and/or
confidential.  If you are not the intended recipient, please: (i) delete
the message and all copies; (ii) do not disclose, distribute or use the
message in any manner; and (iii) notify the sender immediately. In
addition, please be aware that any message addressed to our domain is
subject to archiving and review by persons other than the intended
recipient. Thank you.
---------------------------------------------------------------------