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 6778901
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T16:19:17+00:00 2026-05-26T16:19:17+00:00

I’m learning Android development using Pro Android Web Apps (Apress, Auths: Damon Oehlman &

  • 0

I’m learning Android development using Pro Android Web Apps (Apress, Auths: Damon Oehlman & Sebastien Blanc). I ran into a snag in the second chapter (not a good sign if I’m having trouble already). I couldn’t find any help from the Apress site on the book, so I’m hoping you guys can help me out here.

The chapter has me build an html, css, and js file that are supposed to detect and display the orientation of the device as the user rotates it (rotates the device, that is 🙂 ).

When I run the code in an Android emulator running on my local WAMP server, the page displays ok (I don’t think the css is quite right, but that’s no big deal), but the data regarding the orientation isn’t being displayed at all. I made sure the link to the js file is correct, and I’ve even downloaded all three files from the Apress site to see if it’s something in my code, but those won’t work either. The book’s code is written for v2.1.

I have posted the code for the three files here. Since I’m working through the book using a local WAMP server, I don’t really know how to make it easier for someone to take the files and test them his/herself. Sorry.

I really hope someone can take a look at the code and help me out. I’d really appreciate it, so I can continue on working through the book!

Thanks!

[Edit]
I just figured out how to change the orientation in the emulator and the display does rotate, but again, the output that the js is supposed to generate isn’t displaying after the bulleted items.

  • 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-26T16:19:18+00:00Added an answer on May 26, 2026 at 4:19 pm

    I can’t help too much but recommend that you use an actual device for things like this. If you still wish to use the emulator, make sure you choose Android 2.1 for the OS. You can also debug using the equivalent of System.out.println by using Log.d("tagname","line to be displayed"); which will display lines onto DDMS (which if you’re using Eclipse can be seen by selecting Window -> View Perspective -> Other -> DDMS which will really help you debug this problem more!

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

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
Seemingly simple, but I cannot find anything relevant on the web. What is the
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
We're building an app, our first using Rails 3, and we're having to build
I'm making a simple page using Google Maps API 3. My first. One marker
We are using XSLT to translate a RIXML file to XML. Our RIXML contains
I have thousands of HTML files to process using Groovy/Java and I need to

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.