Tagged: enfold
-
AuthorPosts
-
August 23, 2019 at 4:01 pm #1130393
Hi, we didn’t find answers to the following two topics:
1. How can we define “custom buttons”, e.g. https://www.dropbox.com/s/ym3rqjihlf9z9dn/button.jpg?dl=0
So the symbol on the right side of the button should have the height of the button.2. How can we define individual font colors to be easily used in WordPress editor? E.g. https://www.dropbox.com/s/yizimk83jwgmrm1/font-individual-color.jpg?dl=0
We want to define them in Enfold child theme.Thanks a lot.
August 23, 2019 at 5:33 pm #1130430Hey Jochen,
These are both tasks that can be done via css class names. You set the styles in css and then add the class name to each element that should need that styling.
Best regards,
Jordan ShannonAugust 25, 2019 at 7:57 am #1130724Hi Shannon,
thanks for your reply – but that was already clear to us.
* Can you please send a code example?
* How can we define custom colors, to be used “per click” in the WordPress editor? What do we neeed to create in Enfold child theme?BR, Jochen
August 26, 2019 at 3:32 am #1130814Hi Jochen,
1. You will likely need custom CSS for that, could you post a link to where we can see the element in question?
2. I’m not sure what you mean by “per click”? If you want to assign classes to elements in the layout builder then you can activate that functionality under Enfold->Layout Builder. Look for the Show element options for developers options.
Best regards,
RikardAugust 26, 2019 at 10:01 am #1130889Hello Rikard,
thanks for your reply.ad 1.
Well, the web page with this kind of customized buttons is net yet live.
But you could think of extending this type of code
=== snip ===
[av_button label='Mehr erfahren' link='manually,/use-cases/' link_target='' size='medium' position='left' label_display='' icon_select='yes-right-icon' icon='ue87d' font='entypo-fontello' color='custom' custom_bg='#e4004d' custom_font='#ffffff' av_uid='av-6zgei' admin_preview_bg='']
=== end snip ===
so that it looks like https://www.dropbox.com/s/ym3rqjihlf9z9dn/button.JPG?dl=0ad 2.
We want to be able to define custom colors, so that they can be used in the standard WordPress-Editor an being selected by “click”
https://www.dropbox.com/s/yizimk83jwgmrm1/font-individual-color.jpg?dl=0
We want to fill the eight empty spaces under “Individuelle” with our own custom colors.HTH & kind regards
Jochen
August 28, 2019 at 9:20 am #1131514Hello,
I need to come back to my unsolved issue:
Where can we define individual colors in the child theme?
https://www.dropbox.com/s/ff5hmuc9z38tmk4/define-individual-colors-in-editor.jpg?dl=0
Thanks, JochenAugust 29, 2019 at 10:08 am #1131835Hi,
The color sets are defined in /wp-content/themes/enfold/includes/admin/register-backend-styles.php – it’s an array which uses the color scheme name as key and each color scheme contains a sub-array which stores the color values. You can modify the array directly or use the “avf_skin_options” filter ( http://codex.wordpress.org/Function_Reference/add_filter ) to add your custom schemes.
Best regards,
BasilisAugust 30, 2019 at 9:11 am #1132198Hi Basilis,
thanks a lot. How can we use this in a child theme?BR, Jochen
August 30, 2019 at 4:10 pm #1132341Hi,
You would want to recreate the folder structure he mentioned above within the child theme, so you would have:
enfold-child/includes/admin/register-backend-styles.php
Then make the changes there.
Best regards,
Jordan ShannonAugust 30, 2019 at 4:41 pm #1132362Hi Shannon,
thanks a lot – we’re coming closer.
We’re using here “Splash Blue”
In the “register-backend-styles.php”, for “Splash Blue” are defined tons of variables.
Right now, we want to add two colors:
#e4004d and #4e748b-> What do we need to add in enfold-child/includes/admin/register-backend-styles.php, so that we can use these colors in thw WordPress editor?
Thanks a lot.
September 4, 2019 at 10:13 am #1133736Hi,
Thank you for the update.
Another user provided a possible solution in the other thread. Please continue there.
You need to add this filter in the functions.php file.
function avf_tiny_custom_colours( $init ) { $custom_colours = ' "696969", "Darkgray", "fofofo", "Hellgrau", "f4f7fc", "Hellblau", "BFCDDB", "Hellblau-2", "A0A0A0", "Hellgrau-2", "C8C8C8", "Hellgrau-3", "000000", "Schwarz" '; $init['textcolor_map'] = '['.$custom_colours.']'; return $init; } add_filter('tiny_mce_before_init', 'avf_tiny_custom_colours');
Best regards,
Ismael -
AuthorPosts
- You must be logged in to reply to this topic.