Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7705645
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T23:54:53+00:00 2026-05-31T23:54:53+00:00

I have searched for hours for the answer to my question and have found

  • 0

I have searched for hours for the answer to my question and have found nothing that seems to work. So please accept my apologies if this question has already been answered…

I am very new to app development and have been suggested to go down the route of html, css, jquery using XCODE and PhoneGap to build and compile.
After a lot of faffing, I’ve managed to build a html page and test it through XCODE.

My issue is I can not force the orientation to landscape.

I found answers to set the orientation in the .plist file which I have done. This changes the orientation of toolbars and viewing window, but the content (HTML) stays in portrait mode.

I found an example post where someone created a test app in landscape mode only, great I thought, but unfortunately this was in objective C.

For example this is in a file called ViewA.m

    // ViewA.m

#import "ViewA.h"

@implementation ViewA

-(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
    {
    return (interfaceOrientation == UIInterfaceOrientationLandscapeRight);
    }

-(void)viewDidLoad
    {
//  self.view.frame = CGRectMake(0.0, 0.0, 1024.0, 768.0);
    [super viewDidLoad];
    }

@end

Do these separate files work for HTML as well as Objective C?
Is there a jquery/javascript solution for html apps?

I appreciate this is a bit of a “bitty” question and there could be multiple answers. I would appreciate any help or direction someone could offer.

If this has been solved already, as I say sorry for a repeat question, but there are so many of similar questions, it’s very hard to get through them all!

Thanks in advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T23:54:55+00:00Added an answer on May 31, 2026 at 11:54 pm

    I’ve noticed a few people have looked. I’ve managed to find the answer to my question and wanted to post it, just incase anyone else is having a similar issue.

    To get the content of an app written in HTML to appear in landscape mode you need to go (in xcode)
    Folder (app name) -> Classes -> MainViewController.m

    You will see:

        - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
    {
        // Return YES for supported orientations
        return (interfaceOrientation == UIInterfaceOrientationPortrait);
    }
    

    Change this to

    - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
    {
        // Return YES for supported orientations
        return (interfaceOrientation == UIInterfaceOrientationLandscapeRight);
    }
    

    And that should work 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have searched for this, and i found that for api less than 12,
This is quite a noobish question, I have searched for a few hours now
ok, i have searched for this in the past two hours with results that
I have searched for hours now and haven't found a solution for my problem.
Up till now I have searched for hours on end and have not found
I have searched already but unable to find an answer that works. I simply
I've searched Google for hours, but I can't find the answer anywhere. I have
i searched the web now several hours but get no clear answer. I have
I have searched for hours but could not find anything similar. The crash has
I searched the last hours for a custom control that looks like this: Triangular

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.