This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| document.addEventListener('click', function (event) { | |
| // console.log(event.target); | |
| if (!event.target.matches('.feature_blurb_button')) return; | |
| // find the link target set in the anchor elements inside the blurb | |
| const toggleTargetParent = event.target.querySelector(".et_pb_module_header"); | |
| // console.log(toggleTargetParent); | |
| const toggleTargetID = toggleTargetParent.children[0].getAttribute('href'); | |
| const toggleTarget = document.querySelector(toggleTargetID); | |
| // console.log(toggleTarget); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Salt-Link => https://api.wordpress.org/secret-key/1.1/salt/ | |
| # Repair-Link => https://example.com/wp-admin/maint/repair.php | |
| # Settings-Link => https://example.com/wp-admin/options-general.php | |
| # Debugging | |
| define( 'WP_DEBUG', true ); # Aktiviert den Debug-Modus für PHP | |
| define( 'SCRIPT_DEBUG', true ); # Aktiviert den Debug-Modus für CSS und JS | |
| define( 'WP_DEBUG_LOG', true ); # Legt ein Fehlerprotokoll an => wp-content > debug.log | |
| define( 'WP_DEBUG_DISPLAY', true ); # Zeigt Fehlermeldungen an | |
| define( 'WP_DISABLE_FATAL_ERROR_HANDLER', true ); # Deaktiviert den eingebauten Recovery-Modus => Error Handler |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Change the title of the password reset e-mail | |
| function nxt_password_reset_title($title) { | |
| $title = 'Passwort zurücksetzen für die Webseite XYZ'; | |
| return $title; | |
| } | |
| add_filter('retrieve_password_title', 'nxt_password_reset_title'); | |
| // Change the body text of the password reset e-mail | |
| function nxt_retrieve_password_message( $message, $key, $user_login, $user_object) { | |
| // $first_name = get_user_meta( $user_object->ID, 'first_name', true ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * | |
| * @link https://nextab.de | |
| * @since 1.0.0 | |
| * @package nxt_utf8_conversion | |
| * | |
| * @wordpress-plugin | |
| * Plugin Name: Convert Database collation to utf8mb4 | |
| * Plugin URI: https://nextab.de |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function nxt_course_body_classes( $classes ) { | |
| if(is_singular('lesson')) { | |
| $kurs_taxonomy = get_the_terms(get_the_ID(), 'modules'); | |
| $tax_id = $kurs_taxonomy[0]->term_id; | |
| $bg_position = get_field('nxt_cover_pos', 'modules_' . $tax_id); | |
| } elseif(is_tax('modules')) { | |
| $bg_position = get_field('nxt_cover_pos', 'modules_' . get_queried_object_id()); | |
| } | |
| if($bg_position) { | |
| $classes[] = 'nxt_cover_pos_' . $bg_position; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* Die Funktion "load_child_theme_textdomain" ermöglicht es, ein Übersetzungs-File (de_DE.mo / de_DE.po) des jeweiligen Parent Themes über das Child Theme zu ersetzen. Konkretes Anwendungsbeispiel für Divi, bei dem die Standard-Übersetzung in Divi/lang und Divi/includes/builder/lang mit Übersetzungen im Child Theme Ordner ausgetauscht werden: | |
| **Oder (nach Divi Updates funktioniert bei mir nur noch das): | |
| /* Load Child Theme Language Files */ | |
| function nxt_translations() { | |
| // load custom translation file for the parent theme | |
| load_child_theme_textdomain( 'Divi', get_stylesheet_directory() . '/languages' ); | |
| load_child_theme_textdomain( 'et_builder', get_stylesheet_directory() . '/languages/builder' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Disable Google Fonts for Elementor | |
| add_filter( 'elementor/frontend/print_google_fonts', '__return_false', 99999 ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Shortcode [releasedate] zeigt das AKTUELLE DATUM an. | |
| function release_date_shortcode($atts, $content = null) { | |
| $today = date_i18n('l, j. F Y'); | |
| return '<div class="date_container">Veröffentlicht am: ' . $today . '</div>'; | |
| } | |
| add_shortcode('releasedate', 'release_date_shortcode'); | |
| // falls du das VERÖFFENTLICHUNGSDATUM des Beitrags ausgeben möchtest, verwende stattdessen diesen Code: | |
| function release_date_shortcode($atts, $content = null) { |