Cambiar los valores y la personalización preestablecida del tema de Beaver Builder

Aquí hay una forma rápida de anular el preajuste activo que viene con el tema de Beaver Builder en Customizer. Esto puede ser útil si tiene que comenzar con su propia configuración preestablecida y probablemente eliminar todos los demás preajuste para que el tema no se pueda cambiar drásticamente. Obviamente, puede anular la configuración preestablecida cambiando posteriormente los valores en la personalización, este tutorial se refiere a la modificación de la configuración del valor real antes de la modificación en la personalización. Ignore el preajuste activo, por lo que el cambio de los valores iniciales del preajuste real se realiza utilizando el filtro FL_DEFAULT_THEME_MODS en el que puede pasar nuevos valores al preajuste activo. El filtro utilizado se remite al archivo class_fl_customizer.php desde el padre y se aplica a continuación.
add_filter (‘fl_default_theme_mods’, ‘prefix_default_theme_preset’);
// Cambiar los valores predeterminados predeterminados
Prefijo de funciones
$ mods2 = matriz (
‘FL-Layout-width’ => ‘ancho completo’,
‘FL-Account-width’ => ‘1020’, // El ancho del contenedor
‘fl-scroll-to-top’ => ‘activación’,
‘FL-Body-Bg-Color’ => ‘#fff’,
‘Fl-accent’ => ‘#c3251d’,
‘Fl-accent-hover’ => ‘#9999999’,
‘Fleading-Text-Color’ => ‘#5555555’,
‘Fl-topbar-bg-color’ => ‘#222222’,
‘Fl-topbar-text-color’ => ‘#cccccc’,
‘Fl-topbar-link-color’ => ‘#999999’,
‘Fl-topbar-hover-color’ => ‘#ffffff’,
‘FL-HEADER-BG-COLOR’ => ‘#000’,
‘FL-HEADER-TEXT-COLOR’ => ‘#CCCCCCC’,
‘FL-HEADER-LINK-COLOR’ => ‘ #9999999’, ‘FL-HEADER-HOVER-COLOR’ => #ffffff ‘,
‘FL-NAV-BG-COLOR’ => ‘#000000’,
‘fl-nav-link-color’ => ‘#cccccc’,
‘fl-nav-hobver-color’ => ‘#ffffff’,
‘FL-Footer-Widgets-Bg-Color’ => ‘#000000’,
‘Floter-widgets-text-color’ => ‘#cccccc’,
‘FL-Footer-Widgets-Link-Color’ => ‘#999999’,
‘FL-Footer-Widgets-Hover-Color’ => ‘#ffffff’,
‘FL-Footer-Bg-Color’ => ‘#000000’,
‘Fl-footer-text-color’ => ‘#ccccccc’,
‘FL-Footer-Link-Color’ => ‘#999999’,
‘FL-Footer-Hover-Color’ => ‘#ffffff’,
‘Fl-h1-font-size’ => ’36’,
‘Fl-h2-font-size’ => ’30’,
‘Fl-h3-font-size’ => ’24’,
‘Fl-h4-font-size’ => 20 ‘,
‘Fl-h5-font-size’ => ’18’,
‘Fl-h6-font-size’ => ’16’,
‘FL-Body-Text-Color’ => ‘#5555555’,
‘FL-Body-Font-Weight’ => ‘400’,
‘FL-Body-Font-Size’ => ’18’,
‘FL-Body-Line-Height’ => ‘1,3’
);
$ mods3 = array_merge ($ mods, $ mods2);
Devuelve $ mods3;
}
En este filtro, utilicé Array_Mebribibe para combinar una nueva matriz que es una variable llamada $ mods2 y la combinamos con la matriz de $ mods original para producir $ mods3, que luego se filtra como el nuevo conjunto de valores que verá en El backend en el personalizador.
Agregue tan pocas o cuántas teclas y valores desee. Si realiza cambios en la matriz, antes de seleccionar el preajuste, no se mostrará de inmediato, deberá cambiar a otro preajuste y volver nuevamente para mostrar el nuevo valor. Los valores utilizados anteriormente no son exhaustivos, puede ver Todos ellos en el tema principal en el archivo Customer-presets.php. Solo combina en los que necesitas. Los fragmentos de código se agregan a las características de su hijo.php para una lista completa de temas disponibles en preajuste, consulte el final del artículo.
Eliminar otras presetings completas puede eliminar opcionalmente otras prestaciones además de los valores predeterminados, si no las necesita, hay otras nueve prestaciones que vienen con el tema, aparte del valor predeterminado. Incluso puede agregar su propio preajuste completamente nuevo. Aquí le mostramos cómo eliminar los existentes, que se realiza con Flocacustomizer. add_action (‘after_setup_theme’, ‘prefix_remove_all_presets’, 11);

la función prefix_remove_all_presets () {
// Elimina todo el preajuste incorporado aparte de los predeterminados.
Flcustomizer :: remove_preset (
Array (‘Dark-Dark’, ‘Classic’, ‘Modern’, ‘Bold’,
“Estiércol”, “luxe”, “primer”, “crepúsculo”, “medianoche”
)
);
}
árbitro
S0 El otro preajuste se elimina agregándolos a la matriz, puede optar por deshacerse de todo, algunos o simplemente dejarlos como están. Sin embargo, una cosa es importante para dejar otro preajuste, como si continúe cambiando el valor predeterminado, debe cambiar a otro preajuste y volver para hacer los nuevos cambios. Configurar un preajuste como activo permanente Puede establecer permanentemente un preajuste como preajuste activo para que no se pueda cambiar. set_theme_mod (‘fl-preset’, ‘YourPresetName’); ingrese el nombre preestablecido en set_theme_mod
Eliminando partes del preajuste de la visualización en el personalizador puede refinar aún más los elementos que son visibles en el preajuste activo (y otro preajuste) en el personalizador. add_action (‘personalize_register’, ‘prefix_remove_parts_customizer’, 20);
/**
* Regístrese para personalizador
*/
La función prefix_remove_parts_customizer ($ wp_customize) {
// Elimina paneles y secciones cancelando comentarios.
$ wp_customize-> remove_section (‘fl-preset’);
$ wp_customize-> remove_panel (‘fl-general’);
$ wp_customize-> remove_section (‘fl-vidaout’);
$ wp_customize-> remove_section (‘fl-body-bg’);
$ wp_customize-> remove_section (‘fl-accent-color’);
$ wp_customize-> remove_section (‘Fleading-font’);
$ wp_customize-> remove_section (‘fl-body-text’);
$ wp_customize-> remove_panel (‘FL-Header’);
$ wp_customize-> remove_section (‘fl-topbar-lifeout’);
$ wp_customize-> remove_section (‘fl-topbar-style’);
$ wp_customize-> remove_section (‘FLeader-Lifeout’);
$ wp_customize-> remove_section (‘FLeader-style’); $ wp_customize-> remove_section (‘FLeader-logo’);
$ wp_customize-> remove_section (‘fl-nav-layout’);
$ wp_customize-> remove_section (‘fl-nav-style’);
$ wp_customize-> remove_panel (‘fl-contemplate);
$ wp_customize-> remve_section (‘fl-contemplate-bg’);
$ wp_customize-> remove_section (‘fl-contemplate-blog’);
$ wp_customize-> remove_section (‘fl-contenter-archives’);
$ wp_customize-> remove_section (‘fl-Contempts’);
$ wp_customize-> remove_section (‘fl-contemplate-woo’);
$ wp_customize-> remove_section (‘fl-lightbox-vidaout’);
$ wp_customize-> remove_panel (‘floter’);
$ wp_customize-> remove_section (‘fl-footer-widgets-layout’);
$ wp_customize-> remove_section (‘flot-footer-widgets-style’);
$ wp_customize-> remove_section (‘fl-footer-lifeout’);
$ wp_customize-> remove_section (‘flot-footer-style’);
$ wp_customize-> remove_section (‘FL-Footer-Effect’);
$ wp_customize-> remove_panel (‘FL-Code’);
$ wp_customize-> remove_section (‘FL-CSS-Code-Section’);
$ wp_customize-> remove_section (‘fl-js-section’);
$ wp_customize-> remove_section (‘Flead-Code-Section’);
$ wp_customize-> remove_section (‘FL-HEADER-CODE-SECTION’);
$ wp_customize-> remove_section (‘FL-Footer-Code-Section’);
$ wp_customize-> remove_panel (‘fl-sets’);
$ wp_customize-> remove_section (‘fl-social-links’);
$ wp_customize-> remove_section (‘title_tagline’);
$ wp_customize-> remove_section (‘static_front_page’);
// $ wp_customize-> remve_panel (‘nav_menus’);
// $ wp_customize-> remove_section (‘custom_css’); // $ wp_customize-> remove_panel (‘widgeturi’);
// $ wp_customize-> remove_section (‘fl-export-import’);
}
Esto se hace con la acción de Customize_Register, enumeré todos los paneles y secciones de personalización que corresponden a lo que ve en Customizer si usa el fragmento de código como se indica anteriormente, eliminaría todo excepto los últimos 3 elementos, no querrá eliminar todo. , así que solo comenta // que resalte lo que quieres mostrar.
Andié el fragmento de código para mostrar el panel principal y luego las secciones que les pertenecen. Refle el castor es muy útil, ciertamente puede sobrescribir todo en el estilo CSS del niño, pero también tiene sentido trabajar con personalización y establecer una gran cantidad de CSS allí, por lo que generalmente reduce la cantidad de salida de CSS. Lista de todas las configuraciones que se pueden usar en el preestablecimiento ‘FL-LAYOUT-WIDTH’ => Ancho completo,
‘Fl-cuenta-width’ => 1020,
‘FL-LAYOT-PACING’ => 0,
‘FL-Layout-shadow-size’ => 0,
‘FL-LAYOT-SHADOW-COLOR’ => #D9D9D9,
‘fl-scroll-to-top’ => activar,
‘FL-Body-Bg-Color’ => #fff,
‘FL-Body-Bg-Image’ =>,
‘FL-Body-Bg-Repeat’ => sin repetición,
‘FL-Body-Bg-Posis’ => Centro arriba,
‘FL-Body-Bg-Attachment’ => Parade,
‘FL-Body-Bg-Size’ => Auto,
‘Fl-accent’ => #c3251d,
‘Fl-accent-hover’ => #666666,
‘Fleading-text-color’ => #55555,
‘Fleading-Font-Family’ => Helvetica,
‘Fleading-font-weight’ => 400,
‘Fleading-font-format’ => Ninguno, ‘Fleading-Font-line1’ =>,
‘Fl-h1-font-size’ => 36,
‘FL-H1-LINE-HEight’ => 1.4,
‘FL-H1-ELETTER-PACING’ => 0,
‘Fl-h1-line’ =>,
‘Fl-h2-font-size’ => 30,
‘FL-H2-LINE-HEight’ => 1.4,
‘FL-H2-ELETTER-PACING’ => 0,
‘Fl-h2-line’ =>,
‘Fl-h3-font-size’ => 24,
‘Fl-h3-line-height’ => 1.4,
‘FL-H3-ELETTER-PACING’ => 0,
‘Fl-h3-line’ =>,
‘Fl-h4-font-size’ => 20,
‘Fl-h4-line-height’ => 1.4,
‘Fl-H4-Letter-Pacing’ => 0,
‘Fl-h4-line’ =>,
‘Fl-h5-font-size’ => 18,
‘Fl-h5-line-height’ => 1.4,
‘FL-H5-LETTER-PACING’ => 0,
‘Fl-h5-line’ =>,
‘Fl-h6-font-size’ => 16,
‘FL-H6-LINE-HEight’ => 1.4,
‘FL-H6-LETTER-PACING’ => 0,
‘FL-Body-Text-Color’ => #5555555,
‘FL-Body-Font-Family’ => -Sistem-Apple,
‘FL-Body-Font-Weight’ => 300,
‘FL-Body-Font-Size’ => 18,
‘FL-Body-Line-Height’ => 1.6,
‘FL-Social-icons-color’ => mono,
‘FL-Social-FaceBook’ => http://facebook.com,
‘Fl-social-twitter’ =>,
‘Fl-social-google’ =>,
‘FL-Social-LinkedIn’ =>,
‘Fl-social-yelp’ =>,
‘Fl-social-xing’ =>,
‘FL-Social-Pinterest’ =>,
‘Fl-social-tumblr’ =>,
‘Fl-social-vimeo’ =>,
‘Fl-social-youtube’ =>,
‘Fl-social-flickr’ =>,
‘FL-Social-Instagram’ =>,
‘Fl-social-skype’ =>,
‘Fl-social-dribbble’ =>,
‘FL-SOCIAL-500PX’ =>, ‘FL-Social-Blogger’ =>,
‘FL-SOCIAL-GITHUB’ =>,
‘Fl-social-rss’ =>,
‘FL-SOCIAL-IMAIL’ =>,
‘Fl-topbar-layout’ => ninguno,
‘Fl-topbar-line1’ =>,
‘FL-TOPBAR-COL1-LAYOUT’ => TEXTO,
‘Fl-topbar-col1-text’ =>,
‘Fl-topbar-line2’ =>,
‘FL-TOPBAR-COL2-LAYOUT’ => Menú,
‘Fl-topbar-col2-text’ =>,
‘Fl-topbar-bg-color’ => #222222,
‘Fl-topbar-bg-opacy’ => 100,
‘FL-TOPBAR-BG-gradiente’ => 0,
‘FL-TOPBAR-BG-IMAGE’ =>,
‘Fl-topbar-bg-repeat’ => sin repetir,
‘Fl-topbar-bg-ponis’ => Center de sus,
‘FL-TOPBAR-BG-ATTACHMENT’ => Scroll,
‘Fl-topbar-bg-size’ => auto,
‘Fl-topbar-text-color’ => #ccccccc,
‘Fl-topbar-link-color’ => #999999,
‘Fl-topbar-hover-color’ => #ffffff,
‘FL-HEADER-LAYOUT’ => Correcto,
‘Fl-in-logo-side’ => correcto,
‘FL-vertical-Header-width’ => 230,
‘FL-HEADER-PADDING’ => 30,
‘FL-fijo-header’ => fadein,
‘FL-Hide-Unil-Scroll-Header’ => Disable,
‘FL-Scroll-Discount’ => 200,
‘FL-HEADER-LINE1’ =>,
‘FL-HeAader-Account-Layout’ => Texto social,
‘FL-HeAAder-Account-Text’ => ¡Llámenos! 1-800-555-5555,
‘FL-HEADER-BG-COLOR’ => #000,
‘FL-header-bg-opacy’ => 100,
‘FL-Nav-shadow-size’ => 4,
‘Fl-nav-shadow-kolor’ => #cence,
‘FL-HEADER-BG-gradiente’ => 0,
‘FL-HEADER-BG-IMAGE’ =>,
‘FL-HEADER-BG-Repeat’ => sin repetición,
‘FL-HEADER-BG-POSIS’ => SUS Center, ‘FLeader-Bg-Attachment’ => Scroll,
‘FL-HEADER-BG-SIZE’ => Auto,
‘FL-HEADER-TEXT-COLOR’ => #CCCCCCC,
‘FL-HEADER-LINK-COLOR’ => #999999,
‘FL-HEADER-HOVER-COLOR’ => #ffffff,
‘FL-logo-type’ => text,
‘FL-LOGO-IMAGE’ =>,
‘Fl-logo-image-trin’ =>,
‘Fl-sticky-header-logo’ =>,
‘Fl-logo-text’ => beavron.dev,
‘Fl-logo-font-family’ => Helvetica,
‘Fl-logo-font-weight’ => 400,
‘Fl-logo-font-size’ => 30,
‘FL-HEADER-LOGO-TOP-TAP’ => 50,
‘FL-Nav-Print-Pacing’ => 15,
‘FL-Nav-me-top-spacing’ => 30,
‘fl-nav-weite-align’ => izquierda,
‘FL-HEADER-ASECH’ => Visible,
‘FL-Mobile-Nav-toggle’ =>,
‘FL-NAV-BreakPoint’ => Mobile,
‘FL-NAV-SUBMENU-Indicator’ => deshabilitar,
‘FL-NAV-BG-Color’ => #000000,
‘fl-nav-bg-opacy’ => 100,
‘FL-NAV-BG-gradiente’ => 0,
‘FL-NAV-BG-IMAGE’ =>,
‘Fl-nav-bg-repeat’ => sin repetición,
‘FL-NAV-BG-Postion’ => Centro superior,
‘FL-NAV-BG-ATTACHMENT’ => Scroll,
‘FL-NAV-BG-SIZE’ => Auto,
‘fl-nav-link-color’ => #ccccccc,
‘fl-nav-hobver-color’ => #ffffff,
‘FL-Nav-Font-Family’ => Helvetica,
‘FL-NAV-FONT-WEIGHT’ => 400,
‘FL-NAV-Font-format’ => Ninguno,
‘FL-NAV-FONT-SIZE’ => 16,
‘FL-COUNTANT-BG-COLOR’ => #ffffff,
‘FL-Account-Bg-opacy’ => 100,
‘FL-COUNTANT-BG-IMAGE’ =>,
‘FL-COUNTANT-BG-REPEAT’ => sin repetir, ‘fl-bg-pose’ => centro arriba,
‘FL-COUNTANT-BG-ATTACHMENT’ => Scroll,
‘FL-COUNTANT-BG-SIZE’ => Auto,
‘FL-BLOG-LAYOUT’ => Bar lateral-derecha,
‘FL-BLOG-SIDABAR-SIZE’ => 3,
‘FL-BLOG-Custom-SideBar-Size’ => 25,
‘FL-BLOG-SIDABAR-DISPLAY’ => Desktop,
‘FL-B-BLOG-SIDABAR-UCACIÓN’ => Solo, blog, búsqueda, archivo,
‘FL-BLOG-SIDABAR-UCATION-Post-types’ => todos,
‘FL-BLOG-LINE1’ =>,
‘FL-BLOG-POST Autor’ => Hidden,
‘FL-BLOG-POST-DATE’ => Visible,
‘FL-Blog-Comment-Cond’ => Visible,
‘FL-ACHIVE SHOW-FLEX’ => 0,
‘FL-ACHIVE-LEADMORE-TEXT’ => Leer más,
‘Show-thumbs de fl-dachive’ => al lado,
‘FL-ACHIVE-PULM-SIZE’ => Al lado,
‘FL-Posts show-thumbs’ =>,
‘FL-Posts-Thumble-Size’ => Miniatura,
‘FL-Posts Show-Cats’ => Visible,
‘FL-Posts Show-Tags’ => Visible,
‘FL-Posts show-av’ => oculto,
‘FL-Post Autor-Box’ => Hidden,
‘Fl-woo-layout’ => sin barra lateral,
‘Fl-woo-sidebar-size’ => 4,
‘Fl-woo-custom-sidebar-size’ => 25,
‘Fl-woo-sidebar-explay’ => escritorio,
‘Fl-woo-sidebar-ubation’ => sencillo, tienda,
‘Fl-woo-line1’ =>,
‘Fl-woo-columns’ => 4,
‘Fl-woo-line2’ =>,
‘Fl-woo-galery’ => activado,
‘Fl-woo-line3’ =>,
‘fl-woo-card-botton’ => oculto,
‘Fl-woo-line4’ =>,
‘Fl-woo-css’ => activado,
‘Fl-lightbox’ => activado,
‘FL-Footer-Widgets-Display’ => All, ‘FL-Footer-Widgets-Bg-Color’ => #000000,
‘FL-Footer-widgets-bg-opacy’ => 100,
‘FL-Footer-Widgets-BG-Gradient’ => 0,
‘FL-Footer-Widgets-Bg-Image’ =>,
‘FL-Footer-Widgets-Bg-Reepeat’ => sin repetición,
‘FL-Footer-Widgets-Bg-Posis’ => Centro arriba,
“FL-Footer-Widgets-Bg-Attachment” => Scroll,
‘Floter-widgets-bg-size’ => auto,
‘FL-Footer-Widgets-Text-Color’ => #CCCCCC,
‘FL-Footer-Widgets-Link-Color’ => #999999,
‘FL-Footer-Widgets-Hover-Color’ => #ffffff,
‘FL-Footer-Layout’ => 1-Col,
‘Floter-line1’ =>,
‘FL-Footer-Col1-Layout’ => Texto,
‘Floter-col1-text’ =>,
‘Floter-line2’ =>,
‘FL-Footer-Col2-Layout’ => Texto,
‘FL-Footer-Col2-text’ => 1-800-555-5555 • [Correo electrónico protegido],
‘FL-Footer-Bg-Color’ => #000000,
‘FL-Footer-Bg-opacy’ => 100,
‘FL-Footer-BG-Gradient’ => 0,
‘FL-Footer-Bg-Image’ =>,
‘Fl-footer-bg-repeat’ => sin repetición,
‘FL-Footer-Bg-Posis’ => Centro arriba,
‘FL-Footer-Bg-Attachment’ => Reserva,
‘Floter-bg-size’ => auto,
‘FL-Footer-Text-Color’ => #CCCCCC,
‘FL-Footer-Link-Color’ => #999999,
‘FL-Footer-Hover-Color’ => #ffffff,
‘FL-Footer-Parallax-Effect’ => deshabilitar,
‘FL-CSS-Code’ =>,
‘fl-js-código’ =>,
‘Código FLead’ =>,
‘FLeader-Code’ =>,
‘FL-Footer-Code’ =>,
‘fl-favicon’ =>,
‘Fl-aapple-touch-icon’ =>,
Este es un Lora Lora Preset.

Copyright statement: Unless otherwise noted, this article is Collected from the Internet, please keep the source of the article when reprinting.

Check Also

gkOVSBm5B8SgiXmo

Shopify vs WooCommerce – ¿Cuál es la mejor plataforma?(Comparación)

Shopify vs WooCommerce

Leave a Reply

Your email address will not be published. Required fields are marked *