2.0.3 update – Fonts gone

  • Author
    Posts
  • #6669
    Steve

    Updated half of my sites to the new version, but now I seem to have lost control of my fonts – Lost what I had, and can’t seem to change them at all. The site without the update still have the proper font.

    #6681
    Zed
    Cryout Creations mastermind

    Hi and sorry about that.
    While improving Google font inclusion to support font styles we kind of broke the standard fonts. We’ve already fixed this and submitted the update to WordPress, but it will take a couple of days until the update becomes live.

    The fixed mantra/admin/custom-styles.php file can be retrieved from the uploaded 2.0.3.1 update.

    If you’re comfortable with editing files, you can fix the mantra/admin/custom-styles.php file yourself :

    Search for

    $mantra_googlefont = '"'.str_replace('+',' ',preg_replace('/:.*/i','',$mantra_googlefont)).'"';  
    $mantra_googlefonttitle = '"'.str_replace('+',' ',preg_replace('/:.*/i','',$mantra_googlefonttitle)).'"'; 
    $mantra_googlefontside = '"'.str_replace('+',' ',preg_replace('/:.*/i','',$mantra_googlefontside)).'"'; 
    $mantra_googlefontsubheader = '"'.str_replace('+',' ',preg_replace('/:.*/i','',$mantra_googlefontsubheader)).'"'; 
    
    ?><?php if (stripslashes($mantra_fontfamily) != '"Segoe UI", Arial, sans-serif' || $mantra_googlefont) { ?> * , .widget-title {font-family:<?php if (!$mantra_googlefont) echo $mantra_fontfamily; else echo $mantra_googlefont;  ?> ; }<?php }
    ?><?php if ($mantra_fonttitle != "Default" || $mantra_googlefonttitle) { ?> #content h1.entry-title a, #content h2.entry-title a, #content h1.entry-title , #content h2.entry-title {font-family:<?php if (!$mantra_googlefonttitle) echo $mantra_fonttitle; else echo $mantra_googlefonttitle;  ?> ; }<?php }
    ?><?php if ($mantra_fontside != "Default" || $mantra_googlefontside) { ?> .widget-area *  {font-family:<?php if (!$mantra_googlefontside) echo $mantra_fontside; else echo $mantra_googlefontside;  ?> ; }<?php }
    ?><?php if ($mantra_fontsubheader != "Default"  || $mantra_googlefontsubheader ) { ?> .entry-content h1, .entry-content h2, .entry-content h3, .entry-content h4, .entry-content h5, .entry-content h6  {font-family:<?php if (!$mantra_googlefontsubheader) echo $mantra_fontsubheader; else echo $mantra_googlefontsubheader;  ?> ; }<?php }

    and replace with

    $mantra_googlefont = str_replace('+',' ',preg_replace('/:.*/i','',$mantra_googlefont));
    $mantra_googlefonttitle = str_replace('+',' ',preg_replace('/:.*/i','',$mantra_googlefonttitle));
    $mantra_googlefontside = str_replace('+',' ',preg_replace('/:.*/i','',$mantra_googlefontside));
    $mantra_googlefontsubheader = str_replace('+',' ',preg_replace('/:.*/i','',$mantra_googlefontsubheader));
    
    ?><?php if (stripslashes($mantra_fontfamily) != '"Segoe UI", Arial, sans-serif' || $mantra_googlefont) { ?> * , .widget-title {font-family:<?php if (!$mantra_googlefont) echo $mantra_fontfamily; else echo "\"$mantra_googlefont\"";  ?> ; }<?php }
    ?><?php if ($mantra_fonttitle != "Default" || $mantra_googlefonttitle) { ?> #content h1.entry-title a, #content h2.entry-title a, #content h1.entry-title , #content h2.entry-title {font-family:<?php if (!$mantra_googlefonttitle) echo $mantra_fonttitle; else echo "\"$mantra_googlefonttitle\"";  ?> ; }<?php }
    ?><?php if ($mantra_fontside != "Default" || $mantra_googlefontside) { ?> .widget-area *  {font-family:<?php if (!$mantra_googlefontside) echo $mantra_fontside; else echo "\"$mantra_googlefontside\"";  ?> ; }<?php }
    ?><?php if ($mantra_fontsubheader != "Default"  || $mantra_googlefontsubheader ) { ?> .entry-content h1, .entry-content h2, .entry-content h3, .entry-content h4, .entry-content h5, .entry-content h6  {font-family:<?php if (!$mantra_googlefontsubheader) echo $mantra_fontsubheader; else echo "\"$mantra_googlefontsubheader\"";  ?> ; }<?php }

     


    If you like our creations, help us share by rating them on WordPress.org.
    Please check the available documentation and search the forums before starting a topic.
    #6704
    Martin Ward

    Thanks for the notification – I’ve just updated Mantra as well as making other changes to my site, and thought I’d broken it by also breaking the golden rule of not making too many changes at once.  I had just decided to post a bug when I checked here – phew!   And your new one works fine for me.

    Regards,

    JMW

     

    #6896
    Lisbeth Jørgensen Veillat

    Fine that you’re so fast in posting this newly introduced “bug”. I “corrected” the bug using the css costumization before I went to your site wanting to notify about this problem. I’m (not yet) ready to play with the code so the css solution is working fine for me.

    Thanks a lot,

    Lisbeth Jørgensen Veillat

    #6945
    Sara

    Whew!  I thought I had done something wrong.  Did the update and all the fonts changed.  I will wait until the next update goes live, since I’m not comfortable with the above suggestions.  Thanks!!

Viewing 5 posts - 1 through 5 (of 5 total)

The topic ‘2.0.3 update – Fonts gone’ is closed to new replies.