News:

Wondering if this will always be free?  See why free is better.

Main Menu

Mobile Device Detect

Started by emanuele, March 07, 2012, 02:29:20 PM

Previous topic - Next topic

emanuele

Quote from: doughboy99 on October 11, 2012, 02:07:47 PM
http://www.xxx.co.uk/forum/index.php?http://www.xxx.co.uk/forum/mobiquo/mobiquo.phpThe database value you're trying to insert does not exist: current_topic
Function: get_topic_infoFile: /home/xxxxx/public_html/forum/mobiquo/mobiquo_common.php
Line: 399

Do you have any idea what might be causing this?
mmm...considering this mod adds only one file named "Subs-MobileDetect.php" I don't think your problem is with my mod mod...
Old Fossil's suggestion should be the right one.


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Rukey

Installed this mod, and it's very helpful! Absolutely fantastic. Although sometimes when I visit my forum it doesn't always default to the mobile theme (Using the SMFiphone4 mobile theme - Using a mobile device) and goes straight to the normal PC theme.

Not sure if this is possible, but is there anyway you can disable cookies to the forum via this mod? So it doesn't revert and default at the normal PC theme rather than staying on the mobile theme.

Thanks.

emanuele

I don't have any mobile device to test it.
I don't think the theme would mess with the cookies (I hope).

I think (don't remember exactly) the mod respect two things:
1) user's choice (i.e. if you use ?theme=1)
2) boards-specific themes (if you set a different theme for any of the boards
Both are intended behaviours.

If you are experiencing something different, it would be wonderful if you can identify exactly in what situations the mod fails to work. ;)


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

littlenicki

Hello Emanuelle,

could you maybe please do a SMF 1.1.17 compatible version of this mod? I'm using a mobile theme with my SMF 1.1.17 board and would like to get any mobile vistors redirected to it.

Thank you,

Nicole
Fomer SMF user. Switched to Invision Power Board and VBulletin

emanuele

Sorry, but it's very, very unlikely.

If someone else wants to convert it, the mod is available under an open license and can be changed and re-distributed by anyone. ;)


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

afam4eva

I'm sorry for bumping this thread...but i installed this mod but it's not redirecting to my chosen mobile site.

emanuele

Well...how are you using it to redirect to your "mobile site"? (and what do you mean with "mobile site"?)
What mobile device are you using?


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

afam4eva

Quote from: emanuele on February 02, 2013, 07:59:57 AM
Well...how are you using it to redirect to your "mobile site"? (and what do you mean with "mobile site"?)
What mobile device are you using?
I first installed my mobile site and then installed the mobile devices detect mod and select the theme that i want to use as the mobile default but it's not redirecting. is there something that i need to do?

emanuele

Answer that:
Quote from: emanuele on February 02, 2013, 07:59:57 AM
What mobile device are you using?

It may be the detection is not entirely up to date (even though it should be rather general) and not recognize your device.

Did you select a theme in your profile? I think I made it so that if you select a theme it doesn't override your choice (or maybe not? Don't remember).


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

afam4eva

^^^I'm using a blackberry but i've also tried it with other mobile devices.

What do you mean by "Did you select a theme in your profile?". How do i select a theme in my profile and which profile are you referring to?

emanuele

Quote from: afam4eva on February 02, 2013, 08:02:43 AM
I first installed my mobile site and then installed the mobile devices detect mod and select the theme that i want to use as the mobile default but it's not redirecting. is there something that i need to do?
Sorry, today I'm quite dumb... (let's blame the lack of sleep :P)
When you say "mobile site" do you mean a mobile theme or something else?

Can you put a link to your forum? And the id of the mobile theme? You can find it looking at the themes urls, for example going to admin > configuration > themes and layout > themes settings, selecting a theme (for example "SMF Default Theme - Curve")you will see an url like:
http://yourwebsite.tld/forum/index.php?action=admin;area=theme;th=1;eee21800=46c2a7ab9584dde1135e48b24e077167;sa=settings
the theme id is the number after the "th", in that example 1.


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

afam4eva

I mean "Mobile theme".

here the forum link www . nairaglobe . com

I've copied the link of the theme, so what do i do with it?

Badboy

@afam4eva

What happened to your copyright?
Nothing is true, everything is permitted.

afam4eva

Quote from: Badboy on February 02, 2013, 08:59:20 AM
@afam4eva

What happened to your copyright?
I've not forgotten about that. I'm still gonna put it. The site is really not public yet.

emanuele

You have something that sets the theme to your default in the session (don't think SMF does that by default, at least I don't remember it, but I may be wrong) and once that is set the mod uses the theme from the session and not the mobile theme.

What other mods do you have installed?


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

afam4eva

Quote from: emanuele on February 02, 2013, 09:28:43 AM
You have something that sets the theme to your default in the session (don't think SMF does that by default, at least I don't remember it, but I may be wrong) and once that is set the mod uses the theme from the session and not the mobile theme.

What other mods do you have installed?
How do i access this session if it exist.

These are the only mods that i have installed:

Mobile Device Detect

reCAPTCHA for SMF

Delete Spam Posts

Autocomplete

Ad Managment


emanuele

Can't reproduce the issue so I tend to think it's something specific to your site (and code). Not having the possibility to debug it I can't be sure what it could be...sorry.

As a dirty fix, you may change in Subs-MobileDetect.php:
Code (find) Select
if (!isset($_SESSION['id_theme']) && isset($modSettings['mobile_theme_id']) && CheckIsMobile())
to
Code (replace with) Select
if (isset($modSettings['mobile_theme_id']) && CheckIsMobile())
and useless, but it should work.

Quote from: afam4eva on February 02, 2013, 10:15:52 AM
These are the only mods that i have installed:
Apart from the mods you have something wrong on your code anyway (see the bunch of javascript in the middle of the page).


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

bigggan

#77
I would like a way when i click "view as desktop" on android it shows normal forum and not the selected with this mod. (Or on other device). If thats possible.

eric1234

Weird how come my admin account work so well for the mobile but not normal members?

When  I was with my admin account, every boards that I access is in mobile .

When I was with my normal account, boards that i access become normal theme instead of mobile theme. Even the homepage sometime also normal theme.

emanuele

Quote from: bigggan on February 12, 2013, 03:17:33 PM
I would like a way when i click "view as desktop" on android it shows normal forum and not the selected with this mod. (Or on other device). If thats possible.
That would be better to ask to the mobile theme author. ;)

Quote from: eric1234 on May 11, 2013, 09:59:36 AM
Weird how come my admin account work so well for the mobile but not normal members?

When  I was with my admin account, every boards that I access is in mobile .

When I was with my normal account, boards that i access become normal theme instead of mobile theme. Even the homepage sometime also normal theme.
mmm...yes, that's weird.
There shouldn't be any difference between admin and normal account. The mod overrides the "allow change theme" settings, so that shouldn't be a problem.
Are you by change using some "change theme" mod?
If something sets $_SESSION['id_theme'] then the mod doesn't do anything (i.e. if you add for example ?theme=1 to the url).


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Advertisement: