WordPress.org

Ready to get started?Download WordPress

Forums

Twenty Twelve
[resolved] How to apply IE8 fix to Twenty Twelve? (22 posts)

  1. AndyL99
    Member
    Posted 1 year ago #

    There is apparently a patch to Twenty Twelve that fixes the IE8 menu problem, and this is live over on .com. However the download version does not contain this patch

    Can someone please explain how to obtain the patch and how to apply it to my own installation of Twenty Twelve?

  2. paulwpxp
    Font hero
    Posted 1 year ago #

    There is a plugin to apply specific patch, pls search for it, that's the easiest way, but with svn you can just get the trunk version.

    or just go here and manually download it.
    http://core.trac.wordpress.org/browser/trunk/wp-content/themes/twentytwelve

  3. AndyL99
    Member
    Posted 1 year ago #

    Thanks paulwp

    If I download the file, where do I put it? The file is called ie.css but there is no existing ie.css file in the Twenty Twelve theme to replace or append.

  4. paulwpxp
    Font hero
    Posted 1 year ago #

    @AndyL99

    that's because it's been added, also a new fn call in the function.php too.

    You could try dl just the function.php, style.css, and /css/ie.css ( replace the first two and add the last one —make a new folder called css put the ie.css in there )

    Anyway, it's best to dl the whole thing, and it should go without saying that any changes or customizations must be done in child-theme only, leave the parent(2012) untouched.

    When you have time, take a look at svn and everything will be 99.99% easier.

  5. Steve Dennis
    Member
    Posted 1 year ago #

    I've just done as paulwp says and it works fine.

    One thing though, I can't get ie.css to work when in the child theme folder. I had to create /css/ie.css within the main twentytwelve folder.

  6. AndyL99
    Member
    Posted 1 year ago #

    Thanks Dovedale, that's good to know
    I was wondering whether the code should go in the main folder anyway, as this is code we want to be replaced when an upgrade to twentytwelve comes out

  7. Steve Dennis
    Member
    Posted 1 year ago #

    Sorry for not being more specific.

    As my child theme already has custom functions.php and style.css files, I installed the fixes to the main theme folder. I tried the ie.css in the child theme but it wouldn't pick it up, so moved it to the main theme folder.

    You are right. When twentytwelve v1.1 (?) comes out with these fixes built in, I want it to overwrite what I've just done.

    Happy now as I won't have to explain to my boss why our fancy new website won't work on IE8 (he uses IE9 and so hadn't noticed - I've been scurrying around try to fix it before he does...)

  8. paulwpxp
    Font hero
    Posted 1 year ago #

    The original question of this thread is how to apply the patch, not how to make a childtheme. The right answer is to install svn and checkout(download the update) the trunk(latest) version of 2012.

    But I figure not everyone knows or care to use svn, so why not just dl the files and try, it wouldn't be long before the official 2012 become updated though.

    Files that *I think * needed for this patch to work.

    function.php
    header.php
    style.css
    css/ie.css
    js/navigation.js

    Please note that the header.php is needed too, the conditional thing has changed.

  9. paulwpxp
    Font hero
    Posted 1 year ago #

    The reason /css/ie.css in childtheme wouldn't be loaded is because the fn call is not refering to childtheme's path, look around inside the function.php. There is a function twentytwelve_scripts_styles() which is added to wp_enqueue_scripts action hook, this is to load the js(scripts) and css(styles) into the head of html

    /*
     * Loads the Internet Explorer specific stylesheet.
     */
     wp_enqueue_style( 'twentytwelve-ie', get_template_directory_uri() . '/css/ie.css', array( 'twentytwelve-style' ), '20121010' );
     $wp_styles->add_data( 'twentytwelve-ie', 'conditional', 'lt IE 9' );

    The above is a part of it that's responsible for the ie.css, notice the get_template_directory_uri() which is the path to parent theme, not the child's. Now if anyone want to make changes to this ie.css in childtheme he/she will have to make a function call like this in child's function.php and use get_stylesheet_directory_uri() instead.

    get_template_directory_uri() = path to parent's theme

    get_stylesheet_directory_uri() = path to theme in use

    This is why 2012 is a complicated theme, it's advance - not easy to customize for web designers, but yes, the ninja level coders will always say it's easy.

    2012 is a great theme by itself, but 2012 as a default theme is a different matter.

  10. AndyL99
    Member
    Posted 1 year ago #

    Thanks Paulwp

    I'm going to try the download route as it seems promising. In general I want to stay on stable releases, but this one fix is a show-stopper to launching my new site with twentytwelve. I hope this is a one-off so hope to avoid svp

    From this page it looks like some code should be taken out of hte parent style.css
    http://core.trac.wordpress.org/attachment/ticket/22044/22044.css-only-ie7-love.diff

    I think you mis-interpreted my question about child themes. I have a child theme but would expect that this fix should go into the parent theme, so that it is automatically replaced when 1.1 comes out (is it due with 3.5?). Why do you think it should go in the child theme?

  11. paulwpxp
    Font hero
    Posted 1 year ago #

    Hi AndyL99

    No, I didn't mis-interpreted your question. The patch belongs to the parent theme, the "should be done in childtheme" was meant for any customizations.

    anyway, you do not need to manually dl the files from trunk anymore, WP has just released 3.5 RC1 , you could just go get it and take 2012 from there.

  12. AndyL99
    Member
    Posted 1 year ago #

    Thanks for the info. I tried the Twenty Twelve from teh 3.5 candidate and it works perfectly with IE8

  13. mr_index
    Member
    Posted 1 year ago #

    I cant used it
    it dont work in my sit
    help me please
    http://www.qiusk.ir

  14. esmi
    Forum Moderator
    Posted 1 year ago #

    As per the Forum Welcome, please post your own topic. Your problem - despite any similarity in symptoms - is likely to be completely different.

  15. Rich Ambrose
    Member
    Posted 1 year ago #

    Building the default theme and making it not IE8 compatible is totally irresponsible.

    I've been writing child themes with twenty eleven as the parent theme for the last 18 months. I have had to tell my client that it will take longer than expected to build as i have had to write the IE8 part from scratch. As it's not his fault I can not charge him for this and as usual it's the developer who takes the hit on their hourly rate.

    The theme is not fit for purpose. Very disappointed. It should make it clear that it does not cater for about 25-30% of all your site visitors.

    I will be go back to using twenty eleven as my parent theme in the future.

  16. esmi
    Forum Moderator
    Posted 1 year ago #

    does not cater for about 25-30% of all your site visitors.

    Where are those figures from? The current statistics all show IE8 (now over 4 years old) as well below 7% of the total audience.
    http://www.w3schools.com/browsers/browsers_explorer.asp
    http://www.w3counter.com/globalstats.php

  17. Rich Ambrose
    Member
    Posted 1 year ago #

    I think w3schools stats are based on traffic from web developers so tending to give a more modern view of browser adoption than general web traffic.

    I tend to look at gs.statcounter.com. On saying that, I haven't looked at the stats for about 9 months and was pleased to see that this fits with w3c figures of 7.1%, suggesting IE8 may well be dead which has made my day.

    http://gs.statcounter.com/#browser_version-GB-monthly-201305-201305-bar

    I will check this is backed up by Google Analytics on my own websites

  18. Andrew
    Forum Moderator
    Posted 1 year ago #

    I will check this is backed up by Google Analytics on my own websites

    Of course it's all relative to your audience. You could have 0% or 100% of your audience using IE8.

  19. Rich Ambrose
    Member
    Posted 1 year ago #

    Had a look at my own sites which seem to be between 8-10% over the last 3 months so it's true, IE8 is almost dead!

  20. esmi
    Forum Moderator
    Posted 1 year ago #

    Pretty much, yes. The only real exceptions are those accessing from or within some corporate networks.

  21. sandeeparron
    Member
    Posted 9 months ago #

    The above one didn't worked for my site orclage.com , Any other solution for this problem.

  22. Rich Ambrose
    Member
    Posted 9 months ago #

    Ditch Twenty Twelve and use Twenty Thirteen !

    Twenty Twelve was built entirely as responsive which IE8 doesn't understand. Realising their mistake, Twenty Thirteen isn't.

    Making the parent theme responsive is no use to developers like me who heavily customise child themes so I am glad they have put that behind them.

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags

No tags yet.