Skip to main content

Posts

Showing posts with the label TinyMCE

How to add Google fonts to select in TinyMCE editor in Joomla backend

There was a requirement from one of our customers to select Google fonts which we were using in front end pages in Tiny mice editors in Joomla 2.5 back end. I couldn't find a plug-in which provides this functionality from the back end. There are few plug-ins which can be used to enable Google fonts or font.com fonts by selectors (like class or ids).   Then I went through the source code of tiny mice editor plug-in found a way add new fonts. It was a bad thing when we think about joomla updates. But with client perspective it was a good solution I think. You are welcome to discuss with regards pros and cons.  Add new fonts here Edit editor_template.js file in  media\editors\ tinymce\ jscripts\ tiny_mce\ themes\ advanced\ editor_template.js Search for 'theme_advanced_fonts' or 'Arial' or 'georgia'. There are few places of 'theme_advanced_fonts'. You need to find correct place.  theme_advanced_fonts:"Andale Mono=andale mono,times;Arial=aria