15

I know the iphone home button is extremely crucial for the functioning of the iphone.
However I have an idea for which I need the application running and the home button to be disabled. I tried googling, but haven't been able to find a solution.

Temporary or timed locking (Lock for 5/10 mins.) would also do.

The app. should work on non-jailbroken phones, hence going around apple won't work.

Appreciate any ideas.

PlanetUnknown
  • 3,956
  • 4
  • 49
  • 67
  • 10
    To commentators: Please provide a valid answer if you have any, but don't downvote because you disagree with the OP's idea. – BeemerGuy Nov 16 '10 at 00:46
  • 2
    The thing is that that the OP doesn't even provide any good reasoning for why it might be a good idea to disable the home button. It might be brilliant, but with the information given, it just seems really bad. There's probably other things he could do (like having the app in the background instead), but there's no way to know with the question as it is. – David Liu Nov 16 '10 at 01:53
  • 2
    David - well a reason to not divulge the reasoning is to protect the idea being implemented. I understand running applications in background. But the client requirements are quite easily solved by disabling the home button. I see that this isn't possible for regular apps. hence I'll have to figure out a diff. way. Was just trying to see if there are people who have succeeded. But I'm thankful for answering the question, one way or the other. – PlanetUnknown Nov 16 '10 at 03:11
  • 5
    @Beemer He starts off the question with "I know the iphone home button is extremely crucial for the functioning of the iphone" and then wants to know how to disable it. It's a bad question. – Gregg B Nov 16 '10 at 18:29
  • See also [Lock-down iPhone/iPod/iPad so it can only run one app](http://stackoverflow.com/questions/5011774/lock-down-iphone-ipod-ipad-so-it-can-only-run-one-app), which does provide a solution for newer iOS versions. – Ilmari Karonen Mar 01 '14 at 17:26
  • Ya, this will never get past the Review Team. Why do you want to do this? maybe there's a better implementation we can come up with to help you. – W Dyson Nov 16 '10 at 00:46
  • BubCap.com sells home button covers that effectively deter toddlers from pressing the home button. – Rob Jan 17 '11 at 03:59

7 Answers7

22

Note, from 2014 onwards: just to be clear,

this is now built in to iOS...

Click to accessibility, click "guided access".

Conrats for "inventing" it, PlanetUnknonw! :-)

The answer below is only of historic value...


For the record, it's silly that people are saying "Why would you want to do this?"

it's a great idea for example for APPS FOR SMALL CHILDREN (which is indeed a very large market on the iPhone).

If you've ever marketed an app for small children, you'll know that instantly parents write in abusing you because you "did not stop that stupid home button working, so the child just turns off the game and makes phone calls"

To which you have to reply that it's of course not possible because of the way the iPhone works.

So yes it's a good question. As far as I know, Planet, it is not possible.

Apple should add a "kids mode" where parents can lock the fone on TO one particular app for awhile. (Perhaps you would have to long-press or something the home button to unlock it.)

Community
  • 1
  • 1
Fattie
  • 27,874
  • 70
  • 431
  • 719
  • There is a strong precedent of Apple not allowing hardware buttons to have their functions altered. Just look at something like Camera+. They snuck in a convoluted sequence of steps to turn the volume buttons into shutter buttons and Apple yanked them immediately upon discovery. – Gregg B Nov 16 '10 at 18:25
  • 6
    This is a silly answer to select. Whether or not it's true that there's a possible reason, there's still no way to do it, this one is full of pretentious language to everyone who tried to help, and was late. – Steven Fisher Nov 16 '10 at 18:33
  • 2
    At no point did this answer address the original question except to say "it should be an option". The points don't matter, but this goes to the idea that the question was bad - it can't be done and SHOULDN'T be done (in an app), but the OP just voted for the person who placated him. oh well. – Gregg B Nov 16 '10 at 19:25
  • I didn't have any points at stake in this question, I also mentioned how they don't matter, so I don't know why you are getting all worked up. The person below with 6 votes answered the question with a link, quote, and alternative - he had the better answer. – Gregg B Nov 16 '10 at 19:41
  • I don't care for the outcome (in terms of S/O points etc.), I'm just here to give my two cents. I actually like your idea, here. You could mention that a bug (enhancement) request be filed. – DJ Bouche Nov 16 '10 at 23:02
  • 2
    I don't have any stake in it either, but your answer "buries the lead" and fails to provide a link to Apple's guidelines. It's a bad accepted answer for posterity. Could you add a link to the review guidelines to it and state earlier that it isn't possible? That'd improve it. (Don't get me wrong, I'm certainly not going to downvote you. Your answer is entirely correct. It's just not ideal.) – Steven Fisher Nov 17 '10 at 16:24
14

UPDATE

*iOS 6 reportedly has a "Single App Mode" - Check out vpdn's answer below https://stackoverflow.com/a/10503799/333259

This is against the iOS interface guidelines, and apps have been rejected for "overriding" or restricting behaviour of hardware buttons/switches.

I suggest you have a read of the App Store Review Guideline for iOS apps for a good overview of what you shouldn't be doing.

Particularly:

10.5

Apps that alter the functions of standard switches, such as the Volume Up/Down and Ring/Silent switches, will be rejected

Pretty sure that the Home button is included in that.

I'm not sure what your "idea" is here, but I would suggest you look into other things such as backgrounding. There is a feature that allows you to finish executing tasks in the background, even if the user presses the home button, and optionally display a notification after certain time (before the task "expires"). I imagine that this might offer a more appropriate solution (again dependent on what your idea actually is).

Community
  • 1
  • 1
DJ Bouche
  • 1,154
  • 1
  • 9
  • 17
5

In iOS6 (to be released), there's a feature called "Guided Access", which will allow device owners to lock users (like toddlers and school kids) into an app.

Update: Before the shitstorm about NDA content starts, here's where I got the info from: http://www.theverge.com/2012/6/11/3078350/apple-ios-6-guided-access-parental-control

2

You can't unless you want to run it on jail broken devices.

Catman232
  • 21
  • 1
2

Apple currently will not allow any software to disable or change ANY button functionality for iPhone, iPad, and iPod touch, so the only software solution is to jailbreak the device, so you're not forced to live by Apple's rules.

However, PaperclipRobot.com is about to release a home button cover specifically targeted to keeping young kids from pressing the home button. Not the exact solution to your problem as stated, but I figured it added to the discussion.

1

Unsure if you are looking for a way to do it in code in an app or if you're thinking of locking it in general.

Anyways, if you're looking for a way to do it in general, here's a guide for it

http://igrudge.net/how-to-disable-the-home-button-on-ios-devices-iphoneipad/

njalk
  • 11
  • 1
0

If you are looking to temporarily disable the home button to keep a child in a particular app, the tip for a make magazine article is to use a bulldog clip to cover the home button cheaper, and more reusable than a bubcap, temporary and effective.

Source: http://blog.makezine.com/2011/03/01/ipad-home-button-child-lock/

Danny Staple
  • 7,101
  • 4
  • 43
  • 56