Hi Everyone,
I am building a responsive site for a client utilising the drupal 7 and omega css for narrow, wide etc. Is there a way of creating a context condition which relates to narrow, wide, default stylesheet in use? I could then trigger a certain delta on that condition?
If someone can help me get my head around this then omega becomes a dream come true for my drupal dev needs!
Can anyone give some advice or perhaps point me to something amazingly obvious which I have overlooked/cant see for looking? I guess im looking for the obvious (not to me) method of achieving this using the interface provided by omega, rather than doing things by hand as im used to....
Thanks in advance :)
Paul
Comments
please?
Anyone??? Would really appreciate the help.
I'm not sure you can do that.
I'm not sure you can do that.
The multiple CSS files are switched via media queries, all handled in the browser. Context is server side. You would need to use JS to get the current browser width & alter the context on the server after a page load, or use server side browser sniffing to alter the context.
You haven't made clear why or what your aim is, it may be possible you don't need to switch delta's.
If you are new to Omega, RTFM:http://drupal.org/node/819164 the handbook also mentions IRC, maybe check out #drupal-omega.
Mobil Tools
The mobile tools module allows you to build a context based on the display device. Then you can link a Delta to the context. Currenly, that's the only way I know to do it, although I have a similar problem and am looking for better solutions.
sounds good
thanks for your input zoon_unit and drew reece.
im still ivestigating....... so far I am not finding a solution that works for me. I may simply run a normal and mobile stylesheet until the reactive aspect of the theme is more mature, leaving wide and narrow disabled. I can always come back to them once I am more experienced in the ways of Drupal theming! Its a natural thing surely to want to run a different layout ie. number of columns for a region etc based upon how much screen there is? Surely some more people must have come across this issue?
Still would love to hear from any one who has a solution or workaround for this.
Kind Regards
Paul
There is a feature request in
There is a feature request in the Context project regarding the creation of a context based on media queries: http://drupal.org/node/1026022
I think that's what you'd ultimately want.
Looking to do the same thing
I'm trying to do the same thing as OP, find a way to use delta with Omega's media query. Reason being is that for mobile, I want only the content region front and center with the sidebars hidden. And for a wider screen have the sidebars back up again. Currently using css's 'display:none', but that is not the best way of doing it and it is messing with omega's grid css once the 'alpha-default-X.css' kick in.
From the link provided by bneil, it seems like it is not possible with context.
What you asking @PEP3 for
What you asking @PEP3 must be a Hybrid Responsive design + REST (Server side components)
John Albin mentioned on this podcast about Mobile initiative for Drupal 8
https://www.acquia.com/resources/podcasts/acquia-podcast-39-john-albin-m...
The closest solution I had found and use is what @zoon_unit mentioned "Contenx+Delta+Mobile Tools" the following link explains how to achieve this.
http://www.mediacurrent.com/blog/control-your-drupal-page-layout-context...
--
http://jmolivas.com/
@jmolivas
Media Queries + Server Side Componets
This might be of help to you. http://groups.drupal.org/node/208778