Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: Fabius85 on May 14, 2010, 01:58:13 AM

Title: SMF4iPhone Mod
Post by: Fabius85 on May 14, 2010, 01:58:13 AM
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=2408)
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fcustom.simplemachines.org%2Fmods%2Findex.php%2Faction%2Cdownload%2Fmod%2C2408%2Fid%2C162702%2Fimage&hash=e21ee32bd1e8aae7b782511783eba3696863fb09) (http://custom.simplemachines.org/mods/index.php?action=download;mod=2408;id=162701;image)

A mod designed to work with SMF4iPhone Theme (Link (http://custom.simplemachines.org/themes/index.php?lemma=2089)).
If installed, SMF will use SMF4iPhone Theme if it detects that you're using an iPhone. No need to choose the theme in your layout settings!
The mod is highly configurable and gives the possibility to choose the best theme for every mobile device, even interacting with Curve Mobile, Mobile Theme or any other theme.

Summary
The mod uses the Movila Free Device Detection (http://www.moviladetection.com/detectfree/) which is a free server that detects wether or not you are using a mobile device. This service takes some of the problems out of the picture. It will check the user agent and also the domain names that are used for mobile devices.

After the mobile device is detected, filters defined in "Admin > Configuration > Modification Settings > SMF4iPhone" are used to send a specified user agent to one of previously set themes. If a user agent is not found, the mobile device will go to the failsafe such as wap2 or a theme you specify.

Features Of This Mod
* Uses Movila Free Device Detection service to ensure that a mobile device is reading your forum
* Automatically detects iPhone device (and others) and transfers to the theme
* Can manage the transfer of up to four (4) themes
* User agent list can be adjusted in Modification Settings
* Theme ID can be changed in Modification Settings
* If SMF4iPhone Theme and some other themes are installed before the mod, it will automatically detect the theme IDs and set them by default in Modification Settings
* Supports SMF caching system

Languages
These are the supported languages:
* Dutch (Thanks to Mr. Jinx)
* Dutch-UTF8 (Thanks to Mr. Jinx)
* English
* English-UTF8
* French
* French-UTF8
* German (Thanks to Chili)
* German-UTF8 (Thanks to Chili)
* Italian
* Italian-UTF8
* Spanish_ES (Thanks to videoed)
* Spanish_ES-UTF8 (Thanks to videoed)
* Swedish (Thanks to Richard Roe)
* Swedish-UTF8 (Thanks to Richard Roe)

For SMF 2.0 RC2, RC3 and RC4 Only
SMF4iPhone Mod is for SMF 2.0 RC2, RC3 and RC4 only.

What's new in this version
v1.1   (26/11/2010)

* SMF 2.0 RC4 compatibility.
* Added checkbox to disable mobile theme automatic switch for every user in: Profile > Look and Layout
* Added theme names to the selection boxes in Mod's settings. Now they will appear like "(ID) Theme Name" so you dont need anymore to serach for theme ID by yourself.
* Added new languages: French, German and German-UTF8 (Thanks to Chili), Spanish_ES and Spanish_ES-UTF8 (Thanks to videoed), Swedish and Swedish-UTF8 (Thanks to Richard Roe).
* Fixed UTF-8 chars not converted to their respective HTML entity in some language files.
* Updated all language translations.
* Better alignment of "additional notes" at the end of SMF4iPhone Mod settings page.
* Some improvements to the code.

Donations
Please donate to support!
If you like SMF4iPhone Theme donate to Fabius: (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.paypal.com%2Fen_GB%2Fi%2Fbtn%2Fbtn_donate_LG.gif&hash=fadd12cd7406061e38b6416a5a3a19f7d6257338) (https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=fabius85%40gmail%2ecom&lc=GB&item_name=Fabius&item_number=SMF4iPhone&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donate_LG%2egif%3aNonHosted)
If you like SMF4iPhone Mod donate to butchs: (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.paypal.com%2Fen_GB%2Fi%2Fbtn%2Fbtn_donate_LG.gif&hash=fadd12cd7406061e38b6416a5a3a19f7d6257338) (https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=UJTMMF8FKGLZ6&lc=US&item_name=butchs%2f%20continued%20updates&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted)
Title: Re: SMF4iPhone Mod
Post by: farfromperfection on May 17, 2010, 10:55:33 PM
Hi, I know I've not been around for a while, and while I appreciate your editing of my theme I'm not too comfortable with the donation buttons there.
Title: Re: SMF4iPhone Mod
Post by: butchs on May 18, 2010, 09:20:16 AM
I am not sure why the theme is here with the mod.  I guess to keep things simple.  Nevertheless, the mod is an original work.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on May 18, 2010, 11:20:13 AM
Quote from: butchs on May 18, 2010, 09:20:16 AM
I guess to keep things simple.
yep, even if theme and mod can work standalone, and were approved separately, i preferred to put both on both download pages
Title: Re: SMF4iPhone Mod
Post by: searchgr on May 21, 2010, 02:58:15 PM
I don't have iphone. Is there any way to check it through my browser?
Title: Re: SMF4iPhone Mod
Post by: butchs on May 21, 2010, 04:36:26 PM
Use a UA faker.
Title: Re: SMF4iPhone Mod
Post by: searchgr on May 21, 2010, 05:43:33 PM
UA faker is for those that use iphone. As i said, i don't have iphone.
Title: Re: SMF4iPhone Mod
Post by: searchgr on May 22, 2010, 12:32:54 AM
I had many cache errors and the instruction to turn the caching on.
I wonder what is better, to turn the caching of my forum on or to choose: Skip cache errors.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on May 22, 2010, 10:59:52 AM
Quote from: searchgr on May 21, 2010, 05:43:33 PM
UA faker is for those that use iphone. As i said, i don't have iphone.
if you use firefox, try this:
https://addons.mozilla.org/en-US/firefox/addon/59/

Quote from: searchgr on May 22, 2010, 12:32:54 AM
I had many cache errors and the instruction to turn the caching on.
I wonder what is better, to turn the caching of my forum on or to choose: Skip cache errors.
well, if you dont want to use the cache, then enable "Skip caches errors". if you think that cache can be useful for you, then enables cache :D
Title: Re: SMF4iPhone Mod
Post by: butchs on May 22, 2010, 11:23:57 AM
To test wait 24 hours and use the following UA faker methods:
Title: Re: SMF4iPhone Mod
Post by: searchgr on May 22, 2010, 02:59:09 PM
thank you
Title: Re: SMF4iPhone Mod
Post by: searchgr on May 22, 2010, 05:10:09 PM
Quote from: butchs on May 22, 2010, 11:23:57 AM
To test wait 24 hours and use the following UA faker methods:

  • Windows use FireFox with the [nofollow]"Modify Headers" (https://addons.mozilla.org/en-US/firefox/addon/967)[/nofollow] add-on.
  • Macintosh, [nofollow]"enable the Develop menu" (http://macs.about.com/od/usingyourmac/qt/safaridevelop.htm)[/nofollow] in Safari.


Strange but it doesn't work for firefox. Some members are able to get the theme, some others no.
Do i have to add some more phrases in the mod's textbox? The addon is for iphone3 (as it says).
Title: Re: SMF4iPhone Mod
Post by: butchs on May 22, 2010, 09:03:53 PM
Yes.
:)
Title: Re: SMF4iPhone Mod
Post by: searchgr on May 23, 2010, 02:01:37 AM
currently the phrases are the following: iphone|ipod|android|mobile|Safari Mobile

Can you give me a full list of them?


For example i can see with no problems Mr. Jinx's forum (http://www.chelloo.com/upc/) but the mod can't detect my forum. I wonder what's going wrong.
Title: Re: SMF4iPhone Mod
Post by: overyde on May 25, 2010, 05:49:07 AM
Hi,
    I have installed the smf4iphone Theme followed by the mod.
When i load up the website on my iphone it directs me to the default curve theme (even though my default theme is N2010 (2.0 RC3).
I have set in the mod the correct theme id's of 36 for iphone theme and 35 for my N2010 theme but it still does not work.
Manually loading the theme on the phone works ok ([nofollow]http://www.baby-nation.com/?theme=36[nofollow])

Any help greatly appreciated :)

Update: after deleting the cache it loaded the iphone theme, however the moment i clicked logon it changed me to my N2010 theme. :-/
Title: Re: SMF4iPhone Mod
Post by: butchs on May 25, 2010, 08:51:37 AM
Quote from: overyde on May 25, 2010, 05:49:07 AM
Update: after deleting the cache it loaded the iphone theme, however the moment i clicked logon it changed me to my N2010 theme. :-/

The mod only switches you.  The theme does the rest.  Sounds like an old theme?  Please check the theme thread for help.
Title: Re: SMF4iPhone Mod
Post by: DEK24 on May 25, 2010, 11:45:24 AM
I use Tiny Portal on my forum and it comes up all whacky on the mobile theme. Is there a way to disable it when browsing mobile?
Title: Re: SMF4iPhone Mod
Post by: Afro on May 26, 2010, 07:29:43 AM
In other words, this mod interacts with curve mobile theme without installing the associated mod. (curve-mobile-mod) ?
Title: Re: SMF4iPhone Mod
Post by: butchs on May 26, 2010, 09:57:56 AM
It will load curve mobile theme and 3 others.  No need for the curve-mobile mod.
8)
Title: Re: SMF4iPhone Mod
Post by: butchs on May 26, 2010, 09:59:17 AM
Quote from: DEK24 on May 25, 2010, 11:45:24 AM
I use Tiny Portal on my forum and it comes up all whacky on the mobile theme. Is there a way to disable it when browsing mobile?

The mod switches once in 24 hours so you can manually change your theme ie "?theme=0"

Do not know much about Tiny Portal though..
Title: Re: SMF4iPhone Mod
Post by: DEK24 on May 26, 2010, 03:01:50 PM
Quote from: butchs on May 26, 2010, 09:59:17 AM
Quote from: DEK24 on May 25, 2010, 11:45:24 AM
I use Tiny Portal on my forum and it comes up all whacky on the mobile theme. Is there a way to disable it when browsing mobile?

The mod switches once in 24 hours so you can manually change your theme ie "?theme=0"

Do not know much about Tiny Portal though..

If you don't mind. Check out my forum on your mobile device.

http://johnnyjungle.com/forum
Title: Re: SMF4iPhone Mod
Post by: booch_21 on May 28, 2010, 08:16:31 AM
I have a Droid and found the Tapatalk app solution for good mobile use of my forum.  Then I come across this theme and mod.  Wow!  Nice work to everyone involved! 

One very minor suggestion.  Perhaps a rename from "iPhone" to something that includes all mobile smartphones, since that is what you are really doing.  I know, very nitpicky!   ;D

Donations have been sent!  Keep up the awesome work!
Title: Re: SMF4iPhone Mod
Post by: Afro on May 29, 2010, 05:14:59 AM
^ You have a point. Its not just for iPhone , The name is misleading.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on May 30, 2010, 01:54:04 PM
Quote from: Afro on May 29, 2010, 05:14:59 AM
^ You have a point. Its not just for iPhone , The name is misleading.
yes, it's not just for iphone. however this mod was created originally to auto-switch between smf4iphone theme and other desktop themes, and so it's called SMF4iPhone Mod.
also SMF4iPhone theme can be viewd by other devices than an iPhone, but it's designed in an iPhone style and it's designed to fit on an iPhone display, so it's called SMF4iPhone Theme :D
Title: Re: SMF4iPhone Mod
Post by: Raffoz on June 04, 2010, 06:18:51 AM
is blackberry supported by the mod?

if not, how to add?
Title: Re: SMF4iPhone Mod
Post by: Afro on June 04, 2010, 06:19:34 AM
^ Yes
Title: Re: SMF4iPhone Mod
Post by: Raffoz on June 04, 2010, 06:23:12 AM
ok thanks... it's in the seocnd box... i couldn't read it, because i had to enlarge the box... :)
Title: Re: SMF4iPhone Mod
Post by: NaYa on June 05, 2010, 10:15:15 AM
But how to upload a file to forum by using this ?
Any IDEA ? Mobile internet is growing.

Nowadays peoples downloading and uploading DvD movies and Files with their Mobiles.

Is there any way to add upload option ?

Title: Re: SMF4iPhone Mod
Post by: Raffoz on June 05, 2010, 10:26:26 AM
Quote from: NaYa on June 05, 2010, 10:15:15 AM
But how to upload a file to forum by using this ?
Any IDEA ? Mobile internet is growing.

Nowadays peoples downloading and uploading DvD movies and Files with their Mobiles.

Is there any way to add upload option ?



the skin is for iPhone, principally...
and from iphone, you can't select any files on the device...
Title: Re: SMF4iPhone Mod
Post by: NEO-BAHAMUT- on June 14, 2010, 09:28:55 AM
Hi guys,

just wondering if anyone can help me set this up. So ive just upgraded my forum to version 2.0 RC3. I have installed the mod and applied it. Everything has installed successfully.

Now to the problem. If you look at the image titles "What is this"... basically I am wondering what i set here?

Image "2" is all the themes i currently have installed. Im guessing 1 is the top theme?

Please can someone talk me through how to set this up. Basically when i go on my iphone and hit my forum i get this error...

"parse error: syntax error, unexpected '.' in
/hosted/subs/ulmb/p/s/pspgamerworld/public_html/themes/smf4iphone_theme/languages/iphone.language.english.php"

Im guessing there is a . in there that shouldnt be but not entirely sure.

Please help

thanks.

Added -  This is the code for the above file that seems to be having a problem..

<?php
// Version: 2.0 RC3; iPhone// Important! Before editing these language files please read the text at the top of index.language.english.php.

.language

$txt
['iClassic'] = 'Classic'//Label for the button which switches to full desktop theme
$txt['iMenu'] = 'Menu';
$txt['iBack'] = 'Back';
$txt['iTopics'] = 'Topics';
$txt['iLoading'] = 'Loading';

/* Board Index */

$txt['iBoards'] = 'Boards';
$txt['iLatestPosts'] = 'Latest Posts';

$txt['iPosted'] = 'Posted'//Example: *Posted* x minutes ago;

$txt['iShow'] = 'Show'//Childboards
$txt['iHide'] = 'Hide'//Childboards

/* Time, singular and plural */

$txt['iSecondsAgo'] = 'seconds ago';
$txt['iMinutesAgo'] = 'minutes ago';
$txt['iHoursAgo'] = 'hours ago';
$txt['iDaysAgo'] = 'days ago';
$txt['iWeeksAgo'] = 'weeks ago';
$txt['iMonthsAgo'] = 'months ago';

$txt['iSecondAgo'] = 'second ago';
$txt['iMinuteAgo'] = 'minute ago';
$txt['iHourAgo'] = 'hour ago';
$txt['iDayAgo'] = 'day ago';
$txt['iWeekAgo'] = 'week ago';
$txt['iMonthAgo'] = 'month ago';

$txt['iBy'] = 'by';

/* Tab Bar */

$txt['iHome'] = 'Home';
$txt['iSearch'] = 'Search';
$txt['iMessages'] = 'Messages'
$txt['iProfile'] = 'Profile';
$txt['iLogout'] = 'Logout';

/* Topic display */

$txt['iQuoting'] = 'Quoting';
$txt['iOn'] = 'On';
$txt['iOff'] = 'Off';


/* Pages */

$txt['iPage'] = 'Page';
$txt['iOf'] = 'of'//for example: page 1 *of* 2.
$txt['iPrev'] = 'Prev'//short for "previous"
$txt['iNext'] = 'Next';

/* Posting */

$txt['iSubject'] = 'Subject';
$txt['iCode'] = 'Code'//Verification code
$txt['iVerify'] = 'Verify'//Field to fill in with verifcation code

$txt['iMessage'] = 'Message'//The heading of the message field when posting or sending a PM
$txt['iPost'] = 'Post'//The submit button

/* PM */

$txt['iTo'] = 'To'//Name for the "To: " field
$txt['iSend'] = 'Send'//The submit button

/* Profile */

$txt['iPosts'] = 'posts'//kept lowercase as in the iPhone Contacts application. Try to kep these short.
$txt['iEmail'] = 'email';
$txt['iRegistered'] = 'registered';
$txt['iTitle'] = 'title'//Custom title
$txt['iText'] = 'text'//Personal text
$txt['iKarma'] = 'karma';
$txt['iGender'] = 'gender';
$txt['iAge'] = 'age';
$txt['iLocation'] = 'location';

$txt['iLastActive'] = 'last active';
$txt['iIP'] = 'ip';
$txt['iHostname'] = 'hostname';
$txt['iLocalTime'] = 'local time';

$txt['iSendPM'] = 'Send PM';
$txt['iSendEmail'] = 'Send Email';

/* Search */

$txt['iAlert'] = 'Please enter a word of at least 3 letters to search';

/* Login */

$txt['iRemember'] = 'Remember';
$txt['iSubmit'] = 'Submit';

/* Register */

$txt['iChoose'] = 'Choose';
$txt['iRegisterVerify'] = 'Verify';
$txt['iVerification'] = 'Verification';
$txt['iAgreement'] = 'Registration Agreement';
$txt['iMore'] = 'more'//example: more...
$txt['iDone'] = 'Done';
$txt['i13yo'] = 'I am at least 13 years old';
$txt['agree'] = 'I Agree';

?>
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on June 14, 2010, 10:06:38 AM
About the settings of the mod, if you first installed SMF4iPhone Theme, and then SMF4iPhone Mod, then the ID of SMF4iPhone Theme is automatically selected as theme #1 in Mod's settings. The theme IDs are numbered in order of installation, so don't think that the first one in the list shown in "2.jpg" image is the theme has ID 1. To check theme id you can just type your forum URL followed by "?theme=N" where N is the number of the ID. So:
http://www.yoursite.com/forum/index.php?theme=5
will show your forum using the theme which has ID number 5.
you can setup to 3 theme's with SMF4iPhone Mod and assign auto switch to that themes for the user agents you prefer.
Then you have to set the ID of your default forum theme, and the theme which should be used as "safe mode", you can keep default settings (wap2).
In the next release of the mod i'll add the possibilty to select themes by name instead of ID, as it is easier to configure.

About the parse error you get, you should extract again "iPhone.language.english.php" from the package, and reupload it, without touching anything in it.
Title: Re: SMF4iPhone Mod
Post by: NEO-BAHAMUT- on June 14, 2010, 11:40:56 AM
Hi Mate,

thanks for the quick reply. I managed to sort it out with your help. There must have been an error when installing the theme.... Not too sure but it works now.

Ive now ran in to another problem. If you take a look at your self at... www.pspgamerworld.ulmb.com (on your phone)... It takes you to the Index page but not the mobile view. However if you click on one of the categories it then takes you to the mobile view. Is there something i have missed out here? Im sure that if i hit www.pspgamerworld.ulmb.com then it should take me to the Mobile view where i can login etc?
Title: Re: SMF4iPhone Mod
Post by: NEO-BAHAMUT- on June 15, 2010, 06:28:50 AM
Hi Fabius,

Can you help me with my problem its still happening.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on June 15, 2010, 10:13:11 AM
Quote from: NEO-BAHAMUT- on June 14, 2010, 11:40:56 AM
Hi Mate,

thanks for the quick reply. I managed to sort it out with your help. There must have been an error when installing the theme.... Not too sure but it works now.

Ive now ran in to another problem. If you take a look at your self at... www.pspgamerworld.ulmb.com (on your phone)... It takes you to the Index page but not the mobile view. However if you click on one of the categories it then takes you to the mobile view. Is there something i have missed out here? Im sure that if i hit www.pspgamerworld.ulmb.com then it should take me to the Mobile view where i can login etc?
if i open your website with my iphone it takes me directly to the iphone theme, so you maybe had the cookie already set. if you clear your cookies you'll se that it works properly ;)
Title: Re: SMF4iPhone Mod
Post by: NEO-BAHAMUT- on June 15, 2010, 11:36:21 AM
Ahh i thank you for letting me know that... I was only clearing my history which in turn i thought cleared my cookies and cache. Works a treat thanks.
Title: Re: SMF4iPhone Mod
Post by: pingpongrob on June 16, 2010, 07:56:58 PM
Hi Fabius,
I had SMF R.0 RC2 installed and the Mod and theme work well on my iphone, when I installed (not upgraded) RC3 and installed the Theme and the Mod, I get nothing on my iphone.

Can you help please.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on June 16, 2010, 10:42:20 PM
Quote from: pingpongrob on June 16, 2010, 07:56:58 PM
Hi Fabius,
I had SMF R.0 RC2 installed and the Mod and theme work well on my iphone, when I installed (not upgraded) RC3 and installed the Theme and the Mod, I get nothing on my iphone.

Can you help please.

it is a bit hard to help if you just tell me "it doesnt work" without any specific information about what's wrong with it but follow these steps and see if it helps...




STEP  1
Did you get any errors while installing theme and/or mod?
If not go to next step. If you got errors, tell me what happened so i can help you.

STEP 2
Check if you configured correctly SMF4iPhone Mod settings (in Admin > Modification Settings > SMF4iPhone)
Check if theme's IDs you set are correct. If not, then set them correctly and click "Save".

STEP 3
You need to clear your forum cache, not only your browser cache, so:
First go to Admin > Forum Maintenance, and under "Empty the file cache" click on Run task now.
Then if you have an iPhone/iPodTouch -> into your iPhone/iPodTouch go to Preferences > Safari and tap on Clear history, Clear cookies, Clear cache. Go to next step.
If you're testing theme/mod using a desktop browser with a User Agent Faker -> Set your fake iPhone User Agent. Clear your browser cookies related to your forum and your browser cache. Go to next step.

STEP 4
Using Safari Mobile (or your desktop browser) try to open your forum index. Be sure that "?theme=#" parameter is NOT set at the end of the url you enter, so just "http://www.yoursite.com/forum/index.php".
Title: Re: SMF4iPhone Mod
Post by: pingpongrob on June 16, 2010, 11:19:44 PM
Hi Fabius,
Thanks for taking the time to help.
1. No errors on installation of both the Mod & Theme.
2. Not 100% sure about the number that I should select.
3. Cleared both Cache & Cookies on my iPhone - Cleared cache on my Firefox Browser
4. When I open http://www.affordablett.com.au/smf/index.php (http://www.affordablett.com.au/smf/index.php), in Firefox I get my standard web page - as expected.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on June 17, 2010, 08:47:06 AM
Quote from: pingpongrob on June 16, 2010, 11:19:44 PM
Hi Fabius,
Thanks for taking the time to help.
1. No errors on installation of both the Mod & Theme.
2. Not 100% sure about the number that I should select.
3. Cleared both Cache & Cookies on my iPhone - Cleared cache on my Firefox Browser
4. When I open http://www.affordablett.com.au/smf/index.php (http://www.affordablett.com.au/smf/index.php), in Firefox I get my standard web page - as expected.
Did you set SMF4iPhone Theme selectable by users? Go to:
Admin > Themes and Layout > Manage and Install > Themes that the user is able to select
click on [ Show the list of themes ] and see if SMF4iPhone is checked.

2. You can check the proper ID of your SMF4iPhone Theme this way:
Profile > Look and Layout > Current Theme
click on (change)
Search for SMF4iPhone Theme and move your mouse on [Use this theme] -without clicking on it!-
In your browser statusbar you should see a link like this:
http://www.yoursite.com/forum/index.php?action=theme;sa=pick;u=1;th=3;
"th" is the ID of your theme, and you have to set it in SMF4iPhone Mod settings.

3. You need to clear also your FORUM CACHE:
Admin > Forum Maintenance > Empty the file cache
click on "Run task now" button.

After following all these steps, clear again you Safari Mobile cookies and cache, and see if the theme loads correctly.
Title: Re: SMF4iPhone Mod
Post by: pingpongrob on June 17, 2010, 09:08:28 AM
Its really strange, I wasnt logged in (just Guest), and the standard view was present. Once I logged in the iPhone Theme worked.
I find RC3 really buggy with packages compared with RC2.

Thanks for your help Fabius  :)
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on June 18, 2010, 07:13:08 AM
Quote from: pingpongrob on June 17, 2010, 09:08:28 AM
Its really strange, I wasnt logged in (just Guest), and the standard view was present. Once I logged in the iPhone Theme worked.
but it should load the iphone theme even if you are not logged in ???
Title: Re: SMF4iPhone Mod
Post by: pingpongrob on June 18, 2010, 09:07:18 PM
I believe you are correct, but for some strange reason the Normal web view was present until I logged in.  Their is also a classic button, that take me back to the normal view.

Just as a matter of interest, how do you get the main logo to sit correctly, and what size should it be for the Portrait iPhone view.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on June 20, 2010, 08:13:06 AM
Quote from: pingpongrob on June 18, 2010, 09:07:18 PM
Just as a matter of interest, how do you get the main logo to sit correctly, and what size should it be for the Portrait iPhone view.
size of the image depends on what effect you prefer to have on your logo. by the way you can manage with it in the style.css file, if you search for:
Quote#logo{

   height: 78px;
   margin-bottom: 8px;
   margin-left: 9px;
   margin-right: 9px;
   margin-top: 14px;
   background: url(images/logo.jpg) 0px -30px no-repeat;
   border: 1px solid #aaa;
   -webkit-border-radius: 8px;
   clear: both;
   overflow: hidden;
   z-index: 0;

}

#logocover{

   height: 211px;
   background: url(images/logocover.png) right repeat-y;
   -webkit-border-radius: 10px;
   margin-right: -1px;
   margin-top: -2px;
   z-index: 1;
}
there you can change the properties of the logo positioning and effects.
Title: Re: SMF4iPhone Mod
Post by: ABMoto on June 28, 2010, 10:43:13 PM
Damn forum, keeps timing out so I have to write this all over again!

...Mad props for this theme/mod!  I have, however, come across a few bugs.

1.  After initial installation and logging in, the links on the bottom don't bring me anywhere.  I had to manually update the  a href='#' in the index.template.php file to make them work.

2.  The search page doesn't work (i go to the page but the search field doesn't appear, it's just a blank page).  albertamoto[dot]com/search/ works in a browser but not on a smartphone using this theme

3.  Video is wonky.  If you try to view a video you posted, it'll try to edit the post instead.  Logging out and attempting to view the video, however, will work.

Thanks again for the great mod/theme.  I'm coping this before I submit this time!
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on June 29, 2010, 07:16:57 AM
Quote from: ABMoto on June 28, 2010, 10:43:13 PM
Damn forum, keeps timing out so I have to write this all over again!

...Mad props for this theme/mod!  I have, however, come across a few bugs.

1.  After initial installation and logging in, the links on the bottom don't bring me anywhere.  I had to manually update the  a href='#' in the index.template.php file to make them work.

2.  The search page doesn't work (i go to the page but the search field doesn't appear, it's just a blank page).  albertamoto[dot]com/search/ works in a browser but not on a smartphone using this theme

3.  Video is wonky.  If you try to view a video you posted, it'll try to edit the post instead.  Logging out and attempting to view the video, however, will work.

Thanks again for the great mod/theme.  I'm coping this before I submit this time!
1 and 2. i really dont have any matters (and no one yet reported any problem with buttons at the bottom, or search page).
3. you have to disable quoting (button on the top of every topic page) to be able to "tap" anywhere without opening "reply with quoting" page.
Title: Re: SMF4iPhone Mod
Post by: ABMoto on June 29, 2010, 11:07:16 AM
Thanks for the quick response Fabius.  Ran across another issue as well with another website t2iforum[dot].com

1.  The 'Boards' - 'Latest Posts' at the top of the smf4iphone theme are not there (they're there on my other site).  I looked at the code and they should be triggered on if($settings['number_recent_posts'] > 1).  I tried changing the 1 to a 0 and then emptying the file cache on the site then clearing the cache and cookies on my android phone and then it didn't even pick up the smf4iphone theme when I loaded it up.  I reset it to 1 then cleared the cache from the website and phone and the cookies from my android phone and it loaded the theme but again without the 'Boards' and 'Latest Posts' buttons.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on June 29, 2010, 08:12:37 PM
Quote from: ABMoto on June 29, 2010, 11:07:16 AM
Thanks for the quick response Fabius.  Ran across another issue as well with another website t2iforum[dot].com

1.  The 'Boards' - 'Latest Posts' at the top of the smf4iphone theme are not there (they're there on my other site).  I looked at the code and they should be triggered on if($settings['number_recent_posts'] > 1).  I tried changing the 1 to a 0 and then emptying the file cache on the site then clearing the cache and cookies on my android phone and then it didn't even pick up the smf4iphone theme when I loaded it up.  I reset it to 1 then cleared the cache from the website and phone and the cookies from my android phone and it loaded the theme but again without the 'Boards' and 'Latest Posts' buttons.
the tabs appears if you enabled recent posts showing in the theme settings. recent posts to be displayed must be at least 1 to make that tab appear
Title: Re: SMF4iPhone Mod
Post by: ABMoto on June 30, 2010, 11:02:46 AM
Don't think that's it as I have recent posts enabled and set to 5 on both of my sites (see screenshots).

Also, how does the recent post logic work and how could I increase the number of recent posts that it shows (ex.  for the site where it works, it's set to 5 recent posts but the smf4iphone theme only shows 3)?
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on July 01, 2010, 05:35:05 AM
Quote from: ABMoto on June 30, 2010, 11:02:46 AM
Don't think that's it as I have recent posts enabled and set to 5 on both of my sites (see screenshots).

Also, how does the recent post logic work and how could I increase the number of recent posts that it shows (ex.  for the site where it works, it's set to 5 recent posts but the smf4iphone theme only shows 3)?
did you set it both on default smf default theme and iphone theme?
Title: Re: SMF4iPhone Mod
Post by: ABMoto on July 01, 2010, 12:46:03 PM
You're the man!  That was it!  Thanks you so much.  Now the Latest Posts are showing for the t2iforum smartphone site!

At the risk of being that annoying guy one more time, I have one last issue.

When clicking on 'Latest Posts' in t2iforum[dot]com through the smf4iphone theme, the content headers appear on top of the recent posts (see 02.jpg attachment - ex. Introductions, T2i / 550D General Discussion, T2i / 550D Video-Specific Discussion, ...etc...) instead of just the recent posts appearing (this is working correctly on my other site albertamoto[dot]com).  The only difference between the two forums is that the one working (albertamoto[dot]com) is using child boards and this one isn't.  I think I've narrowed down the issue to the following code in iphone.js:

Quote
function iswitch(id){

   if(id=='switcher'){
      document.getElementById(id).id = 'switcheralt';
     
      var x= document.getElementsByTagName('ul');
     
      for(var i = 0;i<x.length;i++){
         
         if(x.id=='contentrecent')
            x.style.display='block';
         if(x.id=='contentboards')
            x.style.display='none';
            }
      document.getElementById('childbuttondiv').style.display='none';
           
      var x= document.getElementsByTagName('h2');
     
      for(var i = 0;i<x.length;i++){
         
         if(x.id=='contentrecenth2')
            x.style.display='block';
         if(x.id=='contentboardsh2')
            x.style.display='none';

            }
     
   }else{
   
      document.getElementById(id).id = 'switcher';
     
      var x= document.getElementsByTagName('ul');
     
      for(var i = 0;i<x.length;i++){
         
         if(x.id=='contentrecent')
            x.style.display='none';
         if(x.id=='contentboards')
            x.style.display='block';
            }
      document.getElementById('childbuttondiv').style.display='block';
           
      var x= document.getElementsByTagName('h2');
     
      for(var i = 0;i<x.length;i++){
         
         if(x.id=='contentrecenth2')
            x.style.display='none';
         if(x.id=='contentboardsh2')
            x.style.display='block';

            }
   
      }
   

}

Any suggestions on what this might be?
Title: Re: SMF4iPhone Mod
Post by: Leemy on July 01, 2010, 01:14:10 PM
Fabius,

I installed the theme, which loads properly. I installed the mod and directed mobile user agents to the theme (#35).  But when i visit from my iphone, it still shows the normal site. Can you advise? The site is bhangrateams forum.com (without the space) Thanks!
Title: Re: SMF4iPhone Mod
Post by: ABMoto on July 01, 2010, 03:48:19 PM
Leemy,

I tried accessing your site with my Nexus One and didn't get the smf4iphone theme.

Have you tried the following:

1.  Go to Admin -> Configuration -> Themes and Layouts -> Manage and Install
     Then make sure that 'Allow members to select their own themes.' is checked and that the smf4iphone theme is checked
     (see attached manage_install_themes.jpg)

2.  Go to Admin -> Maintenance -> Forum Maintenance
     Then scroll down to the 'Empty the file cache' section and click 'Run task now'
     (see attached empty_file_cache.jpg)
     The clear the cache and cookies on your smartphone and try reloading the page
Title: Re: SMF4iPhone Mod
Post by: Leemy on July 01, 2010, 07:37:50 PM
ABMoto,

I had already set the option in #1 but had not emptied the cache. I have emptied the cache and it now auto-selects. Thanks!
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on July 01, 2010, 07:47:15 PM
there's a little bug which i'm gonna fix in the next release of the theme.
to fix it yourself you should open BoardIndex.template.php in SMF4iPhone Theme folder and search for:
if ($children) echo '

<div class="child buttons" id="childbuttondiv">

<button id="childboardbutton" onclick="childBoards();">Show ', $txt['parent_boards'], '</button>

</div>

';


then replace it with:
if ($children) echo '

<div class="child buttons" id="childbuttondiv">

<button id="childboardbutton" onclick="childBoards();">Show ', $txt['parent_boards'], '</button>

</div>

';

else echo '

<div class="child buttons" id="childbuttondiv"></div>

';


that should fix you matter
Title: Re: SMF4iPhone Mod
Post by: butchs on July 01, 2010, 10:02:06 PM
Ok I have to say this but shouldn't this stuff be with the theme not the mod?
Title: Re: SMF4iPhone Mod
Post by: ~DS~ on July 01, 2010, 10:25:19 PM
Quote from: butchs on July 01, 2010, 10:02:06 PM
Ok I have to say this but shouldn't this stuff be with the theme not the mod?
Are you quoting me? If so I dont know what you mean...
Title: Re: SMF4iPhone Mod
Post by: butchs on July 01, 2010, 10:27:29 PM
Quoting no one in particular but this is a mod thread.  I thought there was a thread for the theme?  I would assume it could get confusing to readers?
Title: Re: SMF4iPhone Mod
Post by: ~DS~ on July 01, 2010, 10:39:31 PM
Quote from: butchs on July 01, 2010, 10:27:29 PM
Quoting no one in particular but this is a mod thread.  I thought there was a thread for the theme?  I would assume it could get confusing to readers?
I am quite confusing as well...I will post it in the theme thread...
Title: Re: SMF4iPhone Mod
Post by: Sledgie on July 02, 2010, 05:41:41 PM
If you click the "Classic" button and go to the forum theme, how do you get back to the iPhone theme?
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on July 02, 2010, 08:15:14 PM
Quote from: Sledgie on July 02, 2010, 05:41:41 PM
If you click the "Classic" button and go to the forum theme, how do you get back to the iPhone theme?
in the readme it is explained how to add a link to your other themes to get back to iphone theme
Title: Re: SMF4iPhone Mod
Post by: steve51184 on July 12, 2010, 08:53:56 PM
is there a way to make the header and footer 'menu' always stay at the top/bottom of the screen?

something like this would be amazing:

http://fortysevenmedia.com/blog/archives/making_your_footer_stay_put_with_css/

can someone post an edited version of the theme maybe? :)
Title: Re: SMF4iPhone Mod
Post by: butchs on July 13, 2010, 08:20:30 AM
That is a theme (http://www.simplemachines.org/community/index.php?topic=376475.0) question.  You may want to ask it here (http://www.simplemachines.org/community/index.php?topic=376475.0).
Title: Re: SMF4iPhone Mod
Post by: steve51184 on July 13, 2010, 09:59:44 AM
ty :)
Title: Re: SMF4iPhone Mod
Post by: Churada on July 13, 2010, 07:18:32 PM
i'm getting the following error after installing this on RC3
QuoteParse error: syntax error, unexpected T_VARIABLE in /home2/chnlovei/public_html/Themes/default/languages/Modifications.english.php  on line 79

That just seems to be the start of this mod, I have attached the file (commented out for the moment so the forum loads).
I'd love to install this, not sure what's wrong.
Title: Re: SMF4iPhone Mod
Post by: butchs on July 13, 2010, 09:37:51 PM
That error has nothing to do with the mod.  It looks like someone manually edited the "Modifications.english.php" file.  You are missing a ;. Try changing $txt['Latest Posts'] = 'Latest Posts' to $txt['Latest Posts'] = 'Latest Posts';

Title: Re: SMF4iPhone Mod
Post by: Leemy on July 23, 2010, 12:28:13 PM
This mod is conflicting with the Pretty URLs (http://custom.simplemachines.org/mods/index.php?mod=636) mod (I dont think its a global issue).  Pretty URLs rewrites URLs to get the board name, topic name, etc.  But in SMF4iPhone, the bottom row of buttons like Home and Messages, do not point to the right URL anymore.


To see an example of this, you can visit my site using your iphone: http://bhangrateamsforum.com/discuss/index.php (http://bhangrateamsforum.com/discuss/index.php)


View a topic or post, then click "Home" at the bottom.  404 error as it adds an extra "index.php"

Title: Re: SMF4iPhone Mod
Post by: Fabius85 on July 23, 2010, 12:57:41 PM
Quote from: Leemy on July 23, 2010, 12:28:13 PM
This mod is conflicting with the Pretty URLs (http://custom.simplemachines.org/mods/index.php?mod=636) mod (I dont think its a global issue).  Pretty URLs rewrites URLs to get the board name, topic name, etc.  But in SMF4iPhone, the bottom row of buttons like Home and Messages, do not point to the right URL anymore.


To see an example of this, you can visit my site using your iphone: http://bhangrateamsforum.com/discuss/index.php (http://bhangrateamsforum.com/discuss/index.php)


View a topic or post, then click "Home" at the bottom.  404 error as it adds an extra "index.php"
first of all, this is not a Mod matter, this is a Theme matter.
by the way, yep, that mod replaces all the URLs. and the buttons of the bar at the bottom, as "Menu" link on upper-right side, has a "#" link (which means it anchors to same page), and use a javascript onClick. so you'd better ask PrettyURL developer to fix this URL replacement which should just not happen, i cannot do anything to fix this :-\
Title: Re: SMF4iPhone Mod
Post by: gamerzworld on July 27, 2010, 12:04:42 AM
I'm getting "SMF4iPhone Mod requires SMF caching to be turned on, goto Admin > Server Settings > Caching, to remove this error" errors in my error log. Since the mod seems to be working fine and on your mod page it only states that it supports the caching system, is this an error message you forgot to remove or is there something I'm missing?

EDIT: Missed the "Skip cache errors" option in the mod settings.
Title: Re: SMF4iPhone Mod
Post by: butchs on July 27, 2010, 07:19:19 AM
Then you are cool.   8)
Title: Re: SMF4iPhone Mod
Post by: Churada on July 30, 2010, 05:37:40 AM
Quote from: butchs on July 13, 2010, 09:37:51 PM
That error has nothing to do with the mod.  It looks like someone manually edited the "Modifications.english.php" file.  You are missing a ;. Try changing $txt['Latest Posts'] = 'Latest Posts' to $txt['Latest Posts'] = 'Latest Posts';

Thanks very much, that fixed the issue, I just realised i forgot to thank you.
Title: Re: SMF4iPhone Mod
Post by: kaamaru on July 30, 2010, 08:01:53 AM
If you have the recatcha mod enabled, the text is in italian. Look at the register.template.php. It looks like this:

if(!empty($modSettings['recaptcha_enabled']) && ($modSettings['recaptcha_enabled'] == 1 && !empty($modSettings['recaptcha_public_key']) && !empty($modSettings['recaptcha_private_key'])))
{
echo'
<div id="verification_control">
<script type="text/javascript">
var RecaptchaOptions = {
   theme : \'custom\',
   lang : \'it\',
   custom_theme_widget: \'recaptcha_widget\',
};
</script>
<div id="recaptcha_widget" style="display: none;">
<div id="recaptcha_image"></div>
<!--div class="recaptcha_only_if_incorrect_sol" style="color: red;">Sbagliato, riprova<br /><br /></div-->
<span class="recaptcha_only_if_image">Riscrivi le due parole:<br /><br /></span>
<!--span class="recaptcha_only_if_audio">Scrivi ciÚ che hai sentito:<br /><br /></span-->
<input id="recaptcha_response_field" name="recaptcha_response_field" type="text"><br /><br />
<a class="ottieni" href="javascript:Recaptcha.reload();">Ottieni un\'altro CAPTCHA</a>

<!--div class="recaptcha_only_if_image"><a href="javascript:Recaptcha.switch_type(\'audio\')">Ottieni un suono CAPTCHA</a></div><br />
<div class="recaptcha_only_if_audio"><a href="javascript:Recaptcha.switch_type(\'image\')">Ottieni un\'immagine CAPTCHA</a></div><br /><br />
<div><a href="javascript:Recaptcha.showhelp()">Help</a><br />
</div-->

<script type="text/javascript" src="http://api.recaptcha.net/challenge?k=6LcfswYAAAAAAFcljyRRV4vXfZuL-BHYqe6RT0un&lang=it"></script>

<noscript>
<iframe src="http://api.recaptcha.net/noscript?k=6LcfswYAAAAAAFcljyRRV4vXfZuL-BHYqe6RT0un&lang=it" height="200" width="500" frameborder="0"></iframe>
<textarea name="recaptcha_challenge_field" rows="3" cols="40"></textarea>
<input type="\'hidden\'" name="\'recaptcha_response_field\'" value="\'manual_challenge\'">
</noscript>

</div>';
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on July 30, 2010, 06:36:58 PM
yep, sorry, i made that for my website when i first worked on the theme and forgot to make that strings localizable, i'll fix that in next release :)
Title: Re: SMF4iPhone Mod
Post by: kaamaru on July 30, 2010, 06:59:54 PM
BTW it doesn't work anymore. It keeps saying it's incorrect, when it isn't.

Anyhow I see you got it working on your site. Good luck!
Title: Re: SMF4iPhone Mod
Post by: butchs on July 30, 2010, 09:30:37 PM
Poor mod takes the blame again.   :o
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on July 31, 2010, 03:43:11 AM
Quote from: Calumks on July 30, 2010, 06:59:54 PM
BTW it doesn't work anymore. It keeps saying it's incorrect, when it isn't.

Anyhow I see you got it working on your site. Good luck!
i forgot to update that part since RC3 was out (i didnt even remember it was there, that's why also it didnt get localized), so it probably stopped working. i will fix it :)
Title: Re: SMF4iPhone Mod
Post by: kaamaru on July 31, 2010, 03:47:54 PM
Thanks :)!
Title: Re: SMF4iPhone Mod
Post by: eng_HK on August 14, 2010, 08:19:51 AM
Hi all
I installaed the Mod and the theme,also done the task from the maintanance log, also the flag for selectable theme are enable, but still continuing to load only the default theme and not the 4iphone...

Any suggestions?
Title: Re: SMF4iPhone Mod
Post by: butchs on August 14, 2010, 08:49:51 AM
Try installing the theme first then the mod will recognize it for you.
Title: Re: SMF4iPhone Mod
Post by: Exochat on August 14, 2010, 10:48:07 AM
Excellent Mod.... no issues with it at all, took a couple of attempts to get it going but works fantastic on Android phone.

Problem the developer has with this sort of Mod is the fact that unless he owns every single piece of mobile kit, there are bound to be people that find bugs or issues that may be because of what they are using and nothing to do with the Mod in question. As such it will always be open to criticism but I want to congratulate him on an excellent development!
Title: Re: SMF4iPhone Mod
Post by: butchs on August 14, 2010, 11:25:51 AM
Thanks...  I did most of the code blind, with no mobile device, Fabius85 was my seeing eye dog and beta tester.   :)
Title: Re: SMF4iPhone Mod
Post by: eng_HK on August 14, 2010, 12:12:21 PM
@butch, did it but same result...
Title: Re: SMF4iPhone Mod
Post by: butchs on August 14, 2010, 12:20:07 PM
Check out reply 36. (http://www.simplemachines.org/community/index.php?topic=381400.msg2669765#msg2669765)
Title: Re: SMF4iPhone Mod
Post by: eng_HK on August 14, 2010, 12:33:08 PM
there must be something wrong..

Unistalled, reinstalled, clear cache, set the cache in the forum option, cleared cache on mobile and always loaded the theme id1, not the iphone ..
Title: Re: SMF4iPhone Mod
Post by: butchs on August 14, 2010, 12:58:34 PM
The mod uses cache, cookies and sessions.  Did you delete cookies? You can try it from another device with a different ip or wait 24 hours for it to clear.  Sorry.
Title: Re: SMF4iPhone Mod
Post by: eng_HK on August 14, 2010, 03:30:03 PM
it works perfectly if I point directly to the theme=XX but seams that the auto-switch doesn't works...
The string to use with Blackberry 9000 bold is  -->    blackberry9000

or better.. If I point to the theme=XX I can see everything very well and adapted to the screen.
If I point to the home and the system try to switch with browser I can see it very small...

Which value I have to use for  Enter the mobile failsafe:  theme=XX where XX is the sm4iphone??
as a Enter the default theme ID: I have to use 1 (the default) or the sm4iphone id??

What i can do? for the switching prblm? and for the values??
Title: Re: SMF4iPhone Mod
Post by: butchs on August 14, 2010, 07:22:06 PM
If you add "blackberry9000" to the phrases in the proper format with "|" between everything to the correct theme id for the theme you want.

Read the help, it will work.
Title: Re: SMF4iPhone Mod
Post by: eng_HK on August 15, 2010, 05:21:25 AM
@butch

I have at ID 2 this

iemobile|Opera Mobi|symbian|series60|series70|series80|series90|series 60|series 70|series 80|series 90|blackberry|blackberry05|palm|webos|blackberry9000

If I point to the theme=XX I can see everything very well and adapted to the screen.
If I point to the home and the system try to switch with browser I can see it very small...

Which value I have to use for  Enter the mobile failsafe:  theme=XX where XX is the sm4iphone??
as a Enter the default theme ID: I have to use 1 (the default) or the sm4iphone id??
Title: Re: SMF4iPhone Mod
Post by: butchs on August 15, 2010, 08:32:57 AM
The size may be a question for the theme.  I can not help you with that, since I do not have a mobile device.  You may want to post a screen shot on the theme help board?

The Mobile failsafe can be "wap", "wap2", "imode" or "theme=#" where # is the ID of the theme.  I like to use a generic theme for the fail safe like wap2  But you can pick any theme you like.
Title: Re: SMF4iPhone Mod
Post by: eng_HK on August 15, 2010, 01:56:08 PM
Seams that I'm not so luky.. it doesn't work... the autoswitch.

it work greate if I point from my blackberry or iphone directly to the smf4iphone theme
Title: Re: SMF4iPhone Mod
Post by: butchs on August 15, 2010, 04:27:14 PM
It has always worked.  Many people complain when they have the wrong UA.  Then they find the correct UA and it works.  You have a typo in your UA for your device.  You need to find a site that will show it to you when logged on and fix it.  Maybe Fab knows where?
Title: Re: SMF4iPhone Mod
Post by: Raffoz on September 01, 2010, 09:31:31 AM
i have a problem...
it happened some days ago when i tried to change something in the panel...

actually, if i connect with an iphone, it works...
then i click on "classic version"..
then if i click whatever in the site, it comes back to iphone version...

it looks how it doesn't get the cookie...

any idea?
thanks

i already tried to uninstall and reinstall...
Title: Re: SMF4iPhone Mod
Post by: butchs on September 01, 2010, 08:48:32 PM
You need to unlock and enable cookies in your browser.   O:)
Title: Re: SMF4iPhone Mod
Post by: b4pjoe on September 02, 2010, 11:24:08 PM
Is there anyway to detect the difference between the iPhone and the iPad? I have users that want to stick with the normal theme using the iPad. Right now it switches both the iPhone and iPad to the mobile theme.
Title: Re: SMF4iPhone Mod
Post by: Raffoz on September 03, 2010, 01:34:56 AM
Quote from: butchs on September 01, 2010, 08:48:32 PM
You need to unlock and enable cookies in your browser.   O:)


they are already unlocked...

every time I click some link from homepage, appears again the mobile version... :(
Title: Re: SMF4iPhone Mod
Post by: eng_HK on September 03, 2010, 01:54:19 AM
I found the prblm.

My Forum is called from a redirect address.
To be more clear the address is www.mydomain.it/Forum

But the forum is called by another url, a third level like,   http://hello.mydomain.it/ that redirect to www.mydomain.it/Forum
This is used for user because so i can separate the principal domain to the rest.

Seams that If I call the hello.mydomain.it I can see the sm4phone them but really really small and compressed,like if the mod is not installed. If I call the www.mydomain.it/Forum evrything works really fine...

It's possible to do something??
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on September 07, 2010, 03:21:30 AM
Quote from: joec88 on September 02, 2010, 11:24:08 PM
Is there anyway to detect the difference between the iPhone and the iPad? I have users that want to stick with the normal theme using the iPad. Right now it switches both the iPhone and iPad to the mobile theme.
try to access to this site with an iphone and with an ipad (i dont have it, so i cant help you  more than this):
http://whatsmyuseragent.com/

Quote from: Raffaele1977 on September 03, 2010, 01:34:56 AM
Quote from: butchs on September 01, 2010, 08:48:32 PM
You need to unlock and enable cookies in your browser.   O:)


they are already unlocked...

every time I click some link from homepage, appears again the mobile version... :(
try to clear your browser cache and cookies, your forum cache and access again to your forum

Quote from: eng_HK on September 03, 2010, 01:54:19 AM
I found the prblm.

My Forum is called from a redirect address.
To be more clear the address is www.mydomain.it/Forum

But the forum is called by another url, a third level like,   http://hello.mydomain.it/ that redirect to www.mydomain.it/Forum
This is used for user because so i can separate the principal domain to the rest.

Seams that If I call the hello.mydomain.it I can see the sm4phone them but really really small and compressed,like if the mod is not installed. If I call the www.mydomain.it/Forum evrything works really fine...

It's possible to do something??
can you please show us what do you mean with "really small and compressed" with a screenshot of it?
Title: Re: SMF4iPhone Mod
Post by: Raffoz on September 07, 2010, 03:26:57 AM
no, it doesn't work... :(
i already did it... sigh... :(
Title: Re: SMF4iPhone Mod
Post by: eng_HK on September 07, 2010, 03:11:01 PM
@fabius
see the 2 file attached.

The shrink is if I call the URL: http://hello.mydomain.it/
The OK is if I call the subfolder  www.mydomain.it/Forum

Seams that is something that do strange with the redirect

In the shrink you can note the scrollbar and the font that are really small and the zoom cursor.
In the OK  you'll see that no scroll bar and that the font are ok.

thx
Title: Re: SMF4iPhone Mod
Post by: b4pjoe on September 07, 2010, 06:13:49 PM
Quote from: Fabius85 on September 07, 2010, 03:21:30 AM
Quote from: joec88 on September 02, 2010, 11:24:08 PM
Is there anyway to detect the difference between the iPhone and the iPad? I have users that want to stick with the normal theme using the iPad. Right now it switches both the iPhone and iPad to the mobile theme.
try to access to this site with an iphone and with an ipad (i dont have it, so i cant help you  more than this):
http://whatsmyuseragent.com/

Yeah, I don't have either one of them either but my users do. And that brings me to something that may be related. If you install this mod on a new SMF install with no portal installed you get the "Classic" button on the front page of the forum. This would be OK because an iPad user could just click it to switch back to the full theme but on a site with the PortaMx portal installed the Classic button never shows. The mod does disable the portal for the iPhone theme but the link for the forum front page is http://www.mysite.com/index.php?action=forum instead of http://www.mysite.com/index.php like it is for a site without the portal installed. I've tried it on multiple installs and the Classic button never shows anywhere as long as PortaMx is installed even if you have the front page disabled in PortaMx. So how can I make the Classic button show?
Title: Re: SMF4iPhone Mod
Post by: eng_HK on September 16, 2010, 04:28:10 AM
@fabius
Have you looked my post???
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on September 16, 2010, 06:32:37 AM
Quote from: Raffaele1977 on September 07, 2010, 03:26:57 AM
no, it doesn't work... :(
i already did it... sigh... :(
In you iPhone, check in "Settings > Safari > Accept cookies" it is set "From visited". if not, set it, then clear cache and cookies of both iphone and forum, and see if it works

Quote from: eng_HK on September 07, 2010, 03:11:01 PM
@fabius
see the 2 file attached.

The shrink is if I call the URL: http://hello.mydomain.it/
The OK is if I call the subfolder  www.mydomain.it/Forum

Seams that is something that do strange with the redirect

In the shrink you can note the scrollbar and the font that are really small and the zoom cursor.
In the OK  you'll see that no scroll bar and that the font are ok.

thx
it seems like the iphone theme is viewed from a desktop browser, so... i dont know, maybe a header meta tag? it would be helpful if you give me the link to your forum so i can see the source code of the pages generated and compare the differences.

Quote from: joec88 on September 07, 2010, 06:13:49 PM
Quote from: Fabius85 on September 07, 2010, 03:21:30 AM
Quote from: joec88 on September 02, 2010, 11:24:08 PM
Is there anyway to detect the difference between the iPhone and the iPad? I have users that want to stick with the normal theme using the iPad. Right now it switches both the iPhone and iPad to the mobile theme.
try to access to this site with an iphone and with an ipad (i dont have it, so i cant help you  more than this):
http://whatsmyuseragent.com/

Yeah, I don't have either one of them either but my users do. And that brings me to something that may be related. If you install this mod on a new SMF install with no portal installed you get the "Classic" button on the front page of the forum. This would be OK because an iPad user could just click it to switch back to the full theme but on a site with the PortaMx portal installed the Classic button never shows. The mod does disable the portal for the iPhone theme but the link for the forum front page is http://www.mysite.com/index.php?action=forum instead of http://www.mysite.com/index.php like it is for a site without the portal installed. I've tried it on multiple installs and the Classic button never shows anywhere as long as PortaMx is installed even if you have the front page disabled in PortaMx. So how can I make the Classic button show?
you can add a link in the footer of the BoardIndex.template.php to switch to classic theme, this should appear even if you install the portal.
Title: Re: SMF4iPhone Mod
Post by: jiltedcitizen on September 18, 2010, 12:18:56 AM
Ok i have an issue.  I have installed the SimpleSEF url rewriter mod and this mod.  It works and on my phone will switch to the iphone theme.  And I can browse.  But if I try and login it says "too many redirects" or something along those lines.

Actually I tried the theme in my browser too and it said it was caught in a redirect loop, so might be theme.  Any idea's anyway?
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on September 19, 2010, 05:52:23 AM
Quote from: jiltedcitizen on September 18, 2010, 12:18:56 AM
Ok i have an issue.  I have installed the SimpleSEF url rewriter mod and this mod.  It works and on my phone will switch to the iphone theme.  And I can browse.  But if I try and login it says "too many redirects" or something along those lines.

Actually I tried the theme in my browser too and it said it was caught in a redirect loop, so might be theme.  Any idea's anyway?
try to uninstall the other mod and see if you still get the error. if not then it's surely an issue related to that mod, and its author could probably help you to fix the incompatibility.
Title: Re: SMF4iPhone Mod
Post by: Snape on September 28, 2010, 05:10:14 PM
Quote from: Fabius85 on September 16, 2010, 06:32:37 AM
Quote from: Raffaele1977 on September 07, 2010, 03:26:57 AM
no, it doesn't work... :(
i already did it... sigh... :(
In you iPhone, check in "Settings > Safari > Accept cookies" it is set "From visited". if not, set it, then clear cache and cookies of both iphone and forum, and see if it works

Not meaning to double-post, but since this is the actual mod thread (and I originally posted in the theme thread)- I am seeing the same problem on my 2.0RC3 forum.  Basically I have a small number of iphone users that actually prefer the full site experience and would like to disable the autodetect specifically for them (unless the classic option can stay set properly- then they're fine with the mod as is).
Title: Re: SMF4iPhone Mod
Post by: Lolafish on October 01, 2010, 04:28:02 PM
Hi guys,

I posted a question in the Theme, and now I'm second guessing myself and thinking it was prolly more of a mod-related problem.  IDK.  I can't find any other threads that talk about this:

http://www.simplemachines.org/community/index.php?topic=376475.msg2803813#msg2803813

As a forum administrator, I know it's frustrating to get double posts. I don't want to be a nuisance but I have some pretty furious members right now wanting their iphone mod back.   :-\

I guess I can go back and uninstall-reinstall stuff, just trying to find a point of reference first.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on October 05, 2010, 08:44:47 AM
Quote from: Snape on September 28, 2010, 05:10:14 PM
Quote from: Fabius85 on September 16, 2010, 06:32:37 AM
Quote from: Raffaele1977 on September 07, 2010, 03:26:57 AM
no, it doesn't work... :(
i already did it... sigh... :(
In you iPhone, check in "Settings > Safari > Accept cookies" it is set "From visited". if not, set it, then clear cache and cookies of both iphone and forum, and see if it works

Not meaning to double-post, but since this is the actual mod thread (and I originally posted in the theme thread)- I am seeing the same problem on my 2.0RC3 forum.  Basically I have a small number of iphone users that actually prefer the full site experience and would like to disable the autodetect specifically for them (unless the classic option can stay set properly- then they're fine with the mod as is).
i'm gonna add a "Disable SMF4iPhone autodetect" checkbox in users control panel in next release of the mod, so that, if enabled by the user, it will point directly to the default theme they choose instead of switching to the mobile theme :)
Title: Re: SMF4iPhone Mod
Post by: Lolafish on October 05, 2010, 03:46:46 PM
Quote from: Lolafish on October 01, 2010, 04:28:02 PM
I guess I can go back and uninstall-reinstall stuff, just trying to find a point of reference first.
I fixed it, BTW.  Working great again!
Title: Re: SMF4iPhone Mod
Post by: toothmkr57 on October 10, 2010, 01:36:14 AM
If i use this mod, and my 'Allow members to select their own themes.' in  Theme Management is turned off, However I have the theme permission mod applied and I allow for everyone to to use the smf4iphone theme, would that work? http://custom.simplemachines.org/mods/index.php?mod=1422
Thanks,
Paul R.
Title: Re: SMF4iPhone Mod
Post by: Akumetsu on October 13, 2010, 10:59:39 AM
Hi everybody, i've installed the theme and the mod, but when i try to acces the site with an iphone, the default theme remain instead changing to the mobile version. I've looked for the error log and i saw that :

SMF4iPhone Mod non e' stato in grado di connettersi a DetectFree (From italian, it means the mod cannot connect to DetectFree)
?action=admin;area=modsettings;sa=iphone


Some ideas to fix it ?


Ps: sorry for my bad english, i'm italian :P
Title: Re: SMF4iPhone Mod
Post by: butchs on October 13, 2010, 02:22:09 PM
That just means the detectfree server is down when it comes back your mod will start working.
Title: Re: SMF4iPhone Mod
Post by: b4pjoe on October 15, 2010, 12:09:29 PM
Using this theme and it seems everything is working except the "Classic" button. Clicking on it has no effect. I see the url it uses is:

domain.com/index.php?theme=2

where 2 is my default theme. If I am using a different theme and manually type that url in it works and changes the forum back to my default theme but it does not work if I'm using the smf4iphone theme. What does work using the smf4iphone theme is manually typing :

domain.com/index.php?theme=2;fullsite

So is there an easy way to make this theme use the latter URL instead of the shorter one that does not work?
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on October 17, 2010, 08:36:25 PM
Quote from: joec88 on October 15, 2010, 12:09:29 PM
Using this theme and it seems everything is working except the "Classic" button. Clicking on it has no effect. I see the url it uses is:

domain.com/index.php?theme=2

where 2 is my default theme. If I am using a different theme and manually type that url in it works and changes the forum back to my default theme but it does not work if I'm using the smf4iphone theme. What does work using the smf4iphone theme is manually typing :

domain.com/index.php?theme=2;fullsite

So is there an easy way to make this theme use the latter URL instead of the shorter one that does not work?
search for classic button link it in "BoardIndex.template.php"
Title: Re: SMF4iPhone Mod
Post by: marinesct on November 14, 2010, 12:18:16 PM
Is there going to be an RC4 compatible version?
Title: Re: SMF4iPhone Mod
Post by: booch_21 on November 15, 2010, 08:50:34 AM
As you can see, it works fine with RC4.  I installed it under RC3 emulation and have had no issues when my Android phone connects to it.

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi113.photobucket.com%2Falbums%2Fn211%2Fbooch_21%2FCAP201011150842-1-1.jpg&hash=194f9775d1b5029908510ed2586bb2072661459e)
Title: Re: SMF4iPhone Mod
Post by: marinesct on November 16, 2010, 09:12:54 AM
Hmm. After my upgrade from RC3 to RC4, it wouldn't install it because it didn't include the RC4 compatibility in the xml. Thanks for lettin me know it works, I'll adjust the xml and reinstall it.

Thanks.
Title: Re: SMF4iPhone Mod
Post by: Ramón Cutanda on November 17, 2010, 03:57:20 PM
Thanks for the mod :-)

Next you will find the spanish_es translation both in UTF-8 and ISO 8859-1 encodings:

    <file name="$languagedir/Modifications.spanish_es-utf8.php" error="skip">
        <operation>
            <search position="end" />
            <add><![CDATA[
// START SMF4iPhone-Mod
$txt['iphone_title'] = 'SMF4iPhone';
$txt['iphone_desc'] = 'Ajustes para SMF4iPhone';
$txt['id_theme1'] = 'Introduce la ID para el tema nº1:';
$txt['id_theme2'] = 'Introduce la ID para el tema nº2:';
$txt['id_theme3'] = 'Introduce la ID para el tema nº3:';
$txt['failsafe_link'] = 'Modo seguro para móviles:';
$txt['id_default_theme'] = 'ID del tema por defecto:';
$txt['iphone_cache_ignore'] = 'Saltar errores de caché';
$txt['phrase1'] = 'Frases para el tema nº1:';
$txt['phrase2'] = 'Frases para el tema nº2:';
$txt['phrase3'] = 'Frases para el tema nº3:';
$txt['notestring'] = 'NOTA: Las frases se deben introducir en el formato del "agente de usuario|agente del usuario", es decir, "safari|firefox". EL modo seguro para móviles puede ser "wap", "wap2", "imode" o "theme=#" dónde # es la ID del tema. El tema no cargará a no ser que tanto la ID como las frases contengan datos.';
// END SMF4iPhone-Mod
]]></add>
        </operation>
        </file>
    <file name="$languagedir/Errors.spanish_es-utf8.php" error="skip">
        <operation>
            <search position="end" />
            <add><![CDATA[
// START SMF4iPhone-Mod
$txt['iphcache'] = 'SMF4iPhone Mod requiere que el caché de SMF esté habilitado. Para solucionar este error ve a Admin > Ajustes del Servidor > Caché';
$txt['iphDNS'] = 'SMF4iPhone Mod no pudo conectar a detectfree';
// END SMF4iPhone-Mod
]]></add>
        </operation>
        </file>
    <file name="$languagedir/Modifications.spanish_es.php" error="skip">
        <operation>
            <search position="end" />
            <add><![CDATA[
// START SMF4iPhone-Mod
$txt['iphone_title'] = 'SMF4iPhone';
$txt['iphone_desc'] = 'Ajustes para SMF4iPhone';
$txt['id_theme1'] = 'Introduce la ID para el tema n&ordm;1:';
$txt['id_theme2'] = 'Introduce la ID para el tema n&ordm;2:';
$txt['id_theme3'] = 'Introduce la ID para el tema n&ordm;3:';
$txt['failsafe_link'] = 'Modo seguro para m&oacute;viles:';
$txt['id_default_theme'] = 'ID del tema por defecto:';
$txt['iphone_cache_ignore'] = 'Saltar errores de cach&eacute;';
$txt['phrase1'] = 'Frases para el tema n&ordm;1:';
$txt['phrase2'] = 'Frases para el tema n&ordm;2:';
$txt['phrase3'] = 'Frases para el tema n&ordm;3:';
$txt['notestring'] = 'NOTA: Las frases se deben introducir en el formato del "agente de usuario|agente del usuario", es decir, "safari|firefox". EL modo seguro para m&oacute;viles puede ser "wap", "wap2", "imode" o "theme=#" d&oacute;nde # es la ID del tema. El tema no cargar&aacute; a no ser que tanto la ID como las frases contengan datos.';
// END SMF4iPhone-Mod
]]></add>
        </operation>
        </file>
    <file name="$languagedir/Errors.spanish_es.php" error="skip">
        <operation>
            <search position="end" />
            <add><![CDATA[
// START SMF4iPhone-Mod
$txt['iphcache'] = 'SMF4iPhone Mod requiere que el cach&eacute; de SMF est&eacute; habilitado. Para solucionar este error ve a Admin > Ajustes del Servidor > Cach&eacute;';
$txt['iphDNS'] = 'SMF4iPhone Mod no pudo conectar a detectfree';
// END SMF4iPhone-Mod
]]></add>
        </operation>
        </file>


Regards,
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on November 17, 2010, 07:05:18 PM
yep, i'm going to release an RC4 compatible version as soon as possible :)
Title: Re: SMF4iPhone Mod
Post by: bros on November 20, 2010, 12:20:46 AM
hey, I have a member on a Windows Phone 7 Phone, I was wondering how to get this mod working for his phone.

"Mozilla/4.0 (compatible; MSIE 7.0; Windows Phone OS 7.0; Trident/3.1; IEMobile/7.0; SAMSUNG; SGH-i917)"
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on November 20, 2010, 07:37:32 PM
Quote from: bros on November 20, 2010, 12:20:46 AM
hey, I have a member on a Windows Phone 7 Phone, I was wondering how to get this mod working for his phone.

"Mozilla/4.0 (compatible; MSIE 7.0; Windows Phone OS 7.0; Trident/3.1; IEMobile/7.0; SAMSUNG; SGH-i917)"
you should try to catch "iemobile|samsung"
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on November 20, 2010, 07:38:43 PM
works on new version of SMF4iPhone theme are done. works on the mod are about 50%. i think i'll release theme in few days. stay tuned ;)
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on November 25, 2010, 07:19:21 PM
New version of the mod is available now!

Download SMF4iPhone Mod (http://custom.simplemachines.org/mods/index.php?mod=2408)

CHANGELOG
v1.1   (26/11/2010)

* SMF 2.0 RC4 compatibility.
* Added checkbox to disable mobile theme automatic switch for every user in: Profile > Look and Layout
* Added theme names to the selection boxes in Mod's settings. Now they will appear like "(ID) Theme Name" so you dont need anymore to serach for theme ID by yourself.
* Added new languages: French, German and German-UTF8 (Thanks to Chili), Spanish_ES and Spanish_ES-UTF8 (Thanks to videoed), Swedish and Swedish-UTF8 (Thanks to Richard Roe).
* Fixed UTF-8 chars not converted to their respective HTML entity in some language files.
* Updated all language translations.
* Better alignment of "additional notes" at the end of SMF4iPhone Mod settings page.
* Some improvements to the code.

See also SMF4iPhone Theme (http://custom.simplemachines.org/themes/index.php?lemma=2089)
Title: Re: SMF4iPhone Mod
Post by: eyo on November 26, 2010, 02:31:35 AM
what do i do with the .php file? i installed the mod but dont know what to do withthat small .php file dl
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on November 26, 2010, 05:33:15 AM
Quote from: ggman on November 26, 2010, 02:31:35 AM
what do i do with the .php file? i installed the mod but dont know what to do withthat small .php file dl
if you installed the mod, the you're done. just configure it in:
Admin > Configuration > Modification Settings > SMF4iPhone

no need to do anything else with the php files...
Title: Re: SMF4iPhone Mod
Post by: PLAYBOY on November 29, 2010, 08:09:02 PM
Is there a way to make this mod for 1.1.12?
Please?
Also does it work with mytouch and other high-tech cellphones as explained? or does it work only on iphones?
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on November 30, 2010, 09:19:34 AM
Quote from: PLAYBOY on November 29, 2010, 08:09:02 PM
Is there a way to make this mod for 1.1.12?
Please?
Also does it work with mytouch and other high-tech cellphones as explained? or does it work only on iphones?
making this mod for 1.1.12 means to completely rewrite it, to fit it's way of working.
moreover i think that 2.0 final version is near to come so it would be quite a waste of time.

btw this mod works with every device, you just need to input the proper user agent (if not yet pre-set)
Title: Re: SMF4iPhone Mod
Post by: PLAYBOY on December 02, 2010, 08:35:31 AM
Well I just wish somebody at least would write it for 1.1.12
Because there are still SO MANY PEOPLE using 1.1.x
Title: Re: SMF4iPhone Mod
Post by: butchs on December 02, 2010, 08:01:13 PM
Donations talk.  But 1.1.x will take some effort...

Title: Re: SMF4iPhone Mod
Post by: PLAYBOY on December 03, 2010, 11:56:55 PM
I am just a moral Playboy. I have no money...
But i have a good heart...

ok i didnt believe that one either :D
Title: Re: SMF4iPhone Mod
Post by: akbora on December 04, 2010, 05:51:13 AM
Can I I launch admin pages with theme?
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on December 05, 2010, 06:17:04 AM
Quote from: akbora on December 04, 2010, 05:51:13 AM
Can I I launch admin pages with theme?
you can, but pages are completely messed up, cause theme doesnt include the admin part
Title: Re: SMF4iPhone Mod
Post by: neilbombd on December 10, 2010, 04:49:03 AM
Just installed the new version of the iphone skin for rc4, then reinstalled this mod, but I get an error now on installation:

It wants me to find:
<li>
<label for="display_quick_mod">', $txt['display_quick_mod'], '</label>
<select name="default_options[display_quick_mod]" id="display_quick_mod">
<option value="0"', empty($context['member']['options']['display_quick_mod']) ? ' selected="selected"' : '', '>', $txt['display_quick_mod_none'], '</option>
<option value="1"', !empty($context['member']['options']['display_quick_mod']) && $context['member']['options']['display_quick_mod'] == 1 ? ' selected="selected"' : '', '>', $txt['display_quick_mod_check'], '</option>
<option value="2"', !empty($context['member']['options']['display_quick_mod']) && $context['member']['options']['display_quick_mod'] != 1 ? ' selected="selected"' : '', '>', $txt['display_quick_mod_image'], '</option>
</select>
</li>


and add below:

<hr />
<li>
<input type="hidden" name="default_options[disable_mobile_switch]" value="0" />
<label for="disable_mobile_switch"><input type="checkbox" name="default_options[disable_mobile_switch]" id="disable_mobile_switch" value="1"', !empty($context['member']['options']['disable_mobile_switch']) ? ' checked="checked"' : '', ' class="input_check" /> ', $txt['dms_desc_inside'], '</label>
</li>


But I can't find that in the iphone skin's Profile.template.php file at all.  Nor can I find anything relating to the string "quick_mod"
Title: Re: SMF4iPhone Mod
Post by: cAPSLOCK on December 11, 2010, 04:30:24 PM
I am having this same problem as above.  On installation it fails saying:

Execute Modification    ./Themes/smf4iphone_theme_v1/Profile.template.php    Test failed

Then as Neil says I cannot find anywhere in the Profile.template.php to manually fix it.

*Edit* Experimented with just addinfg the code to the end after the other <li></li> items...  nothing
Title: Re: SMF4iPhone Mod
Post by: butchs on December 12, 2010, 07:48:31 AM
Looks like you have a mod conflict.  Uninstall your other mods and reinstall this mod.
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on December 18, 2010, 05:48:25 AM
Quote from: cAPSLOCK on December 11, 2010, 04:30:24 PM
I am having this same problem as above.  On installation it fails saying:

Execute Modification    ./Themes/smf4iphone_theme_v1/Profile.template.php    Test failed

Then as Neil says I cannot find anywhere in the Profile.template.php to manually fix it.

*Edit* Experimented with just addinfg the code to the end after the other <li></li> items...  nothing
this modification is not to be applied on EVERY theme, but just to SMF default theme (infact the checkbox for other themes is optional)
Title: Re: SMF4iPhone Mod
Post by: PLAYBOY on December 18, 2010, 06:35:39 AM
I am not sure if it would make any sense but here is what i did...

I copy and pasted this code:

<head>
        <script
                        src="http://detectfree.moviladetection.com/detectfree.js"
                        language="javascript"
                        type="text/javascript">
        </script>
</head>

<script language="javascript" type="text/javascript">
<!--//--><![CDATA[//><!--

// test
document.write("is_mobile:" + (is_mobile ? "true" : "false"));

//--><!]]>
</script>


into an html file and added "require once" in the index.template.php
So this script runs everypage and my members said forum looks a lot easier to browse and better looking.


I got the code from same place where the author got the code from. You can give it a try. Lemme know if you need more detailed explanations. I ll be glad to help anybody.
Title: Re: SMF4iPhone Mod
Post by: ffingers on December 31, 2010, 03:03:09 AM
quick question...i have tiny portal installed and it completely screws up the theme on the mobile device. I understand there is a check in the theme i believe to ignore the portal....any thoughts?
Title: Re: SMF4iPhone Mod
Post by: MATTEK on January 05, 2011, 12:44:40 PM
Question

Am I to understand that I will have to install this mod and then a theme that will default when it detects I'm using an Iphone?
Title: Re: SMF4iPhone Mod
Post by: ffingers on January 05, 2011, 05:05:20 PM
Quote from: MATTEK on January 05, 2011, 12:44:40 PM
Question

Am I to understand that I will have to install this mod and then a theme that will default when it detects I'm using an Iphone?

yep...there is an smf4iphone theme that you can install that this was essentially designed for....

On a side note...i just got mine up and running perfectly with it being customized a bit for graphics, colors, etc....if anyone wants to check it out on the iphone....my website is http://cbrjunkie.com/index.php?action=iphone

cheers to the mod and the theme author...EXCELLENT work!
Title: Re: SMF4iPhone Mod
Post by: akbora on January 09, 2011, 02:02:22 PM
There are over the thousand of thousand errors:

........
SMF4iPhone Mod failed to connect to DetectFree

What's that and what can I do?
Title: Re: SMF4iPhone Mod
Post by: impreza on January 09, 2011, 03:14:55 PM
A useful modification, thank you
Title: Re: SMF4iPhone Mod
Post by: Leemy on January 09, 2011, 05:40:36 PM
Quote from: akbora on January 09, 2011, 02:02:22 PM
There are over the thousand of thousand errors:

........
SMF4iPhone Mod failed to connect to DetectFree

What's that and what can I do?

I installed the mod yesterday and have this problem too. RC4 and latest version

SMF4iPhone Mod failed to connect to DetectFree
Title: Re: SMF4iPhone Mod
Post by: butchs on January 09, 2011, 08:27:36 PM
Looks like DetectFree is down.  May be so until later Monday?
Title: Re: SMF4iPhone Mod
Post by: NanoSector on January 10, 2011, 01:58:03 PM
Can I get the code for disabling Dream Portal?

Tried changing the link for the "home" button to ?index.php?action=forum, but no luck on that.
Title: Re: SMF4iPhone Mod
Post by: butchs on January 10, 2011, 08:42:33 PM
eh?  Wrong thread?
Title: Re: SMF4iPhone Mod
Post by: Paracelsus on January 11, 2011, 06:06:48 AM
Quote from: PLAYBOY on December 02, 2010, 08:35:31 AM
Well I just wish somebody at least would write it for 1.1.12
Because there are still SO MANY PEOPLE using 1.1.x

Second that.
Title: Re: SMF4iPhone Mod
Post by: Bagheera on January 11, 2011, 08:40:41 AM
Hello  :)

Is the DetectFree service still down?

Error: SMF4iPhone Mod failed to connect to DetectFree

Btw: love the mod  ;D thanks
Title: Re: SMF4iPhone Mod
Post by: NanoSector on January 11, 2011, 09:55:42 AM
Quote from: butchs on January 10, 2011, 08:42:33 PM
eh?  Wrong thread?
No not really...

I mean so the theme would disable DP since the portal is messed up in the theme.
Title: Re: SMF4iPhone Mod
Post by: ffingers on January 11, 2011, 04:43:24 PM
anyone have any ideas about detectfree?
Title: Re: SMF4iPhone Mod
Post by: radioz on January 12, 2011, 01:31:11 AM
When I download the latest version of this mod (smf4iphone_theme_v1.1.zip) for my  V2 RC4 forum, I get this return when I attempt to upload the zip package:

QuoteAn Error Has Occurred! Package upload failed due to the following error:

"Although the package was downloaded to the server it appears to be empty. Please check the Packages directory, and the "temp" sub-directory are both writable. If you continue to experience this problem you should try extracting the package on your PC and uploading the extracted files into a subdirectory in your Packages directory and try again. For example, if the package was called shout.tar.gz you should:
1) Download the package to your local PC and extract it into files.
2) Using an FTP client create a new directory in your "Packages" folder, in this example you may call it "shout".
3) Upload all the files from the extracted package to this directory.
4) Go back to the package manager browse page and the package will be automatically found by SMF."

I tried the process multiple times with no success.

FYI and thanks!  I would probably like to upload this package later.
Title: Re: SMF4iPhone Mod
Post by: NanoSector on January 12, 2011, 07:32:49 AM
Try extracting it on your computer.
Title: Re: SMF4iPhone Mod
Post by: giz on January 12, 2011, 11:50:55 AM
hi, i've uploaded both this app and the iphone mod.
i cannot find anywhere in this topic what the settings are supposed to be but theme 1 is mentioned a lot but i think what is needed is a good set of instructions.
i have allowed members to choose their own theme, cleared the cache in both my forum,phone and for the sake of it my laptop.
i have 2 themes installed on my forum, core which is the default theme and smf4iphone.
admin-modification settings-smf4iphone i have the following:
select the theme#1 - (33) smf4iphone
select the theme#2 - (33) smf4iphone
select the theme#3 - (33) smf4iphone
Enter the mobile failsafe: wap
skip cache errors:  tick

i can choose the iphone theme in my profile using both laptop and mobile and it switches fine but that is not what this mod is supposed to do, how do i make it switch auto?
Title: Re: SMF4iPhone Mod
Post by: Bagheera on January 12, 2011, 06:09:45 PM
Apparently the DetectFree is down  ??? for last 4 days  :o

I am giving it until tomorrow and im looking for something else. This is crazy. 
Title: Re: SMF4iPhone Mod
Post by: bros on January 12, 2011, 09:40:15 PM
I concur with renegades
Title: Re: SMF4iPhone Mod
Post by: Bagheera on January 15, 2011, 08:49:53 AM
I uninstall the mod because it doesn't work, and add small code for redirect in the index.template.php of my default template right after the <head>,; tag.

echo '

<script type="text/javascript">
if(screen.width < 500){
window.location = "http://domainname.com/index.php?theme=3";
}
</script>';


Replace the number with number of your mobile theme.

This is just for one mobile template but that's all I need. Hope that will help someone.  ;)
Title: Re: SMF4iPhone Mod
Post by: angelgb81 on January 16, 2011, 11:59:22 AM
Renegades solution works for me. Thanks.
Title: Re: SMF4iPhone Mod
Post by: Boricua012 on January 18, 2011, 06:07:14 AM
I've installed the mod and it's been active for about two days. I just checked my error log and I've noticed this error shows up frequently.

SMF4iPhone Mod failed to connect to DetectFree

Is this normal or this something i should worry about?
Title: Re: SMF4iPhone Mod
Post by: Bagheera on January 18, 2011, 09:58:38 PM
read the posts above you ;) it was explained
Title: Re: SMF4iPhone Mod
Post by: butchs on January 19, 2011, 07:26:45 PM
Hopefully fab can look at what is going on and make adjustments to the detectfree connection?

Title: Re: SMF4iPhone Mod
Post by: taysan on January 28, 2011, 10:18:18 AM
Still seems to be failing - uninstalling (just reinstalled with fresh download of theme and mod).
Title: Re: SMF4iPhone Mod
Post by: Fabius85 on January 29, 2011, 01:19:15 PM
i was quite busy in this perdiod, but i'm gonna take a look at all your suggestions and bug reports and fix them all :)
Title: Re: SMF4iPhone Mod
Post by: DEEPSNUYB on January 30, 2011, 01:58:16 AM
Quote from: farfromperfection on May 17, 2010, 10:55:33 PM
Hi, I know I've not been around for a while, and while I appreciate your editing of my theme I'm not too comfortable with the donation buttons there.

quit your crying, if you're not going to support it anymore then let these guys do it.  sheesh.
Title: Re: SMF4iPhone Mod
Post by: eng_HK on January 30, 2011, 09:37:02 AM
seams that detectfree is not working...

Apply Filter: Only show the errors with the same message
SMF4iPhone Mod non è stato in grado di connettersi a DetectFree
Title: Re: SMF4iPhone Mod
Post by: DEEPSNUYB on January 30, 2011, 03:54:42 PM
I believe it is because if you go to it with your mobile phone it will convert over to their mobile site.
Title: Re: SMF4iPhone Mod
Post by: eng_HK on January 31, 2011, 02:13:25 AM
No, It's the log from my SMF forum.
I tried to reach my address with the mobile and I received that error inside the forum
Title: Re: SMF4iPhone Mod
Post by: NanoSector on January 31, 2011, 11:40:32 AM
Quote from: DeepSnuybing on January 30, 2011, 01:58:16 AM
Quote from: farfromperfection on May 17, 2010, 10:55:33 PM
Hi, I know I've not been around for a while, and while I appreciate your editing of my theme I'm not too comfortable with the donation buttons there.

quit your crying, if you're not going to support it anymore then let these guys do it.  sheesh.
Quit your ******ing. farfromperfection started this theme and he has his own opinion on what is being done with it.

PS That post is months old, from mid-2010.
Title: Re: SMF4iPhone Mod
Post by: DEEPSNUYB on January 31, 2011, 11:41:20 PM
Quote from: Simple Series team on January 31, 2011, 11:40:32 AM
Quote from: DeepSnuybing on January 30, 2011, 01:58:16 AM
Quote from: farfromperfection on May 17, 2010, 10:55:33 PM
Hi, I know I've not been around for a while, and while I appreciate your editing of my theme I'm not too comfortable with the donation buttons there.

No you can go f' yourself.
quit your crying, if you're not going to support it anymore then let these guys do it.  sheesh.
Quit your ******ing. farfromperfection started this theme and he has his own opinion on what is being done with it.

PS That post is months old, from mid-2010.
Title: Re: SMF4iPhone Mod
Post by: NanoSector on February 01, 2011, 10:25:44 AM
Quote from: DeepSnuybing on January 31, 2011, 11:41:20 PM
Quote from: Simple Series team on January 31, 2011, 11:40:32 AM
Quote from: DeepSnuybing on January 30, 2011, 01:58:16 AM
Quote from: farfromperfection on May 17, 2010, 10:55:33 PM
Hi, I know I've not been around for a while, and while I appreciate your editing of my theme I'm not too comfortable with the donation buttons there.

No you can go f' yourself.
quit your crying, if you're not going to support it anymore then let these guys do it.  sheesh.
Quit your ******ing. farfromperfection started this theme and he has his own opinion on what is being done with it.

PS That post is months old, from mid-2010.
So what are you trying to say?
Title: Re: SMF4iPhone Mod
Post by: DEEPSNUYB on February 04, 2011, 08:53:34 PM
The autoswitching still no workie
Title: Re: SMF4iPhone Mod
Post by: NanoSector on February 05, 2011, 04:59:53 AM
Quote from: DeepSnuybing on February 04, 2011, 08:53:34 PM
The autoswitching still no workie
Don't expect us to support you in both threads.
It's in one of them or in neither.
Title: Re: SMF4iPhone Mod
Post by: DEEPSNUYB on February 05, 2011, 05:10:47 AM
Quote from: Simple Series team on February 05, 2011, 04:59:53 AM
Quote from: DeepSnuybing on February 04, 2011, 08:53:34 PM
The autoswitching still no workie
Don't expect us to support you in both threads.
It's in one of them or in neither.

YOU DON'T HAVE TO DO JACK AND I DON'T EXPECT JACK FROM YOU.  IT'S POSTED IN BOTH THREADS BECAUSE THE ISSUE COULD BE THE THEME ITSELF OR THE MOD ITSELF. HENCE THE AUTHOR INITIALLY POSTING TWO DIFFERENT THREADS FOR US TO ASK SUPPORT IN.
Title: Re: SMF4iPhone Mod
Post by: NanoSector on February 05, 2011, 05:14:05 AM
Quote from: DeepSnuybing on February 05, 2011, 05:10:47 AM
Quote from: Simple Series team on February 05, 2011, 04:59:53 AM
Quote from: DeepSnuybing on February 04, 2011, 08:53:34 PM
The autoswitching still no workie
Don't expect us to support you in both threads.
It's in one of them or in neither.

YOU DON'T HAVE TO DO JACK AND I DON'T EXPECT JACK FROM YOU.  IT'S POSTED IN BOTH THREADS BECAUSE THE ISSUE COULD BE THE THEME ITSELF OR THE MOD ITSELF. HENCE THE AUTHOR INITIALLY POSTING TWO DIFFERENT THREADS FOR US TO ASK SUPPORT IN.
Calm, man.

You get support for both mod and theme in both threads. Hence you should not double-post your question, since then support may get harder for you.

The author has two topics since the mod is posted in the modifications section, and the theme is posted in the theme section.
Both are included in both pages.
Title: Re: SMF4iPhone Mod
Post by: DEEPSNUYB on February 05, 2011, 05:25:10 AM
Quote from: Simple Series team on February 05, 2011, 05:14:05 AM
Quote from: DeepSnuybing on February 05, 2011, 05:10:47 AM
Quote from: Simple Series team on February 05, 2011, 04:59:53 AM
Quote from: DeepSnuybing on February 04, 2011, 08:53:34 PM
The autoswitching still no workie
Don't expect us to support you in both threads.
It's in one of them or in neither.

YOU DON'T HAVE TO DO JACK AND I DON'T EXPECT JACK FROM YOU.  IT'S POSTED IN BOTH THREADS BECAUSE THE ISSUE COULD BE THE THEME ITSELF OR THE MOD ITSELF. HENCE THE AUTHOR INITIALLY POSTING TWO DIFFERENT THREADS FOR US TO ASK SUPPORT IN.
Calm, man.

You get support for both mod and theme in both threads. Hence you should not double-post your question, since then support may get harder for you.

The author has two topics since the mod is posted in the modifications section, and the theme is posted in the theme section.
Both are included in both pages.

It's posted in both threads for the reason I stated. If you cannot help then keep your pie hole shut.
Title: Re: SMF4iPhone Mod
Post by: NanoSector on February 05, 2011, 05:26:39 AM
Quote from: DeepSnuybing on February 05, 2011, 05:25:10 AM
Quote from: Simple Series team on February 05, 2011, 05:14:05 AM
Quote from: DeepSnuybing on February 05, 2011, 05:10:47 AM
Quote from: Simple Series team on February 05, 2011, 04:59:53 AM
Quote from: DeepSnuybing on February 04, 2011, 08:53:34 PM
The autoswitching still no workie
Don't expect us to support you in both threads.
It's in one of them or in neither.

YOU DON'T HAVE TO DO JACK AND I DON'T EXPECT JACK FROM YOU.  IT'S POSTED IN BOTH THREADS BECAUSE THE ISSUE COULD BE THE THEME ITSELF OR THE MOD ITSELF. HENCE THE AUTHOR INITIALLY POSTING TWO DIFFERENT THREADS FOR US TO ASK SUPPORT IN.
Calm, man.

You get support for both mod and theme in both threads. Hence you should not double-post your question, since then support may get harder for you.

The author has two topics since the mod is posted in the modifications section, and the theme is posted in the theme section.
Both are included in both pages.

It's posted in both threads for the reason I stated. If you cannot help then keep your pie hole shut.
You don't seem to read my post. Re-read it and come with a valid statement.
Title: Re: SMF4iPhone Mod
Post by: DEEPSNUYB on February 05, 2011, 05:30:51 AM
I'll say it again. SHUT YOUR MOUTH IF YOU CANNOT HELP. :)
Title: Re: SMF4iPhone Mod
Post by: sviridovt on February 06, 2011, 03:36:47 PM
guys, please help I use rc4 and my mod doesnt work. I setup everything correctly, there are no errors, and the theme is installed and theme works. its just the auto switch that doesn't work. I setup the ability to switch themes and made sure smf4iphone is set, yet it still doesnt work
Title: Re: SMF4iPhone Mod
Post by: b4pjoe on February 06, 2011, 09:30:25 PM
The detectfree server has not been working for some time.
Title: Re: SMF4iPhone Mod
Post by: sviridovt on February 06, 2011, 10:36:28 PM
Quote from: joec88 on February 06, 2011, 09:30:25 PM
The detectfree server has not been working for some time.

so do I just wait?
Title: Re: SMF4iPhone Mod
Post by: b4pjoe on February 07, 2011, 01:07:33 AM
Quote from: sviridovt on February 06, 2011, 10:36:28 PM
so do I just wait?

The DetectFree server is not controlled by the mod author so there isn't anything they can do.

There was a script someone made a page or two back that makes it switch to the mobile theme based up the resolution of the device you are using. I haven't tried it but I think there were people that said it worked for them.
Title: Re: SMF4iPhone Mod
Post by: Caltan on February 08, 2011, 10:42:46 AM
Quote from: joec88 on February 07, 2011, 01:07:33 AMThere was a script someone made a page or two back that makes it switch to the mobile theme based up the resolution of the device you are using. I haven't tried it but I think there were people that said it worked for them.

Yep, just make sure the script is in the index.template.php for whatever theme you have set for default and it works fine.  If you're a compulsive error log checker, though, you may want to also uninstall the mod, since the DetectFree failure throws up an error entry every time.
Title: Re: SMF4iPhone Mod
Post by: Cerebus06 on February 11, 2011, 09:56:33 AM
Actually, I installed the script by RenegadesForum in lieu of the mod as shown, but when I navigate to the page using my iPhone, the page just gets stuck in an endless loop and never resolves.  I haven't been able to get the script to work at all so far as a result.

I've tested the iPhone theme itself, and it functions fine.
Title: Re: SMF4iPhone Mod
Post by: dugbug on February 12, 2011, 09:12:22 AM
So how do you install a mod?  I assume its a "package" and tried to use the admin browse package feature, but it requires I select an individual file... so do I choose install.xml or something?

I tried copying the mod contents to the packages folder, so now the admin browse packages shows it but its not installed, nor is there an option to click on install.  How does one activate it?

thanks for any help
Title: Re: SMF4iPhone Mod
Post by: dugbug on February 12, 2011, 09:43:56 AM
Ok nevermind... I have RC5 and it checks a compatibility list prior to offering an install button.  For experimentation, I added RC5 to the list and it let me attempt to install it, however the installation complains that a mod must be made to the SMF4iPhone theme.

In particular, Profile.template.php.  It wants to find some code and then append a few lines.  The problem is the code it is attempting to locate does not exist in the file.

I have the latest versions of both the mod and theme.

any ideas?
Title: Re: SMF4iPhone Mod
Post by: DEEPSNUYB on February 13, 2011, 04:32:52 AM
This where you should manually edit your files. Its good practice amyways instead of using the package manager.

The mod doesn't works anyways with RC4.
Title: Re: SMF4iPhone Mod
Post by: z_dane on February 22, 2011, 06:42:36 PM
i also using RC5. before this no problem with RC4.
i get error log state "SMF4iPhone Mod failed to connect to DetectFree"

any idea?
Title: Re: SMF4iPhone Mod
Post by: Commander Keen on February 24, 2011, 10:09:55 AM
I'm using RC4 with this Mod. The Theme itself works but I also get the error telling me that there's no connection to DetectFree.
At least I now know why it's not working ;-).
But why is there no connection?
Title: Re: SMF4iPhone Mod
Post by: butchs on February 24, 2011, 08:14:49 PM
Fabius85 is working hard trying to find out what changes detect free made that are preventing the mod from working.
Title: Re: SMF4iPhone Mod
Post by: mkress on February 27, 2011, 08:18:17 AM
it's unnecessary to request a webservice for every user

I have downloaded following file and added to Sources-dir:
http://detectmobilebrowsers.mobi/

Then I replaced this in DetectFree.php:

//No data in SMF cache about this IP or session and no cookie. Time to check the Detectfree db
        $headers = "";
        if (function_exists("getAllHeaders")) {
                foreach (getAllHeaders() as $key => $value) {
                        $key_lower = strtolower($key);
                        if ($key_lower == "connection") continue;
                        if ($key_lower == "content-length") continue;
                        if ($key_lower == "content-type") continue;
                        if ($key_lower == "host") continue;
                        if ($key_lower == "keep-alive") continue;
                        $headers .= "$key: $value\r\n";
                }
        } else {
                foreach ($_SERVER as $key => $value) {
                        if (substr($key, 0, 5) == "HTTP_") {
                                $key = str_replace("_", " ", substr($key, 5));
                                $key = str_replace(" ", "-", ucwords(strtolower($key)));
                                $key_lower = strtolower($key);
                                if ($key_lower == "connection") continue;
                                if ($key_lower == "content-length") continue;
                                if ($key_lower == "content-type") continue;
                                if ($key_lower == "host") continue;
                                if ($key_lower == "keep-alive") continue;
                                $headers .= "$key: $value\r\n";
                        }
                }
        }
       
        $url = "http://detectfree.moviladetection.com/";
$contents  = iphone_fetch_web_data($url, $headers);

$is_mobile = "undef";

if (!$contents) {
loadLanguage('Errors');
log_error($txt['iphDNS'], 'user'); // could not connect
        } else {
                $lines = explode("\r?\n", $contents);
               
                foreach ($lines as $line) {
                        $pos = strpos($line, ":");
                        if ($pos && strlen($line) > $pos + 1) {
                                $key = substr($line, 0, $pos);
                                $value = substr($line, $pos + 1);
                                if ($key == "is_mobile")
                                        $is_mobile = $value;
                        }
                }
        }

if ($is_mobile != "true")
$detectfree_check = "false"; // iphone_lookup
else
$detectfree_check = "true"; // iphone_lookup



with this:

require_once($sourcedir . '/mobile_device_detect.php');
$mobileCheck = mobile_device_detect(true,true,true,true,true,true,true,false,false);
$detectfree_check = $mobileCheck[0];


so the function iphone_fetch_web_data is unnecessary and no external request is needed
Title: Re: SMF4iPhone Mod
Post by: b4pjoe on February 27, 2011, 11:07:30 AM
Quote from: fca07 on February 27, 2011, 08:18:17 AM
it's unnecessary to request a webservice for every user

I have downloaded following file and added to Sources-dir:
http://detectmobilebrowsers.mobi/

Then I replaced this in DetectFree.php:

<clip>

so the function iphone_fetch_web_data is unnecessary and no external request is needed

Can you tell me what this does to iPad users? Is it detected as a mobile browser because my iPad users do not want to be switched to the mobile theme.

Nevermind. I see at that site that:

QuoteThe function has eight parameters that can be passed to it which define the way it handles different scenarios. These paramaters are:

    * iPhone - Set to true to treat iPhones as mobiles, false to treat them like full browsers or set a URL (including http://) to redirect iPhones and iPods to.
    * iPad - Set to true to treat iPads as mobiles, false to treat them like full browsers or set a URL (including http://) to redirect iPads to.
    * Android - Set to true to treat Android handsets as mobiles, false to treat them like full browsers or set a URL (including http://) to redirect Android and Google mobile users to.
    * Opera Mini - Set to true to treat Opera Mini like a mobile, false to treat it like full browser or set a URL (including http://) to redirect Opera Mini users to.
    * Blackberry - Set to true to treat Blackberry like a mobile, false to treat it like full browser or set a URL (including http://) to redirect Blackberry users to.
    * Palm - Set to true to treat Palm OS like a mobile, false to treat it like full browser or set a URL (including http://) to redirect Palm OS users to.
    * Windows - Set to true to treat Windows Mobiles like a mobile, false to treat it like full browser or set a URL (including http://) to redirect Windows Mobile users to.
    * Mobile Redirect URL - This should be full web address (including http://) of the site (or page) you want to send mobile visitors to. Leaving this blank will make the script return true when it detects a mobile.
    * Desktop Redirect URL - This should be full web address (including http://) of the site (or page) you want to send non-mobile visitors to. Leaving this blank will make the script return false when it fails to detect a mobile.

Thanks for your post.
Title: Re: SMF4iPhone Mod
Post by: mkress on February 27, 2011, 01:48:49 PM
Hi,

simply set the second param to false:

$mobileCheck = mobile_device_detect(true,false,true,true,true,true,true,false,false);
Title: Re: SMF4iPhone Mod
Post by: z_dane on February 27, 2011, 11:14:17 PM
credit to fca07

however after try edit myself, i get blank page.

(smf 2.0 RC5 with latest mod + inferno theme & smf4iphone theme)

hopefully somebody will update this mode for rc5
Title: Re: SMF4iPhone Mod
Post by: dembow on March 01, 2011, 01:40:17 PM
hi i need a little help

i want the unread button to link to: index.php?action=unread;all;start=0 instead of how it is now pointing to: index.php?action=unread

what do i need to change?
Title: Re: SMF4iPhone Mod
Post by: NanoSector on March 01, 2011, 01:51:08 PM
Quote from: dembow on March 01, 2011, 01:40:17 PM
hi i need a little help

i want the unread button to link to: index.php?action=unread;all;start=0 instead of how it is now pointing to: index.php?action=unread

what do i need to change?
This is not the right topic. Create a new one, please.
Title: Re: SMF4iPhone Mod
Post by: dembow on March 01, 2011, 01:59:25 PM
oh sorry, but where?
Title: Re: SMF4iPhone Mod
Post by: NanoSector on March 01, 2011, 02:29:23 PM
Quote from: dembow on March 01, 2011, 01:59:25 PM
oh sorry, but where?
If you have SMF 2.0 RCx into the 2.x support boards and the other one (1.x support boards) for 1.1.x.

Simple, innit? ;)
Title: Re: SMF4iPhone Mod
Post by: dembow on March 01, 2011, 02:38:38 PM
Quote from: Yoshi2889 on March 01, 2011, 02:29:23 PM
If you have SMF 2.0 RCx into the 2.x support boards and the other one (1.x support boards) for 1.1.x.

Simple, innit? ;)

but aren't those boards for smf support only?
Title: Re: SMF4iPhone Mod
Post by: NanoSector on March 01, 2011, 02:41:44 PM
Quote from: dembow on March 01, 2011, 02:38:38 PM
Quote from: Yoshi2889 on March 01, 2011, 02:29:23 PM
If you have SMF 2.0 RCx into the 2.x support boards and the other one (1.x support boards) for 1.1.x.

Simple, innit? ;)

but aren't those boards for smf support only?
Yesssssssss......your problem is with SMF isn't it? SMF processes the links (index.php?action=actionhere in your case)... ???
Title: Re: SMF4iPhone Mod
Post by: dembow on March 01, 2011, 02:56:16 PM
my problem is with the SMF4iPhone mod unread topics button link

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi.imgur.com%2Fl9r58.jpg&hash=228ff88797668c62962efb95b3444e69933b9de3)

i want that button to link to: index.php?action=unread;all;start=0 instead of how it is now pointing to: index.php?action=unread

does this has to do with smf or with the SMF4iPhone mod?

Title: Re: SMF4iPhone Mod
Post by: dembow on March 03, 2011, 11:46:00 AM
scratch that, just figured it out
Title: Re: SMF4iPhone Mod
Post by: Leemy on March 13, 2011, 11:02:26 AM
Is there a resolution for the frequent "SMF4iPhone Mod failed to connect to DetectFree" errors? I dont think any users are being properly redirected.
Title: Re: SMF4iPhone Mod
Post by: Robin1989 on March 14, 2011, 09:19:00 PM
will this be updated to rc5 and does the mod and theme work on a forum with simpleportal installed as that makes index.php goto the portal and index.php?action=forum goto the forum
Title: Re: SMF4iPhone Mod
Post by: dembow on March 21, 2011, 06:28:34 PM
please update this to rc5...please!  (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fsmiliesftw.com%2Fx%2Fyahoo_63.gif&hash=7d139c2f0378440317a742787b0e4ede5c17f91d)


nevermind managed to make it work on RC5 (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi44.tinypic.com%2F9sa1jl.jpg&hash=ff7c3c72e6d53c1d84bdc79aa24ea6ae2502d5ba)
Title: Re: SMF4iPhone Mod
Post by: waruna on March 23, 2011, 09:58:04 AM
If I install this mod, does iphone user can surf my forum nicely? And does this mod support Blackberry?

I use SMF 2.0 RC2, is it ok?

Thanks in advance
Title: Re: SMF4iPhone Mod
Post by: mastro on March 23, 2011, 10:48:09 AM
Quote from: dembow on March 21, 2011, 06:28:34 PM
please update this to rc5...please!  (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fsmiliesftw.com%2Fx%2Fyahoo_63.gif&hash=7d139c2f0378440317a742787b0e4ede5c17f91d)


nevermind managed to make it work on RC5 (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi44.tinypic.com%2F9sa1jl.jpg&hash=ff7c3c72e6d53c1d84bdc79aa24ea6ae2502d5ba)

Do you mean that you made it to recognize the iphone??
Title: Re: SMF4iPhone Mod
Post by: dembow on March 25, 2011, 12:18:00 PM
Quote from: mastro on March 23, 2011, 10:48:09 AM

Do you mean that you made it to recognize the iphone??

have you tried installing this on RC5?
Title: Re: SMF4iPhone Mod
Post by: mastro on March 25, 2011, 12:34:17 PM
Quote from: dembow on March 25, 2011, 12:18:00 PM
Quote from: mastro on March 23, 2011, 10:48:09 AM

Do you mean that you made it to recognize the iphone??

have you tried installing this on RC5?

Yes ->Look here www.hdforum.gr (http://www.hdforum.gr)
But it has the known problem "SMF4iPhone Mod failed to connect to DetectFree"
Title: Re: SMF4iPhone Mod
Post by: jack001 on March 26, 2011, 01:38:53 PM
ya. Its not getting installed in my smf 2.0 rc5.
Giving error of file either corrupt or not compatible to version. Please mod it for rc5.
Title: Re: SMF4iPhone Mod
Post by: dembow on March 27, 2011, 03:01:37 AM
@mastro @jack001 when installing the mod emulate for RC3 (click the advanced link and change it to RC3 instead of RC5). at least for me it let me install it

i have a work around for the detect problem but it makes the classic button do nothing and users can't see the "default" theme just the iPhone theme  :-\
Title: Re: SMF4iPhone Mod
Post by: Lolafish on April 01, 2011, 12:14:35 PM
Will there be an updated iphone mod that uses something "other" than Detect Free in the near future?

My work around right now is that I've added a "Mobile Site" menu button in my forum, but it's inconvenient to make users have to look for it.  Auto detect is so much better.   ;)
Title: Re: SMF4iPhone Mod
Post by: KensonPlays on April 01, 2011, 08:46:39 PM
I tried emulating for RC4 it says installed correctly but i tried on my android phone on Dolphin Browser HD and Dolphin Browser Mini but it loads full desktop site.
Title: Re: SMF4iPhone Mod
Post by: rosey on April 02, 2011, 09:47:21 AM
would love to see an update for RC5
Title: Re: SMF4iPhone Mod
Post by: butchs on April 03, 2011, 07:51:23 AM
Quote from: Lolafish on April 01, 2011, 12:14:35 PM
Will there be an updated iphone mod that uses something "other" than Detect Free in the near future?

My work around right now is that I've added a "Mobile Site" menu button in my forum, but it's inconvenient to make users have to look for it.  Auto detect is so much better.   ;)

I am getting annoyed with this...  I gave this mod to Fab hoping he would support it since he seemed to have the drive and a mobile device (something I do not have).  >:(

It can be easily converted to Tera-Wurfl (http://www.tera-wurfl.com/wiki/index.php/Main_Page).

Download and install Terra-Wurfl.

Search Detectfree.php for:
// No data in SMF cache about this IP or session and no cookie. Time to check the Detectfree db
        $headers = "";
        if (function_exists("getAllHeaders")) {
                foreach (getAllHeaders() as $key => $value) {
                        $key_lower = strtolower($key);
                        if ($key_lower == "connection") continue;
                        if ($key_lower == "content-length") continue;
                        if ($key_lower == "content-type") continue;
                        if ($key_lower == "host") continue;
                        if ($key_lower == "keep-alive") continue;
                        $headers .= "$key: $value\r\n";
                }
        } else {
                foreach ($_SERVER as $key => $value) {
                        if (substr($key, 0, 5) == "HTTP_") {
                                $key = str_replace("_", " ", substr($key, 5));
                                $key = str_replace(" ", "-", ucwords(strtolower($key)));
                                $key_lower = strtolower($key);
                                if ($key_lower == "connection") continue;
                                if ($key_lower == "content-length") continue;
                                if ($key_lower == "content-type") continue;
                                if ($key_lower == "host") continue;
                                if ($key_lower == "keep-alive") continue;
                                $headers .= "$key: $value\r\n";
                        }
                }
        }
       
        $url = "http://detectfree.moviladetection.com/";
$contents  = iphone_fetch_web_data($url, $headers);

$is_mobile = "undef";

if (!$contents) {
loadLanguage('Errors');
log_error($txt['iphDNS'], 'user'); // could not connect
        } else {
                $lines = explode("\r?\n", $contents);
               
                foreach ($lines as $line) {
                        $pos = strpos($line, ":");
                        if ($pos && strlen($line) > $pos + 1) {
                                $key = substr($line, 0, $pos);
                                $value = substr($line, $pos + 1);
                                if ($key == "is_mobile")
                                        $is_mobile = $value;
                        }
                }
        }


replace with:
$is_mobile = false;
// Include the Tera-WURFL file
require_once("TeraWurfl.php");

// instantiate the Tera-WURFL object
$myDevice = new TeraWurfl();

// Get the capabilities from the object
$myDevice->GetDeviceCapabilitiesFromAgent($_SERVER['HTTP_USER_AGENT']);
$cap = $myDevice->capabilities;

//  device brand $cap['product_info']['brand_name']
$devicename = $cap['product_info']['model_name'];

// check if this device is mobile
if($cap['product_info']['is_wireless_device'])
$is_mobile = true;



Then simply maintain the wurfl database.
Title: Re: SMF4iPhone Mod
Post by: Commander Keen on April 12, 2011, 10:56:41 AM
It works! (RC4 and Tera-Wurfl). At least on my own iphone 4

Thanks a lot!
Title: Re: SMF4iPhone Mod
Post by: mastro on April 13, 2011, 01:38:50 PM
How do we install Tera-Wurfl?? Is there a how to?? Any fast details on the installation??
Title: Re: SMF4iPhone Mod
Post by: Snape on April 13, 2011, 01:47:57 PM
Quote from: mastro on April 13, 2011, 01:38:50 PM
How do we install Tera-Wurfl?? Is there a how to?? Any fast details on the installation??
The wiki explains how...but if you're on shared hosting, make sure your provider supports mysqli in PHP or else the installer won't run at all.
Title: Re: SMF4iPhone Mod
Post by: butchs on April 15, 2011, 07:46:58 PM
Quote from: Commander Keen on April 12, 2011, 10:56:41 AM
It works! (RC4 and Tera-Wurfl). At least on my own iphone 4

Thanks a lot!

Yay!!!  Not bad for a guy who does not have a smart phone.
:)
Title: Re: SMF4iPhone Mod
Post by: mastro on April 16, 2011, 05:29:56 AM
Quote from: Snape on April 13, 2011, 01:47:57 PM
Quote from: mastro on April 13, 2011, 01:38:50 PM
How do we install Tera-Wurfl?? Is there a how to?? Any fast details on the installation??
The wiki explains how...but if you're on shared hosting, make sure your provider supports mysqli in PHP or else the installer won't run at all.

Thanks you...managed to succeed !!

Finally...what do you mean by "Then simply maintain the wurfl database." ???
Title: Re: SMF4iPhone Mod
Post by: butchs on April 16, 2011, 05:58:49 AM
wurfl uses a database that has to be updated.  Read about it at the wurfl site.
Title: Re: SMF4iPhone Mod
Post by: Sakacoco on April 27, 2011, 06:00:39 AM
butchs,

Thanks for the Tera Wurfl but it doesn't work on my setup using SMF 2.0 RC5, any tips ?
Title: Re: SMF4iPhone Mod
Post by: butchs on April 27, 2011, 04:22:07 PM
Try testing Tera Wurfl and make sure that is working.
Title: Re: SMF4iPhone Mod
Post by: Dlget on May 14, 2011, 09:01:10 PM
i'm getting error message, "SMF4iPhone Mod failed to connect to DetectFree" in Error log
Title: Re: SMF4iPhone Mod
Post by: Dlget on May 15, 2011, 09:27:15 PM
Visit My Website dlget.co.cc from iphone or mobile & say if the mod is working or not
Title: Re: SMF4iPhone Mod
Post by: Bagheera on May 17, 2011, 08:47:52 AM
Your site doesn't work at all  :P  "Server not found"
Title: Re: SMF4iPhone Mod
Post by: jezinho on May 18, 2011, 12:47:56 PM
Is there still someone working on the Movila DetectFree problems with this mod?
Apparently (after reading the whole thread) their whole page was down for some time, but now it's definitely working again (don't know about the database though): http://www.moviladetection.com/detectfree

I've read about the Tera-Wurfl workaround, but considering the additional work with keeping it up-to-date (and thus multiplied opportunities to make sth wrong for a 50% noob like me), the Movila one would be the better choice.
Title: Re: SMF4iPhone Mod
Post by: Dlget on May 19, 2011, 09:43:41 PM
No it's working
Title: Re: SMF4iPhone Mod
Post by: Bagheera on May 20, 2011, 01:50:44 PM
Now it does  :D and on blackberry it shows the regular theme as on computer :-X If you want to show the mobile theme on blackberry you have to specify each model separately for it to work.  ;)
Title: Re: SMF4iPhone Mod
Post by: Iomega0318 on May 25, 2011, 11:49:51 PM
So I noticed a warning on install about caching having to be enabled.. Why is that?
My host wont allow caching anyways.. which I kind of prefer.. Just curious why..
Title: Re: SMF4iPhone Mod
Post by: butchs on May 26, 2011, 06:31:08 PM
Then select the "Skip cache errors" check box.
Title: Re: SMF4iPhone Mod
Post by: eng_HK on May 29, 2011, 10:45:37 AM
Hi I tried to use the Tera-Wurfl..without any success.

I have forum installed in /Forum so the detectfree.php is under /Forum/Sources/detectfree.php
I have installed Tera-wurlf in /WURFL

On the line of the include what I have to specify??
// Include the Tera-WURFL file
require_once("../../WURFL/TeraWurfl.php");

is correct?
it doesn't work, but i can't see any error inside the log.
I always can see only the default theme

Pls help me
Thx
Title: Re: SMF4iPhone Mod
Post by: eng_HK on June 06, 2011, 09:10:23 AM
Someone have any idea??
Title: Re: SMF4iPhone Mod
Post by: ChaosEnergy on June 17, 2011, 04:04:54 PM
will there be an update for 2.0 gold?
Title: Re: SMF4iPhone Mod
Post by: PLAYBOY on June 20, 2011, 07:24:23 AM
If somebody gives me the texts, i can translate it to Turkish right away.
When is this gonna be updated for 2.0?
Title: Re: SMF4iPhone Mod
Post by: Lazybones on June 25, 2011, 05:30:04 PM
Just a poke to see if it is likely a 2.0 final update will be released for this mod?
Title: Re: SMF4iPhone Mod
Post by: shorepower on July 03, 2011, 08:51:46 AM
Small bump. Would love to use this mod and theme on our 2.0 forum
Title: Re: SMF4iPhone Mod
Post by: Lolafish on July 11, 2011, 08:47:19 PM
Ugh...still a lot of steps to this.  Haven't done it:

http://www.simplemachines.org/community/index.php?topic=381400.msg3007557#msg3007557

Are there many people using this on 2.0 Gold yet?
Title: Re: SMF4iPhone Mod
Post by: PLAYBOY on July 11, 2011, 11:09:51 PM
QuoteAre there many people using this on 2.0 Gold yet?

I definetely will after the update.
Title: Re: SMF4iPhone Mod
Post by: numus on August 01, 2011, 11:11:29 AM
Any update on this working with 2.0? Been patching the 2.0 rc4 and still can't get it to work.
Title: Re: SMF4iPhone Mod
Post by: Eric222 on September 07, 2011, 10:54:52 AM
Quote from: numus on August 01, 2011, 11:11:29 AM
Any update on this working with 2.0? Been patching the 2.0 rc4 and still can't get it to work.
Patient is a virtue ok
Title: Re: SMF4iPhone Mod
Post by: hcfwesker on September 11, 2011, 05:34:39 PM
Quote from: numus on August 01, 2011, 11:11:29 AM
Any update on this working with 2.0? Been patching the 2.0 rc4 and still can't get it to work.

Same here.  The edits for mobile themes in their Profile.template.php files are none existent.  Really hoping for a 2.0 Update soon.  :)
Title: Re: SMF4iPhone Mod
Post by: misha3 on October 08, 2011, 08:19:43 AM
About the pretty good idea to use Tera-WURFL:

I found out on a shared web server after installation, that WURFL needs high MySQL rights (CREATE_ROUTINE), that my provider (hosteurope) will not give on shared server products ... so :-(
Title: Re: SMF4iPhone Mod
Post by: Iomega0318 on November 05, 2011, 09:08:52 AM
I agree, a 2.0 version would be awesome now lol :)
Title: Re: SMF4iPhone Mod
Post by: Dlget on November 11, 2011, 11:41:34 AM
I'm using it. What's tera wurfl.
Title: Re: SMF4iPhone Mod
Post by: DEK24 on November 27, 2011, 08:56:41 PM
Is there any update on this in the works?
Title: Re: SMF4iPhone Mod
Post by: DEK24 on December 19, 2011, 09:37:14 PM
Quote from: DEK24 on November 27, 2011, 08:56:41 PM
Is there any update on this in the works?

anyone?
Title: Re: SMF4iPhone Mod
Post by: PLAYBOY on December 19, 2011, 11:32:02 PM
I am also waiting for an update
Title: Re: SMF4iPhone Mod
Post by: Kindred on February 01, 2012, 08:05:59 PM
No movement in this since rc4...  Also, I am wondering about the need for any external detection service or database....   Doesn't the device identify itself on connection?

I got this error...

http://test.turtleshellprod.com/index.php?http://test.turtleshellprod.com/SMF4iPhone Mod failed to connect to DetectFree

Which I understand was happening before...
Also, of course, the theme is not designed to handle 2.0 final...
Title: Re: SMF4iPhone Mod
Post by: butchs on February 01, 2012, 08:11:37 PM
See reply 210 (http://www.simplemachines.org/community/index.php?topic=381400.msg3007557#msg3007557).
Title: Re: SMF4iPhone Mod
Post by: Kindred on February 01, 2012, 08:12:54 PM
Yeah... I read that... But why do I ave to even maintain that database?
Title: Re: SMF4iPhone Mod
Post by: butchs on February 02, 2012, 04:51:59 AM
I have not looked at it in well over a year since I do not have a smart-phone.
Title: Re: SMF4iPhone Mod
Post by: samurai-lupin on April 07, 2012, 12:46:02 AM
Hello, is there also a SMF 1.1 Version of this great mod available? Thank you
Title: Re: SMF4iPhone Mod
Post by: NanoSector on April 07, 2012, 03:48:04 AM
Quote from: samurai-lupin on April 07, 2012, 12:46:02 AM
Hello, is there also a SMF 1.1 Version of this great mod available? Thank you
Nah, you should upgrade to SMF 2.x.
Title: Re: SMF4iPhone Mod
Post by: josem on October 04, 2012, 02:33:02 PM
As someone said before, registration part is not working :(
Captcha doesnt get shown
Title: Re: SMF4iPhone Mod
Post by: swaggaderby on September 18, 2014, 03:57:22 PM
PLEASE CAN THIS BE MADE TO WORK ON SMF 2.0.8?
Title: Re: SMF4iPhone Mod
Post by: Kindred on September 18, 2014, 04:49:11 PM
please do not shout.

and this mod has not been touched in 2 years...
but it worked with RC4, so there is a better than average chance that it will still work on 2.0.8

Although, there are much better choices for mobile designs now...
Title: Re: SMF4iPhone Mod
Post by: swaggaderby on September 19, 2014, 12:15:39 PM
Quote from: Kindred on September 18, 2014, 04:49:11 PM
please do not shout.

and this mod has not been touched in 2 years...
but it worked with RC4, so there is a better than average chance that it will still work on 2.0.8

Although, there are much better choices for mobile designs now...
Alright.