Minecraft-Modern-Theme/header.php aktualisiert
This commit is contained in:
@@ -46,35 +46,35 @@
|
||||
|
||||
<div class="header-info">
|
||||
<div class="social-links">
|
||||
<?php
|
||||
// Array mit den Social-Media-Plattformen und ihren Font Awesome Klassen
|
||||
$social_icons = array(
|
||||
'discord' => 'fab fa-discord',
|
||||
'youtube' => 'fab fa-youtube',
|
||||
'twitter' => 'fab fa-x-twitter', // Neues Icon für Twitter/X
|
||||
'facebook' => 'fab fa-facebook-f',
|
||||
'instagram' => 'fab fa-instagram',
|
||||
'tiktok' => 'fab fa-tiktok',
|
||||
'twitch' => 'fab fa-twitch',
|
||||
'steam' => 'fab fa-steam',
|
||||
'github' => 'fab fa-github',
|
||||
'linkedin' => 'fab fa-linkedin-in',
|
||||
'pinterest' => 'fab fa-pinterest-p',
|
||||
'reddit' => 'fab fa-reddit-alien',
|
||||
'teamspeak' => 'fab fa-teamspeak',
|
||||
'spotify' => 'fab fa-spotify'
|
||||
);
|
||||
<?php
|
||||
// Array mit den Social-Media-Plattformen und ihren Font Awesome Klassen
|
||||
$social_icons = array(
|
||||
'discord' => 'fab fa-discord',
|
||||
'youtube' => 'fab fa-youtube',
|
||||
'twitter' => 'fab fa-x-twitter', // Neues Icon für Twitter/X
|
||||
'facebook' => 'fab fa-facebook-f',
|
||||
'instagram' => 'fab fa-instagram',
|
||||
'tiktok' => 'fab fa-tiktok',
|
||||
'twitch' => 'fab fa-twitch',
|
||||
'steam' => 'fab fa-steam',
|
||||
'github' => 'fab fa-github',
|
||||
'linkedin' => 'fab fa-linkedin-in',
|
||||
'pinterest' => 'fab fa-pinterest-p',
|
||||
'reddit' => 'fab fa-reddit-alien',
|
||||
'teamspeak' => 'fab fa-teamspeak',
|
||||
'spotify' => 'fab fa-spotify'
|
||||
);
|
||||
|
||||
// Schleife, die alle verfügbaren Icons durchgeht
|
||||
foreach ($social_icons as $key => $class) {
|
||||
// Prüfen, ob für diese Plattform eine URL im Customizer hinterlegt wurde
|
||||
if (get_theme_mod('social_' . $key)) {
|
||||
// Wenn ja, Link und Icon ausgeben
|
||||
echo '<a href="' . esc_url(get_theme_mod('social_' . $key)) . '" target="_blank"><i class="' . esc_attr($class) . '"></i></a>';
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
// Schleife, die alle verfügbaren Icons durchgeht
|
||||
foreach ($social_icons as $key => $class) {
|
||||
// Prüfen, ob für diese Plattform eine URL im Customizer hinterlegt wurde
|
||||
if (get_theme_mod('social_' . $key)) {
|
||||
// Wenn ja, Link und Icon ausgeben
|
||||
echo '<a href="' . esc_url(get_theme_mod('social_' . $key)) . '" target="_blank"><i class="' . esc_attr($class) . '"></i></a>';
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user