Hi everybody,
I’am recently trying a new project in pages. I was wondering if there is a way to built diferent layouts for pages and mobile. So the user see diferent component in case is using a desktop or mobile. As far as I have explored, sometimes the page layout is not as nice in the mobile version.
Any other options?
Many thanks.
Albert Puig
Have you tried the detect device integration? It might provide what youre looking for in temns of visibility settings.
1 Like
Hello Joe,
I’ve just tried and I guess this might work for the loged users but what about the ones that only visit the page without sign in in the very beginig? Any tips will be apreciate
Many thanks!
Albert
It should work the same for both. The only difference with Signed In users is that you can save the value in their User Profile, if you want. But you can still use the Integration to detect device attributes for non-signed in users (visitors).
1 Like
Oh, thats great. Could I have more details of how to do so? Thanks ;)!
It should just be a matter of adding a column to capture the appropriate device attribute, and then you could use that to control component visibility conditions. If you’re doing it for visitors, then you may need to ether add the column to several tables, or add it to one table and then use it as a single value in any other tables where it’s needed.
To be honest, I’m not sure which attribute would be most reliable - perhaps Window Height/Width? I think it’s something you’d need to experiment with using different devices.
1 Like
Sounds great, but just one last question.
How could I capture the device type without any user interaction since the first welcome first screen has to be different already… Many thanks for your help in advanced ;)!
It’s a computed column, so it should be available as soon as the App is loaded.
1 Like
Does this consume an Update every time a user uses the app? Or more like the Distance Column that does not?
1 Like
I assume it wouldn’t use any updates because it computed client side.
1 Like
OK Great. Thank you all ;)! Have a noce sunday.
Albert
1 Like
Just one more question about this, is there an option to capture the mobile lenguage with this integration so we offer the proper lenguage to the user straight away?
Many thanks.
Albert
This in a javascript column will provide the user’s language code.
return window.navigator.language;
1 Like
Oh great. I think I founded the type column but still havo some doubts of how to fill the fields. Here an screen shoot:
Any extra advise of how to conclude?. Many thanks in advanced;)
I don’t know how you plan to show different languages, but you could use that language code with an IF column to return different values based on language, or you could pass it into a third party service that might do translations.