• Resolved AndyL99

    (@andyl99)


    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?

Viewing 15 replies - 1 through 15 (of 21 total)
  • 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

    Thread Starter AndyL99

    (@andyl99)

    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.

    @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.

    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.

    Thread Starter AndyL99

    (@andyl99)

    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

    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…)

    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.

    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.

    Thread Starter AndyL99

    (@andyl99)

    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?

    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.

    Thread Starter AndyL99

    (@andyl99)

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

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

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

    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.

    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

Viewing 15 replies - 1 through 15 (of 21 total)
  • The topic ‘How to apply IE8 fix to Twenty Twelve?’ is closed to new replies.