Forums | Mahara Community

Developers /
Using Mahara with iPad and iPhone

anonymous profile picture
Account deleted
Posts: 3

08 June 2010, 22:26

Hi All,

As we are planning a project that uses Mahara with iPad and iPhone in class, we ran in to a small problem of the drag-and-drop not working in creating and editing views. We solved it by modifing the views.js file to treat the devices as ie6. We post it here to see whether there is better way to solve it and possibly help others who ran into the same problem and want a quick fix :-)

Many Thanks



P.S. The patch script (to patch against js/views.js file in version 1.2.4 :

<         }
>         } else {
>             // Unhide the radio button if the browser is iPhone, IPad or IPod
>             if ((navigator.userAgent.match(/iPhone/i)) || (navigator.userAgent.match(/iPod/i)) || (navigator.userAgent.match(/iPad/i))) {
>                     forEach(getElementsByTagAndClassName('input', 'blocktype-radio', 'top-pane'), function(i) {
>                     setNodeAttribute(i, 'style', 'display:inline');
>                 });
>             }
>         }
>     // Whether the brower is iPhone, IPad or IPod
>     if ((navigator.userAgent.match(/iPhone/i)) || (navigator.userAgent.match(/iPod/i)) || (navigator.userAgent.match(/iPad/i))) {
>             this.isIE6 = true;
>     }

François Marier's profile picture
Posts: 411

09 June 2010, 0:12

Thanks for that James. I opened a bug on the tracker:

Please note that patches in the "unidiff" format are a lot easier to apply (and read) if the line numbers happen to change in a future version. You can create them by using "-u" as an argument to "diff".



anonymous profile picture
Account deleted
Posts: 3

09 June 2010, 0:51

Thanks Francois

Also,  thanks for the tips on patches format.


François Marier's profile picture
Posts: 411

19 July 2010, 0:31

Hi James,

I have just committed a fix for this in what will become Mahara 1.3.

Are you able to test the following patch to make sure it works with iPhones/iPads?



anonymous profile picture
Account deleted
Posts: 1

30 October 2010, 8:11

We here have also been starting a roll-out of Mahara on Ubuntu with iPad, iPhone and iMacs.  We ran into the bigger problem of TinyMCE not working on the iPhone OS 3 devices because of the contentEditable limitation of the platform.  Rather than wait for Apple to "bless" us with iOS4 and iAds and the like, we tinkered with TinyMCE in various ways, but ended up finding this central solution that has the edit/input areas appear as a textarea for iPad/iPhone/iPod Touch and still retain their rich goodness for everyone else.  I hope it works for others as well as it's worked for us (we are using Mahara 1.2.4-1 from Ubuntu's 10.04 repositories):

--- ./lib/web.php.Save	2010-07-08 11:50:51.000000000 -0400
+++ ./lib/web.php	2010-10-29 22:56:32.195669268 -0400
@@ -96,6 +96,11 @@
     // TinyMCE must be included first for some reason we're not sure about
     $checkarray = array(&$javascript, &$headers);
     $found_tinymce = false;
+    if (strpos($_SERVER['HTTP_USER_AGENT'], 'iPad') !== false ||
+        strpos($_SERVER['HTTP_USER_AGENT'], 'iPhone') !== false ||
+	strpos($_SERVER['HTTP_USER_AGENT'], 'iPod') !== false) {
+	$found_tinymce = true;
+    }
     foreach ($checkarray as &$check) {
         if (($key = array_search('tinymce', $check)) !== false || ($key = array_search('tinytinymce', $check)) !== false) {
             if (!$found_tinymce) {
anonymous profile picture
Account deleted
Posts: 3

02 November 2010, 20:58

Hi P Park,    Thanks


Dirk Meyer's profile picture
Posts: 425

09 November 2011, 7:50

I'll pick up the thread again:

Using 1.4 and 1.5 dev, adding, deleting, editing and moving blocks on a 'edit page' does not work anymore on ipad. I see all the features such as the radio buttons, the arrows, the gear box and 'place block here' but none of those actually do anyhting.

More and more users are interested in using mahara with ipads and it would be great if someone had a quick solution. 

anonymous profile picture
Account deleted
Posts: 72

28 May 2012, 19:55

I think this was fixed but has now started again?

In the latest 1.5, with the ability to select a theme for the page, the html editor does not appear at all on the iPad.  

Instead there is a message saying that the default theme has been changed.

I'm with Dirk, the iPad is useful to us in many ways as a learning tool but currently not with iOS.

We are in the middle of a project and would be grateful for a quick fix if anyone has the time (preferably not rolling back the install :).



Kristina Hoeppner's profile picture
Posts: 3910

29 May 2012, 5:41

Hello Richard,

Sorry, but I can't test it as I don't have an iPad. Does this issue only occur when users can choose their own theme or also when they cannot? It would help to narrow down the issue to see if it is theme related or if it is something else.



P.S. Great presentation at the iMoot 2012. It's good to see how you integrate technology at your school. Smile

anonymous profile picture
Account deleted
Posts: 72

29 May 2012, 6:42

Hi Kristina

No, you can't use any of the dialogs at all, when you click an update button in edit mode, be it on an image or text box etc, nothing happens except the "theme changed" message comes up (even though you haven't changed the theme).

I think this is since the latest upgrade to 1.5 as it was working before on 1.4 and even the first 1.5 (memory a bit hazy but that's my recollection).

Obviously we don't use the iPad a lot with Mahara as the user experience is poor but sometimes we have to (our Y9's have these supplied by the school).

If you haven't seen the error, maybe I should file a detailed bug report?

Shameless plugs:
Thanks, I haven't seen yours yet, still catching up on the recordings (but I will, it's on my list).

My ppt (Moodle/Mahara at The Southport School) is also available at if anyone else is interested.  Of course, if you sign up to iMoot you can view them all.



27 results