WordPress.org

Ready to get started?Download WordPress

Forums

different body_class output between localhost and online (4 posts)

  1. geoffmuskett
    Member
    Posted 3 years ago #

    Hi all,

    It's not a major problem, but for some reason I'm getting different outputs from the body_class function between my localhost (XAMPP) and online. For example the same page is 'page-id-14' on localhost and 'page-id-12' online. I'm using the Starkers theme, and the page is http://www.babelfishlanguageschool.com/courses/

    I guess it's a different PHP configuration or something. Has anyone had this before and know of a fix?

    For the minute I have two style sheets and its a little awkward.

    Thanks,

    Geoff

  2. Chip Bennett
    Theme Review Admin
    Posted 3 years ago #

    Are you using exactly the same database between the two sites?

    The difference is that on your XAMPP install, the Page in question has an ID of 14, while on your webhost, the Page in question has an ID of 12.

    The $page->ID comes from the database table.

  3. esmi
    Forum Moderator
    Posted 3 years ago #

    For example the same page is 'page-id-14' on localhost and 'page-id-12' online.

    That makes perfect sense to me. You simply created the pages in a different order on your local server compared to your remote server.

  4. geoffmuskett
    Member
    Posted 3 years ago #

    Of course! [slaps forehead]

    Thanks for your help guys!

Topic Closed

This topic has been closed to new replies.

About this Topic