gtd-php
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
September 09, 2010, 03:01:44 AM
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Search:
Advanced search
March 2010:
v0.9rc1
released
1756
Posts in
305
Topics by
425
Members
Latest Member:
joey_ser33
gtd-php
gtd-php
gtd-php users
Gtd-php on iPhone?
« previous
next »
Pages:
[
1
]
Author
Topic: Gtd-php on iPhone? (Read 1521 times)
bg
Guest
Gtd-php on iPhone?
«
on:
July 28, 2009, 06:52:32 PM »
Hi all,
Has anyone tried to adapt gtd-php to the I-phone?
Thank you for your reply.
«
Last Edit: December 01, 2009, 05:42:51 AM by Andrew
»
Logged
Andrew
Administrator
Hero Member
Posts: 375
Re: Gtd-php on iPhone?
«
Reply #1 on:
July 29, 2009, 11:28:28 AM »
Hello there Benjamin,
there is a
trac ticket
for this - Scott's been thinking about it
Logged
bg
Guest
Re: Gtd-php on iPhone?
«
Reply #2 on:
August 10, 2009, 02:12:32 AM »
Hi,
Thank you for your reply.
I am sorry to say I have tested this add-on and it is really far from meeting my expectations...
If there is any development for iPhone,which would be very great,please let me know.
«
Last Edit: December 01, 2009, 05:57:24 AM by Andrew
»
Logged
kirkeller
Jr. Member
Posts: 4
Re: Gtd-php on iPhone?
«
Reply #3 on:
September 07, 2009, 08:48:18 PM »
I use gtd-php and plan to use it for iPhone. I've also begun to modify it to do things like get tasks via email....so feel free to email me if you're in a similar boat.
Here's the first step I've taken to make gtd work on the iPhone.
The main menus will not work in the iPhone because the iPhone cannot understand the css onhover css state.
Luckily, the gtd-php crew had to work around the fact that IE does not handle onhover well either. Gtd-php uses javascript on the main menu to get around this IE problem. What I did was modify this javascript and remove the instruction for it to only fire if in IE. If you were really fancy I suppose you could agent sniff for the iPhone. I'm not going to do that just yet.....but maybe later.
I'll post more as I get this polished....but for right now...
1. Locate under the gtd folder the themes/default/theme.js file. This is the main script we'll work with.
1.5. Make a backup of this file before you begin editing....so if you don't like the result you can get back your original state
2. Find this line:
node.onmouseover=function(){this.className+=" over";};
3. Change it to:
node.onclick=function(){this.className+=" over";};
4. Comment out the line below it by using two slashes....it should look like this:
//node.onmouseout =function(){this.className=this.className.replace("over", "");};
What we've done is told the javascript to not fire the main menu unless you click on it.
Now we have to tell this javascript to do this no matter what the browser agent is. You'll find the line to do this about 6 lines down from the top.
5. Find this line:
var isBadIE=(browser.indexOf(" msie 6")!=-1 || browser.indexOf(" msie 5")!=-1);
6. Add to this line to tell it to treat IE6, IE5 and the iPhone the same in terms of the main menu. Change the line to look like this:
var isBadIE=(browser.indexOf(" msie 6")!=-1 || browser.indexOf(" msie 5")!=-1 || browser.indexOf("iphone")!=-1);
7. Save the theme.js file and upload it.
Now the menu will fire correctly when hit by the iPhone.
I'll add more to this if people find it helpful. Please do email me or comment here if you find this useful. Otherwise, I'll assume no one does and post my work infrequently or not at all.
Logged
Andrew
Administrator
Hero Member
Posts: 375
Re: Gtd-php on iPhone?
«
Reply #4 on:
September 07, 2009, 11:19:41 PM »
Hi Kirkeller, welcome to the forums.
Good work!
There are a few people here interested in an iPhone app, so please do keep posting. It should be possible to create an alternative iPhone theme, which would remove the need to modify the default theme. See the redblue theme in the standard distribution for how this is done.
Regards,
Andrew
Logged
kirkeller
Jr. Member
Posts: 4
Re: Gtd-php on iPhone?
«
Reply #5 on:
September 08, 2009, 10:00:31 AM »
thanks. very good point on making a theme. I had that thought as I was driving to work this morning. I'll get on that. if I do that, what's the best way to convey that? keep the files and provide links as I progress?
Logged
Andrew
Administrator
Hero Member
Posts: 375
Re: Gtd-php on iPhone?
«
Reply #6 on:
September 09, 2009, 02:52:48 AM »
Yes, you could provide links here on this forum, or you could add a page to
the wiki
, or you could add a ticket to the
enhancement & bug-tracking system
and attach files there
Logged
bg
Guest
Re: Gtd-php on iPhone?
«
Reply #7 on:
September 11, 2009, 07:02:05 AM »
Thanks Kirkeller for your work. It is brilliant. Please, let us know your most recent development.
Cheers.
Benjamin
«
Last Edit: December 01, 2009, 05:42:39 AM by Andrew
»
Logged
pix0r
Jr. Member
Posts: 1
Re: Gtd-php on iPhone?
«
Reply #8 on:
September 16, 2009, 11:56:50 AM »
As far as creating an iPhone app, it would be really helpful if there were a JSON or XML-based web service provided with GTD-PHP to read, create and edit items. Is this available or planned for a future version?
Logged
Andrew
Administrator
Hero Member
Posts: 375
Re: Gtd-php on iPhone?
«
Reply #9 on:
September 16, 2009, 01:23:02 PM »
Quote
it would be really helpful if there were a JSON or XML-based web service provided with GTD-PHP to read, create and edit items.
Yes, the AJAX plugin has some of this stuff - it's certainly possible to do AJAX calls for each of those.
But I'll admit it hasn't been done methodically - all the bits are in there; some functionality has been built. But we haven't standardised - there's a bit of XML here, a bit of JSON there. On reflection, I think I prefer the JSON, but I'm persuadable either way.
Regards,
Andrew
Logged
kirkeller
Jr. Member
Posts: 4
Re: Gtd-php on iPhone?
«
Reply #10 on:
September 16, 2009, 02:34:57 PM »
I'm not doing core development obviously, but my 2 cents would be to have crud calls done as rest services returning json.
that way you could build unique ui (which would mist likely be done with JavaScript, thus the json and understanding how to call the appropriate service and parameters would be uri based, thus easy to understand.
that being said however I could certainly understand that being a version. 10 request and not .09
Logged
Andrew
Administrator
Hero Member
Posts: 375
Re: Gtd-php on iPhone?
«
Reply #11 on:
September 18, 2009, 12:00:44 AM »
I think the REST side of it would require on some fancy footwork in .htaccess using a redirect, wouldn't it?
Say we want a url:
http://my.server/gtdphp/5
to view an item, and
http://my.server/gtdphp/5/edit
to edit the item, then I'd need .htaccess to tell the server to translate this to:
http://my.server/gtdphp/itemReport.php?itemId=5
and
http://my.server/gtdphp/item.php?itemId=5
respectively.
Now, that's easily done, as long as we know (to take probably the most common setup) that the user's got Apache with rewrite module.
The risk is, in rewriting the code so that it depends on that URL rewriting, that we exclude some users who for one reason or another wouldn't be able to set up that URL rewrite.
Or have I got this completely wrong?
Logged
kirkeller
Jr. Member
Posts: 4
Re: Gtd-php on iPhone?
«
Reply #12 on:
September 18, 2009, 10:27:43 AM »
yeah, you're right.
maybe have a rest module that could be enabled?
perhaps better for add on dev.
but yeah, you're right on the URL rewrite as I understand it
Logged
Pages:
[
1
]
« previous
next »
Jump to:
Please select a destination:
-----------------------------
gtd-php
-----------------------------
=> gtd-php users
=> gtd-php dev
Loading...