Forums | Mahara Community

Mobile Mahara /
MaharaDroid 1.7


Dirk Meyer's profile picture
Posts: 425

20 July 2011, 23:12

I have a HTC Desire with Android 2.3.3

Turns out that after I rebooted the phone the photos and videos magically appeard on the phone. I never had to reboot before. I learned that turning off and rebooting a phone are two different things. Thanks for checking

Wullie's profile picture
Posts: 252

01 August 2011, 9:42

Dirk,

I am using an HTC Desire with Android 2.2 and it doesn't delete the phot after upload.

Maybe the software version?

Dirk Meyer's profile picture
Posts: 425

12 August 2011, 14:41

Yes, it could be as its still happening but not a big deal.

On another note, I recently enabled SSL on my site and Maharadroid does not connect anymore. This is probably not implemented yet??

anonymous profile picture
Account deleted
Posts: 27

14 August 2011, 16:34

Hi Dirk,

I must confess HTTPS is untested - so thanks for giving that a go. Reviewing the code there are some crude assumptions regarding ports - HTTP is registered to 80 and HTTPS 443 .. so just defaults at this stage (I will improve in due course and should test on non-standard ports for completeness). That said in theory HTTPS should be supported. I take it you changed the Upload URI to https:// ... etc?

I would't be surprised if it does not work if there are any cert warnings, etc (the HTTP libraries tend to be fussy out of the box). I will do some debugging. 

Cheers,

Alan

anonymous profile picture
Account deleted
Posts: 34

23 January 2012, 10:13

What was the verdict on HTTPS working in your app? I figure if you use certificates to protect the HTTP connection you could do some basic stuff based on the mobile token. I'd have thought in principle that - if you have a fully correct properly signed certificate, an app should be able to say 'ok this certificate is good, proceed'.

anonymous profile picture
Account deleted
Posts: 27

29 January 2012, 16:35

Hi David,

Sorry - have not yet had a chance to look into this. Will update this thread when I have.

Cheers,

Alan

anonymous profile picture
Account deleted
Posts: 27

19 April 2012, 17:14

Hi David,

Some quick testing reveals MaharaDroid supports:

a) HTTP on any port (the default port is specifie at 80 my misunderstanding - not hard wired as I previously mentioned) .. i.e.

i) add a Listen 8000 in your port.conf on apache2 

ii) change your virtual host setting to handle *:8000

iii) change your MaharaDroid URL to include :8000 and away you go .. no issues

b) HTTPs is suported .. but when testing I get an error: "No peer certificate"

Here in my testing I'm using some default certs from base apache2 install so a bit more work may be required here (some debugging to review at least). A quick search finds me others that have solved it ..

http://stackoverflow.com/questions/8806128/android-ssl-no-peer-certificate

That said, if you are using a good trusted cert - 'it should work' .. I'll keep debugging my test one and then hopefully can run some tests on a demo https instance to confirm.

Cheers,

Alan

Emilie Lenel's profile picture
Posts: 112

22 March 2012, 5:21

Hello

I have tested MaharaDroid 1.8 (using Mahara 1.4 connected with Moodle via mnet/sso)

But when i try to upload an artefact, i have the error msg "Sending failed: Value <!DOCTYPE of type java.lang.String cannot be converted to JSONObject" ?

Do you have any idea what could be the issue ?

Thanks for your help,

Emilie

anonymous profile picture
Account deleted
Posts: 27

25 March 2012, 16:18

Hi Emilie,

It sounds like you are getting a non-JSON response from the upload request (i.e. there is an error). Mahara pages default (I believe) to start with a DOCTYPE line such as:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" ...

So this might explain the error message (that said we should trap that in the app and display an appropriate response). The JSON output should not have that string - it should just be JSON (see below). Can you please double check your settings, especially the site URLs / paths are correct. Check also what you get when you try to go directly to the page:

http://<your mahara install>/artefact/file/mobileupload.php

I see the  (with a Content-Type: application/json header):

{"fail":"Auth token cannot be blank"}

I see that you are using mnet/sso which may be complicating things (I'm not familiar with this). If anyone else can assist who is familiar / can confirm / deny this is supported with the app that would be great.

Cheers,

Alan

 

Emilie Lenel's profile picture
Posts: 112

29 March 2012, 8:03

Hi Alan

Thanks a lot for your answer

I have double checked my urls/paths, they're all correct

I also checked my url: http://vfoadtest.unicaen.fr/livret/mahara/artefact/file/mobileupload.php

I get the same message:  {"fail":"Auth token cannot be blank"}

Does anyone also faced the same issue (non-JSON response) ?

Thanks

Cheers

Emilie