phpBB 3.0 Tutorial

This tutorial explains how to add automatic mobile device detection to your phpBB 3.0 forum.

Mobile Style

First you need to upload a mobile phpBB style to your forum. You can download mobile style for phpBB 3.0 from here.

Upload it on your forum. No need to install style, you just need to upload it.

Editing files

You will need to upload one new file and edit one phpBB file to add automatic mobile device detection.

1. In style directory you will find subdirectory "contrib", in that directory you will find file "mobile.php" (art_mobile/contrib/mobile.php). Copy it to your forum to directory "includes".

2. Open includes/session.php, find this:
Code:
    // Call phpbb_user_session_handler() in case external application want to "bend" some variables or replace classes...
    // After calling it we continue script execution...
    phpbb_user_session_handler();
and add before it:
Code:
    // Mod: phpBB Mobile start
    include_once($phpbb_root_path . 'includes/mobile.' . $phpEx);
    phpbb_mobile::setup('art_mobile');  // Change first parameter to correct directory name of mobile style
    // Mod: phpBB Mobile end
That is all. Check your forum, you should see mobile style when viewing forum on mobile device.

If you do not have mobile device to test forum, open forum on your desktop. You should see link "Switch to full style" near footer. Click it. If it works, you have correctly modified your forum.

Problems

If you have ran into problems after editing files, look closely at code changes. Probably you have done a mistake somewhere.

Note that instructions tell you to paste code BEFORE code you are searching for, not after it. This is the most common mistake.

If you have any questions or ran into problems, please post your questions on support forum.