Skip to Content
author's profile photo Former Member
Former Member

Media queries not working with opensocial

Hi all,

I've created a widget including media queries, but the css inside the media query doesn't work inside my opensocial gadget.

@media screen and (min-width:450px)

When I insert the URL (not the xml) in an URL widget, or when I access the URL (not the xml) directly in my browser, it's working fine. Doesn't opensocial support media queries? According to the documentation it should.

To be clear, I inserted the URL referred to in below HREF of the XML gadget.

<?xml version="1.0" encoding="UTF-8"?>

<Module>

<ModulePrefs title="How do I"></ModulePrefs>

<Content href='../hello' view="authoring, consumption, mobile, preview"></Content>

</Module>

Does anyone know why this is not recognized?

Thanks for your help.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    Posted on Jan 07, 2014 at 02:57 PM

    Hi Bob,

    Can you share the hello source code?

    thanks,

    Eliel.

    Cloud Portal

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Eliel Schurman

      Hi Eliel,

      Thanks for the tip. When comparing your spec.xml with mine, I noticed that i was missing the content type. When I inserted "url" in the content file, the media queries are working fine and I can still point to the defined URL pattern.

      Spec xml

      <?xml version="1.0" encoding="UTF-8"?>

      <Module>

      <ModulePrefs title="How do I"></ModulePrefs>

      <Content href='../hello' type="url" view="authoring, consumption, mobile, preview"></Content>

      </Module>

      Many thanks, appreciate your help!

      Bob

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.