No, we still support multiple renditions (i.e., basic-mobile) to be
defined if that's what the blogger wants, for single-rendition the
blogger can use either a responsive theme or even a non-responsive one
(my smartphone just shrinks the image if it's non responsive, I can
enlarge it and view chunks of the blog page.)
The older code, if there was just the standard rendition defined, would
make a copy of it and make the copy the mobile rendition, requiring the
theme user to have to maintain two sets of templates even if they were
desired to stay identical (e.g., a responsive theme). When I took that
out -- no copies unless two renditions are defined in the theme.xml -- I
apparently didn't get the code right for the standard theme to be the
default one. I'll get it fixed.
As for the "browser user agent", I'm not sure if that "deviceType"
parameter is something that a Roller page creates once in a browser or
something all browsers supply regardless of the website that they are
on, Googling isn't bringing up much on that parameter so I'm assuming
the former. I'm pretty much new to this particular topic.
Glen
On 09/02/2014 02:45 AM, Greg Huber wrote:
If there is no "mobile" on the theme.xml for the theme it used to show the
default, so maybe something has changed.
The browser user agent is used to determine if its a mobile device. What I
do is to use the jquery mobile logic i.e. LiteDeviceResolver, I can update
roller but am not sure on the licensing etc on copying jquery code. As you
mentioned previously the preferred method now would be to use a responsive
design, rather than a separate theme, so this is kind of parked?
Cheers Greg
On 2 September 2014 01:49, Glen Mazza <glen.ma...@gmail.com> wrote:
Hi Team, I noticed today with Roller 5.1 the blogs are not rendering on
smartphones (at least mine, I have a Windows 8 smartphone that uses IE as
its browser) except for the combo basic-mobile theme, the only one that
provides explicit "mobile" rendition types. For the others, Roller just
returns a blank screen or a 404 or similar error page. To test, for my
website I created 5 empty blogs, one for each theme we offer:
https://web-gmazza.rhcloud.com/frontpage/
https://web-gmazza.rhcloud.com/gaurav/
https://web-gmazza.rhcloud.com/testdual/ (basic-mobile).
https://web-gmazza.rhcloud.com/frontpage/
https://web-gmazza.rhcloud.com/fauxcoly/
What I would like to have Roller do -- and I had incorrectly assumed was
already being done -- was for Roller to fall back to the "standard"
rendition type when the "mobile" rendition was not available, correct
anyway if you're using a responsive theme. Searching through the code I
think the only change I need to do is in class RollerVelocity[1], for those
getTemplate() methods that take a deviceType parameter, to attempt to get
the standard rendition type as a fallback if the mobile deviceType was
requested and is not available. I'll test it. Until a Roller 5.1.1 is
out, users should be able to duplicate renditions in their theme.xml,
defining the standard one as also the mobile one.
Couple of other concerns, in our MobileDeviceRepository class, our device
listing[2] used as a backup to determine if mobile is necessary may be
out-of-date, I think I can Google something more recent. Also, just to
confirm, line #88 of that same file, checks the user agent "deviceType"
parameter for "standard" or "mobile" to determine the type, but that
parameter is not normally sent by a browser, correct?
Regards,
Glen
[1] http://svn.apache.org/viewvc/roller/trunk/app/src/main/
java/org/apache/roller/weblogger/ui/rendering/
velocity/RollerVelocity.java?revision=1583506&view=markup#l96
[2] http://svn.apache.org/viewvc/roller/trunk/app/src/main/
java/org/apache/roller/weblogger/ui/rendering/mobile/
MobileDeviceRepository.java?revision=1611764&view=markup#l34