Forums

Home » Liferay Portal » English » 2. Using Liferay » General

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Ranjith kumar Chittuluri
Mobile Theme is not reflecting in all devices
December 27, 2012 3:18 AM
Answer

Ranjith kumar Chittuluri

Rank: New Member

Posts: 12

Join Date: December 13, 2011

Recent Posts

Hi

I am using liferay 6.1 GA1 for my development. and Mysql 5.5
I am facing a problem in mobile detection
I deploy the Wrufl war wurfl-web 6.1.0.x , I configure the mobile rules for specific OS
but its reflecting when we accessed from Android and its not reflecting mobiles which doesn't have android OS
please help me how can we implement to other OS also
is there any updations in the wurfl war ..?
I had downloaded the war from this location

http://sourceforge.net/projects/lportal/files/Liferay%20Plugins/6.1.0%20GA1/wurfl-web-6.1.0.1-ce-ga1-20120106155615760.war/download

how know which the device is accessing the web page from .VM file
is there any code or API is present so that we can get the device

I am attaching the war file also


Thanks in Advance
Ranjith Chittuluri
Attachments: wurfl-web-6.1.0.1-ce-ga1-20120106155615760.war (2,104.7k)
Milen Dyankov
RE: Mobile Theme is not reflecting in all devices
December 27, 2012 3:04 PM
Answer

Milen Dyankov

LIFERAY STAFF

Rank: Regular Member

Posts: 237

Join Date: October 30, 2012

Recent Posts

If it works for Android devices it means you have installed wurfl-web correctly.
Can you explain what you mean by reflecting and not reflecting? Whet exactly you are trying to do? What rules and rule groups you have defined? What actions are configured to take place when rules match? What are the priorities? Are you testing using real devices or emulators?
Ranjith kumar Chittuluri
RE: Mobile Theme is not reflecting in all devices
December 27, 2012 11:12 PM
Answer

Ranjith kumar Chittuluri

Rank: New Member

Posts: 12

Join Date: December 13, 2011

Recent Posts

Milen Dyankov:
If it works for Android devices it means you have installed wurfl-web correctly.
Can you explain what you mean by reflecting and not reflecting? Whet exactly you are trying to do? What rules and rule groups you have defined? What actions are configured to take place when rules match? What are the priorities? Are you testing using real devices or emulators?


Hi Milen Dyankov
Thanks for your quick reply

My requirement is to change the theme and content for the mobile device users
I had defined 3 rule groups as Per the OS used in the mobiles i.e I phone , Android, Symbian ( nokia )
I had defined the same action for all the 3 different groups with priority as Android -0 Nokia -1 Iphone-2
In android mobiles The theme is changing as defined in the action
The Theme modification action which I had assigned to the specific OS are not reflecting on the mobile devices
I am using it on live devices . not by changing user agent in computer browser
I am attaching the screen shots also Please Help me to figure-out the issue

Thanking in Advance

Thanks and Regards
Ranjith Chittuluri
Attachment

Attachment

Attachment

Attachment

Attachment

Attachments: Android mobile action.JPG (96.6k), mobile device rules for android.JPG (88.4k), mobile device rules for symbian.JPG (84.5k), mobile device rules.JPG (78.5k), rules assigned to page with proriets.JPG (110.0k)
Milen Dyankov
RE: Mobile Theme is not reflecting in all devices
December 28, 2012 6:02 AM
Answer

Milen Dyankov

LIFERAY STAFF

Rank: Regular Member

Posts: 237

Join Date: October 30, 2012

Recent Posts

From your screenshots it looks it's configured OK. Can you try by changing the user agent to some "standard" iOS one in your browser. If this way it works it may be the case that wurfl does not recognize the UA coming fro the actual device. It could be that the device is too new or has branded UA (apparently some telecommunication comapnies do that with the devices they sell)
INTHIYAZ SHAIK
RE: Mobile Theme is not reflecting in all devices
December 31, 2012 3:41 AM
Answer

INTHIYAZ SHAIK

Rank: New Member

Posts: 20

Join Date: November 24, 2011

Recent Posts

Hi ,
Are you using Seperate themes for PC and Mobile ?
If not then it is better to use two different Themes.
You can get the "Device Recognition Provider " from the markeplace-place (which is by default present in the Liferay6.1.1 tomcat bundle).
By using the "Device Recognition Provider " ,you can detech from which device the request is coming .
Based upon the screen size you can apply the css.
Ranjith kumar Chittuluri
RE: Mobile Theme is not reflecting in all devices
December 31, 2012 3:53 AM
Answer

Ranjith kumar Chittuluri

Rank: New Member

Posts: 12

Join Date: December 13, 2011

Recent Posts

Milen Dyankov:
From your screenshots it looks it's configured OK. Can you try by changing the user agent to some "standard" iOS one in your browser. If this way it works it may be the case that wurfl does not recognize the UA coming fro the actual device. It could be that the device is too new or has branded UA (apparently some telecommunication comapnies do that with the devices they sell)



Dear Milen Dyankov

Thanks for your quick reply and suggestion i tried it in different mobiles like Sony Ericsson,Nokia,Samsung which is having 3g compatible its not reflecting in all
is there any code to apply secific resolution for specific device
like we are writing separate css for ie6 & Mozilla if present please suggest

Thanks In advance


Regards
Ranjith Chittuluri
Ranjith kumar Chittuluri
RE: Mobile Theme is not reflecting in all devices
December 31, 2012 3:59 AM
Answer

Ranjith kumar Chittuluri

Rank: New Member

Posts: 12

Join Date: December 13, 2011

Recent Posts

INTHIYAZ SHAIK:
Hi ,
Are you using Seperate themes for PC and Mobile ?
If not then it is better to use two different Themes.
You can get the "Device Recognition Provider " from the markeplace-place (which is by default present in the Liferay6.1.1 tomcat bundle).
By using the "Device Recognition Provider " ,you can detech from which device the request is coming .
Based upon the screen size you can apply the css.



Dear INTHIYAZ SHAIK,

Thanks for your Reply and Suggestion
Yes I am using separate Theme for PC and Mobile
My main issue is that the another theme is not reflecting properly in mobile devices
Is there any updated Device Recognition Provider present for LIFERAY 6.1 GA1
can you please share any sample theme or code developed based on screen resolutions


Regards
Ranjith Chittuluri
INTHIYAZ SHAIK
RE: Mobile Theme is not reflecting in all devices
December 31, 2012 4:13 AM
Answer

INTHIYAZ SHAIK

Rank: New Member

Posts: 20

Join Date: November 24, 2011

Recent Posts

Hi

#set ($device =$theme_display.getDevice())
#set ($capabilities =$device.getCapabilities() )
#set ($is_mobile =$getterUtil.getBoolean($capabilities.get("is_wireless_device").getValue()))

Try to write this code in portal_normal.vm file to detect the device ,may it helps to you
Milen Dyankov
RE: Mobile Theme is not reflecting in all devices
December 31, 2012 6:37 AM
Answer

Milen Dyankov

LIFERAY STAFF

Rank: Regular Member

Posts: 237

Join Date: October 30, 2012

Recent Posts

That is a good advise. In fact I would disable/delete all device rules and use a simple theme which displays the device capabilities somewhere. This way accessing the portal with different devices you'll get to know how (if at all) they are recognized by WURFL.
Ranjith kumar Chittuluri
RE: Mobile Theme is not reflecting in all devices
January 1, 2013 5:00 AM
Answer

Ranjith kumar Chittuluri

Rank: New Member

Posts: 12

Join Date: December 13, 2011

Recent Posts

INTHIYAZ SHAIK:
Hi

#set ($device =$theme_display.getDevice())
#set ($capabilities =$device.getCapabilities() )
#set ($is_mobile =$getterUtil.getBoolean($capabilities.get("is_wireless_device").getValue()))

Try to write this code in portal_normal.vm file to detect the device ,may it helps to you


Dear "INTHIYAZ SHAIK "Thanks For your reply

I placed these code in my VM file I got all the details of the device and
I don't know how to use these code I am not good expert in liferay can you share me any war file or detail vm file for mobile theme
I am attaching the .txt file Which i got output for those code

Regards
Ranjith Chittuluri
Attachments: mobile theme.txt (27.3k)