Forums de discussion

Implementing RESS (Responsive Design With Server Components) in Liferay

thumbnail
Luis Mas, modifié il y a 10 années.

Implementing RESS (Responsive Design With Server Components) in Liferay

Regular Member Publications: 146 Date d'inscription: 18/05/09 Publications récentes
Hi all,

Recently I've read this article Lightening Your Responsive Website Design With RESS http://mobile.smashingmagazine.com/2013/10/08/responsive-website-design-with-ress/, It's a very interesting article on how to go further in improving Users Experience.

I think most of the things can be done with Liferay 6.2 (next version coming) using Resposive Web Design in conjunction with the WURLF Utilities provided, but one of the things I think it's not possible in an easy way to implement with Liferay is "Connectivity Detection" and depending on the bandwidth of the connection or the kind of connection of the device that requested a page in Liferay (Edge, GPRS, Wi-fi, ...) serve a content or other content.

You can imagine an User that is accesing from a SmartPhone, its network connection is very important when he/she is requesting a page, and maybe the response should be different if the User is accessing from a Wi-Fi connection or from a GPRS/Edge connection.

Do you think it would be an useful improvement to Liferay? I'm thinking on adding an improvement request.

Thanks for your opinion!!!
thumbnail
Juan Fernández, modifié il y a 10 années.

RE: Implementing RESS (Responsive Design With Server Components) in Liferay

Liferay Legend Publications: 1261 Date d'inscription: 02/10/08 Publications récentes
Hola Luis:
I think that adding more control to device detection (for example adding a rule that makes decissions based on available bandwith) is a great idea. I'm not sure if WURLF can support this, but I agree it is worth analyzing.
I'll ping our WURLF expert (Milen) to see how hard it would be to implement it. Anyways, go ahead and open the feature request... and convince the community this is a good idea! emoticon
Thanks for your valuable feedback,
Juan
thumbnail
Jorge Ferrer, modifié il y a 10 années.

RE: Implementing RESS (Responsive Design With Server Components) in Liferay

Liferay Legend Publications: 2871 Date d'inscription: 31/08/06 Publications récentes
Thanks Luis, we've been discussing for a while about this concept without knowing it had a name emoticon
thumbnail
Milen Dyankov, modifié il y a 10 années.

RE: Implementing RESS (Responsive Design With Server Components) in Liferay

Expert Publications: 310 Date d'inscription: 30/10/12 Publications récentes
While this is a very nice to have feature I'm afraid it's outside of the scope of WURFL. The information about the connection type/speed is not something that you can store in a database as it is not tided to the device and may change at any time without notice. WURFL on the other hand is simply a database and API containing stale device specific information. The same problem is with resolution - WURFL will tell you that the device resolution is 800x600 and it will tell you that it supports dual orientation but will NOT tell you whether the user is currently holding the device horizontally or vertically (which means the resolution can in fact be 600x800). Likewise WURFL can tell you weather the device supports WiFi, 3G, .... but it will NOT tell you what the current connection is.

One easy way to detect the connection speed (not exact but in terms of slow/fast) is to use Javascript timer in HEAD like this:
<script type="text/javascript">
    var slowLoad = window.setTimeout( function() {
        // redirect to page/site dedicated to low bandwidth connection 
    }, 10 );

    document.addEventListener( 'load', function() {
        window.clearTimeout( slowLoad );
    }, false );
</script>


This basically adds a timer as soon as the page starts loading and then removes it when "load" event occurs. If the remove does not happen is specified time then the connection is "slow", the code in the timer is executed and we can take some action (for example redirect to lightweight version of the site). To add this to every page you can check Samuel Kong's excellent post http://www.liferay.com/web/samuel.kong/blog/-/blogs/adding-a-javascript-to-every-page or you can try CustomGlobalMarkup plugin I wrote sometime ago (unfortunately not yet updated to 6.2)
thumbnail
Aravinth Kumar, modifié il y a 7 années.

RE: Implementing RESS (Responsive Design With Server Components) in Liferay

Regular Member Publications: 152 Date d'inscription: 26/06/13 Publications récentes
Hi All,

Is there anyway to detect low bandwidth internet connection and based on that redirect site to lighter version site in liferay?

Is there any such feature in the latest versions of liferay?

Thanks in Advance.

Regards,
Aravinth