Multiple list and detail viewers to a single section
9 posts by 3 authors in: Forums > CMS Builder
Last Post: December 2, 2011 (RSS)
By ennisoft - December 1, 2011 - edited: December 1, 2011
I want to set up a mobile device version of my CMSB site to operate in a subdomain (or just a subfolder) of my existing site; in order to display the same records as on my main (desktop viewed) site, but in a different format, I need to be able to define a second set of viewers.
How do I get around this?
I know I could configure the entire site to work at both 1000px and 180px wide, but I want to retain the existing layout for the main site.
Any help appreciated.
Re: [ennisoft] Multiple list and detail viewers to a single section
By InHouse - December 1, 2011
If I understand your situation correctly, this problem is now best handled using Media Queries which detect the size of the screen being used. You can instruct a set of CSS rules to be applied to your basic page layout which completely restructure your page for that size of device. Best of all, you don't have to write a second set of pages - just adjust your page elements to flow differently in a narrow screen.
Some good info on this is available at:
http://www.adobe.com/devnet/dreamweaver/articles/introducing-media-queries.html
and there's respond.js to backfill media querie functions in older browsers:
https://github.com/scottjehl/Respond#readme
Hope this helps!
J.
Re: [InHouse] Multiple list and detail viewers to a single section
By ennisoft - December 2, 2011 - edited: December 2, 2011
CSS is great for repositioning / hiding / resizing content, but I think that rebuilding the whole site using media queries would be unmanageable in the long term.
My original issue remains; how do I link a second set of viewers to a section?
Coincidentally, your reply is of use to another thread just posted in the forum, which is a very similar query!
Re: [ennisoft] Multiple list and detail viewers to a single section
By InHouse - December 2, 2011
In that case, I could see two options:
1 - Redirect mobile users to a sub-folder with an entirely mobile-friendly version of the site. Then you'd just use all the same queries and the only thing you'd have to look out for would be to avoid using the automatic _link and build your own anchors. Plus, make sure you make all your page updates in both locations. You'd effectively be running two sites like in the very old days when we sometimes built printer-friendly versions of sites like this.
2 - In the main site pages, detect for the mobile subdomain and put conditionals on which query to load and possibly (again) whether to use or ignore the auto _link values.
The former seems more straightforward to me, though I have to say that media queries seem both simpler and better than both options - but I don't have a full grasp of your site requirements.
Cheers!
Re: [InHouse] Multiple list and detail viewers to a single section
By ennisoft - December 2, 2011
Thanks again, the first approach is what I was going for - I didn't have the information about replacing _link with a hard coded link to the detail viewer.
The only remaining piece of the puzzle as far as I can see is this: the back link from the detail viewer to the list viewer takes into account if the user had navigated through pages of lists - I guess I'll have to use the "onclick=history.back()" script for this.
Re: [ennisoft] Multiple list and detail viewers to a single section
By InHouse - December 2, 2011
But you will want to remove that automatic link to be sure. I often find that we need to build our own links anyway due to the conditions of the project, so not using the automatic link isn't a huge hardship.
J.
Re: [InHouse] Multiple list and detail viewers to a single section
By ross - December 2, 2011
Thanks for helping out. Sounds like you got ennisoft sorted out on this one :).
Thanks!
Cheers,
Ross Fairbairn - Consulting
consulting@interactivetools.com
Hire me! Save time by getting our experts to help with your project.
Template changes, advanced features, full integration, whatever you
need. Whether you need one hour or fifty, get it done fast with
Priority Consulting: http://www.interactivetools.com/consulting/
Re: [ennisoft] Multiple list and detail viewers to a single section
By ross - December 2, 2011
Wanted to post again as a reply to you so you get the notification. Basically, it sounds to me like inHouse has you going now. Keep us up to date with how you are making out.
Thanks!
Cheers,
Ross Fairbairn - Consulting
consulting@interactivetools.com
Hire me! Save time by getting our experts to help with your project.
Template changes, advanced features, full integration, whatever you
need. Whether you need one hour or fifty, get it done fast with
Priority Consulting: http://www.interactivetools.com/consulting/
Re: [ross] Multiple list and detail viewers to a single section
By InHouse - December 2, 2011
Nice to have confirmation from the pros though!
J.