Hi,

I trying themekey as an option for redirecting to a different frontpage only for mobile users.

I've tried the theme switching option for mobile users where mobile users see a different theme for the frontpage only and that works great. This doesn't however solve my problem. I want mobile users to see a different frontpage (at a different URL) but still the same theme as my default.

so mobile users need to go to www.example.com/front-mobile instead of www.example.com/front

I've tried the redirecting rule chain but it doesn't seem to work with the following rules:
mobile_detect:isMobile = true
with a sub-rule as follows
drupal:is_front_page = true with the target set to www.example.com/front-mobile

What else should I try?

Thanks

Comments

spuky’s picture

Ran in the same Issue today seems the redirects are not firing when themes are set on the Frontpage...

I helpt myself by creating a fake redirect theme... containing 2 files..

fakeredirect.info

name = Fake Redirect Theme
description = redirect to /front-mobil
core = 7.x

and an html.tpl.php

<?php
global $base_url;
drupal_goto($base_url . '/front-mobil');

And just assign that fake theme when Conditions are meet sorry had not the time for digging around.

nravens’s picture

This seems to work now for some reason without changing anything(with settings as I've described above) . I just carried on with something else and came back to this after a few weeks and it seems to work now.

I'll test on other mobile devices because I was using a Samsung before and now using a Sony and it works...

mkalkbrenner’s picture

Status: Active » Closed (won't fix)

Ok, I close this issue for now. Feel free to re-open it if the issue raises again or if you could provide more information.