Server side responsive design: yes or no?

Thor

Honorary Master
Joined
Jun 5, 2014
Messages
44,413
Reaction score
7,522
Location
Bellville
Just curious if this is worth knowing.

Would this not make it slower as it happens on the server?

Code:
if ( $detect->isMobile() ) {*

}*

// Any tablet device.if( $detect->isTablet() ){


*}
 
Just curious if this is worth knowing.

Would this not make it slower as it happens on the server?

Code:
if ( $detect->isMobile() ) {*

}*

// Any tablet device.if( $detect->isTablet() ){


*}

It depends what code you're running exactly but no, it wouldn't slow things down. If done correctly it might actually make it faster
 
You should keep it client side if possible. The device viewing the site or how the site/data is displayed is not the server side's concern.
 
Last edited:
By definition if you're using server side code to change the display then you are no longer using a "responsive" design, but are actually using an "adaptive" design.
 
By definition if you're using server side code to change the display then you are no longer using a "responsive" design, but are actually using an "adaptive" design.

You can easily do a mixture of the two, for example ress (Responsive Design + Server Side Components), or maybe the site is for the most part responsive but there is server side image optimization or some form of css processing.
 
Thanks for all the replies.

Currently I use media queries in the css

But read about this last night and just wanted to make sure what I do is correct.

I guess this would be perfect for images to serve full size images on desktop and serve a different mobile optimized image on mobile.

Although.... I do that already with media queries
 
You can render it server side, but you will need to design your application from the ground up with isomorphic in mind.
 
If you need to decide server-side on how to render front-end, then your architecture is wrong.

Html 5, AMP or bootstrap will sort you out. Server-side I would focus on caching, compression, security but not on presentation.
 
If you need to decide server-side on how to render front-end, then your architecture is wrong.

Html 5, AMP or bootstrap will sort you out. Server-side I would focus on caching, compression, security but not on presentation.

I'm on the same page as far as my understanding on the topic goes
 
If you need to decide server-side on how to render front-end, then your architecture is wrong.

Html 5, AMP or bootstrap will sort you out. Server-side I would focus on caching, compression, security but not on presentation.

Server side can be used for presentation, not to determine the layout, but to speed things up.
 
I always say "go with responsive", as it is the most reliable way of getting it to work on as many devices as possible, without making specific considerations on the server. If the site is big, and needs to serve slightly different content or if it uses a completely different navigation system, then you could use responsive for PCs and tablets, and then a mobile site for phones. Capitec does this. See what happens when you scale down the Capitec site.
 
I always say "go with responsive", as it is the most reliable way of getting it to work on as many devices as possible, without making specific considerations on the server. If the site is big, and needs to serve slightly different content or if it uses a completely different navigation system, then you could use responsive for PCs and tablets, and then a mobile site for phones. Capitec does this. See what happens when you scale down the Capitec site.

That message made my day!
 
Lol the capitec msg when u size it down to mobile

Looks like you’ve got a bit of a thing for responsive design...

But you can keep trying to resize until you’re blue in the face. While this site is responsive, we use device recognition as well to make it fast on phones, so you'll need to check it on your phone to see the small-screen version.
 
If you need to decide server-side on how to render front-end, then your architecture is wrong.

Html 5, AMP or bootstrap will sort you out. Server-side I would focus on caching, compression, security but not on presentation.

Yeah this is correct, it makes everything just a whole lot easier for all devs.

Pure frontend devs can focus on responsive dev this way. While pure backend devs can just focus on dev under the hood. That is if you have a decent MVC framework in place.
 
Top
Sign up to the MyBroadband newsletter
X