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

The Archive Base Latest Questions

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

I am currently working on a mobile application framework written in HTML 5, CSS3

  • 0

I am currently working on a mobile application framework written in HTML 5, CSS3 and jQuery. For the markup of the ‘screens’, I have the following layout:

<div class="page" id="home">
    <!-- some content is here... -->
</div>
<div class="page" id="lists">
    <!-- some more content is here... -->
</div>

I am currently using jQuery to detect the first div element on the page and set it’s class attribute as current. I then have the following CSS declaration which hides anything other than page.current:

div.page {
    display: none;
}
    div.page.current {
        display: block;
    }

Whenever the browser detects a hash change event (window.onhashchange), I run the following jQuery:

if(window.location.hash)
{
    var the_hash = window.location.hash.substring(1);
    if($('#' + the_hash).length > 0)
    {
        $('.current').removeClass('current');
        $('#' + the_hash).addClass('current');
    }
}
else
{
    $('div').eq(0).addClass('current');
}

Which works great at showing whichever anchor element was clicked. However, I would now like to create a CSS transition (something simple like a slide transition). I know that I could achieve this using jQuery and animate(), but I would prefer to go with an entirely CSS3 animation (something like transitioning transforms), because iOS provides hardware acceleration for these animations.

Could anyone point me in the right direction as to how, with this markup I might add in an animation to wipe the current div from right to left, while at the same time showing the new one?

  • 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-24T23:29:54+00:00Added an answer on May 24, 2026 at 11:29 pm

    The simplest way is probably to add another class to each offscreen page, such as .left and .right, that positions the page just off the screen to that side, maybe using use the left: CSS property.

    To bring the page onto the screen, you would remove the .left class and change it to .current.

    To animate the transition, you’d need a CSS rule on the .page class like:

    -webkit-transition: left 1s linear;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm currently working on a consumer mobile application project and have read that 40%
Currently I am working with Jquery mobile and encountered the following problem: I am
Working on a mobile application using jquery mobile and phonegap framework. My question is
I am working on a PhoneGap application using jQuery Mobile. Currently I am only
I`m currently working on a script, and I have the following situation. function somnicefunction()
I am designing a Netflix Application for BlackBerry mobile devices. I am currently working
I am currently working on the creation of an application for mobile devices with
Does Using Namespace; consume more memory? I'm currently working on a mobile application and
We have a Windows Mobile application which is currently running on Symbol (now Motorola)
the application i'm currently working on is mobile network dependant, so my question is,

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.