Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #940518

    Hi
    please have a look here:

    The breadcrumb is double.
    It says:
    Sie befinden sich hier:Startseite/Veranstaltungen/Veranstaltungen/Ritterfest auf Schloss Diedersdorf

    The same here:
    http://www.flugtraeumer.de/events
    It says:
    Sie befinden sich hier: Startseite/Veranstaltungen/Veranstaltungen

    How can i get rid of the duplicate?
    Regards danny

    #941076

    Hey Flugtraeumer,

    Please check if “Veranstaltungen” is added to any category? Try removing it from the assigned category for testing purpose.

    If that does not help please provide us admin login details in private so we can take a closer look at the issue.

    Best regards,
    Vinay

    #941481

    1: Its not in a category. Only single events (its a posttype) are IN categorys. Which categorys these are you can see in the single-event i linked in my last post (box to the left)
    2: The last theme-update messed it up (see Googlechache and have an eye onto the now different URLs): http://webcache.googleusercontent.com/search?q=cache:5M4G1hv_9ZYJ:www.flugtraeumer.de/termine+&cd=2&hl=de&ct=clnk&gl=de&client=firefox-b

    This issue (double links in breadcrumb) is very typical for Enfold:
    https://www.google.de/search?q=enfold+double+breadcrumb&ie=utf-8&oe=utf-8&client=firefox-b&gfe_rd=cr&dcr=0&ei=LJDQWr3dHYeT8Qewmo3YDA

    I know that there is one or some lines to add in functions.php to solve things like this.
    Please provide us with that
    Thanks danny

    #943324

    Hi,

    Thank you for the update. Did you add any filter for the breadcrumbs in the functions.php file? Please provide the login details in the private field.

    Best regards,
    Ismael

    #943653

    Hello
    There is absolutely nothing special in the functions.php and as i already said – its a well known typical Enfold-issue

    Here is the function.php:

    <?php
    /*
    * Add your own functions here. You can also copy some of the theme functions into this file. 
    * WordPress will use those functions instead of the original functions then.
    */
    function enqueue_parent_theme_style() {
          wp_enqueue_style( 'parent-style', get_template_directory_uri().'/style.css' );
    }
    add_action( 'wp_enqueue_scripts', 'enqueue_parent_theme_style');
    
    /* Proper way to enqueue styles and scripts
     */
    function theme_name_scripts() {
    	wp_enqueue_style( 'style-name', get_stylesheet_uri() );
    }
    add_action( 'wp_enqueue_scripts', 'theme_name_scripts' );
    include 'shortcodes.php';

    Danny

    #944100

    and i forgot to say – this is the content of shortcode.php

    <?php
    
    ///////////////////////////////////////////////////////////////
    //
    //	Custom layout shortcodes
    //
    ///////////////////////////////////////////////////////////////
    
    $thirds = 0;
    
    // Thirds
    add_shortcode('third', 'third');
    function third($atts, $content = null)
    {
    	global $thirds, $fourths;
    	
    	// check if an incompatible layout combination isn't in progress
    	$out = '';
    	if($fourths != 0){
    		$thirds = 0;
    		$fourths = 0;
    		$out = '<div class="clear"></div>';
    	}
    	
    	$thirds++;
    
    	if($content == null) return '';
    	
    	$class = 'layout-third';
    
    	if($thirds == 3) $class .= ' layout-last';
    	
    	$out .= '<div class="'.$class.'">';
    	$out .= do_shortcode($content);
    	$out .= '</div>';
    	
    	if($thirds == 3){
    		$out .= '<div class="clear"></div>';
    		$thirds = 0;
    	}
    	
    	return $out;
    }
    
    // Two Thirds
    add_shortcode('two-thirds', 'two_thirds');
    function two_thirds($atts, $content = null)
    {
    	global $thirds, $fourths;
    	
    	// check if an incompatible layout combination isn't in progress
    	$out = '';
    	if($fourths != 0 || $thirds > 2){
    		$thirds = 0;
    		$fourths = 0;
    		$out = '<div class="clear"></div>';
    	}
    	
    	$thirds += 2;
    
    	if($content == null) return '';
    	
    	$class = 'layout-two-thirds';
    	
    	if($thirds == 3) $class .= ' layout-last';
    	
    	$out .= '<div class="'.$class.'">';
    	$out .= do_shortcode($content);
    	$out .= '</div>';
    	
    	if($thirds == 3){
    		$out .= '<div class="clear"></div>';
    		$thirds = 0;
    	}
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    
    $fourths = 0;
    // Halves
    add_shortcode('half', 'half');
    function half($atts, $content = null)
    {
    	global $thirds, $fourths;
    	
    	// check if an incompatible layout combination isn't in progress
    	$out = '';
    	if($thirds != 0 || $fourths > 2){
    		$thirds = 0;
    		$fourths = 0;
    		$out = '<div class="clear"></div>';
    	}
    	
    	$fourths += 2;
    
    	if($content == null) return '';
    	
    	$class = 'layout-half';
    	
    	if($fourths == 4) $class .= ' layout-last';
    	
    	$out .= '<div class="'.$class.'">';
    	$out .= do_shortcode($content);
    	$out .= '</div>';
    	
    	if($fourths == 4){
    		$out .= '<div class="clear"></div>';
    		$fourths = 0;
    	}
    	
    	return $out;
    }
    
    // Fourths
    add_shortcode('fourth', 'fourth');
    function fourth($atts, $content = null)
    {
    	global $thirds, $fourths;
    	
    	// check if an incompatible layout combination isn't in progress
    	$out = '';
    	if($thirds != 0){
    		$thirds = 0;
    		$fourths = 0;
    		$out = '<div class="clear"></div>';
    	}
    	
    	$fourths++;
    
    	if($content == null) return '';
    	
    	$class = 'layout-fourth';
    	
    	if($fourths == 4) $class .= ' layout-last';
    	
    	$out .= '<div class="'.$class.'">';
    	$out .= do_shortcode($content);
    	$out .= '</div>';
    	
    	if($fourths == 4){
    		$out .= '<div class="clear"></div>';
    		$fourths = 0;
    	}
    	
    	return $out;
    }
    
    // Three Fourths
    add_shortcode('three-fourths', 'three_fourths');
    function three_fourths($atts, $content = null)
    {
    	global $thirds, $fourths;
    	
    	// check if an incompatible layout combination isn't in progress
    	$out = '';
    	if($thirds != 0 || $fourths > 1){
    		$thirds = 0;
    		$fourths = 0;
    		$out = '<div class="clear"></div>';
    	}
    	
    	$fourths += 3;
    
    	if($content == null) return '';
    	
    	$class = 'layout-three-fourths';
    	
    	if($fourths == 4) $class .= ' layout-last';
    	
    	$out .= '<div class="'.$class.'">';
    	$out .= do_shortcode($content);
    	$out .= '</div>';
    	
    	if($fourths == 4){
    		$out .= '<div class="clear"></div>';
    		$fourths = 0;
    	}
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Buttons
    //
    ///////////////////////////////////////////////////////////////
    add_shortcode('button', 'button');
    function button($atts, $content = null)
    {
    	if($content == null) return '';
    	
    	extract(shortcode_atts(array(
    		'link' => '#',
    		'type' => ''
    	), $atts));
    	
    	$out = '<a href="'.$link.'" class="button '.$type.'">';
    	$out .= do_shortcode($content);
    	$out .= '</a>';
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	List styles
    //
    ///////////////////////////////////////////////////////////////
    add_shortcode('list', 'uds_list');
    function uds_list($atts, $content = null)
    {
    	if($content == null) return '';
    	
    	extract(shortcode_atts(array(
    		'type' => ''
    	), $atts));
    	
    	$out = '<div class="list '.$type.'">';
    	$out .= $content;
    	$out .= '</div>';
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Boxes
    //
    ///////////////////////////////////////////////////////////////
    add_shortcode('box', 'uds_box');
    function uds_box($atts, $content = null)
    {
    	if($content == null) return '';
    	
    	extract(shortcode_atts(array(
    		'type' => ''
    	), $atts));
    	
    	$out = '<div class="box '.$type.'">';
    	$out .= $content;
    	$out .= '</div>';
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Pullquotes
    //
    ///////////////////////////////////////////////////////////////
    add_shortcode('pullquote', 'pullquote');
    function pullquote($atts, $content = null)
    {
    	if($content == null) return '';
    	
    	extract(shortcode_atts(array(
    		'align' => 'left'
    	), $atts));
    	
    	$out = '<blockquote class="pullquote '.$align.'">';
    	$out .= $content;
    	$out .= '</blockquote>';
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Dividers
    //
    ///////////////////////////////////////////////////////////////
    add_shortcode('divider', 'divider');
    function divider($atts)
    {
    	$out = '<hr class="divider" />';
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Portfolio
    //
    ///////////////////////////////////////////////////////////////
    add_shortcode('portfolio', 'portfolio_shortcode');
    function portfolio_shortcode($atts, $content = null)
    {
    	extract(shortcode_atts(array(
    		'category' => 'Portfolio'
    	), $atts));
    	
    	if(is_numeric($cat)){
    		$params = 'cat='.$cat;
    	} else {
    		$params = 'category_name='.$category;
    	}
    	
    	$posts = query_posts($params);
    	
    	if(!have_posts()) return;
    	
    	$out = '<div id="portfolio">';
    	$n = 1;
    	while(have_posts()){
    		the_post();
    		$custom = get_post_custom();
    		$anim = $custom['animation'][0];
    		$anims = array('curve', 'up', 'down', 'left', 'top');
    		
    		if($anim == 'random') $anim = $anims[array_rand($anims)];
    		
    		$out .= '<div class="portfolio-item '. ($n%3 == 0 ? 'last' : '') .'">';
    		$out .= '<img src="'.get_first_image().'" alt="" />';
    		$out .= '<span class="anim">'. ((!empty($anim) && in_array($anim, $anims)) ? $anim : 'down' ).'</span>';
    		$out .= '<div class="portfolio-post">';
    		$out .= '<h3><a href="'.get_permalink().'">'.get_the_title().'</a></h3>';
    		$out .= get_the_excerpt();
    		$out .= '<br /><a href="'.get_permalink().'" class="read-more">Read More &raquo;</a>';
    		$out .= '</div>';
    		$out .= '</div>';
    		$n++;
    	}
    	
    	$out .= '</div>';
    	$out .= '<div class="clear"></div>';
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Inner slider
    //
    ///////////////////////////////////////////////////////////////
    add_shortcode('slider', 'slider_shortcode');
    function slider_shortcode($atts, $content = null)
    {
    	extract(shortcode_atts(array(
    		'delay' => 1000,
    		'height' => '200px'
    	), $atts));
    	
    	$matches = array();
    	$pattern = '@(https?://([-\w\.]+)+(:\d+)?(/([\w/_\-\.]*(\?\S+)?)?)?)@';
    	if(!preg_match_all($pattern, $content, $matches)){
    		return '';
    	}
    	$images = $matches[0];
    	
    	if(empty($images)) return '';
    	
    	$out = '<div class="inner-slider">';
    	$out .= '<span class="inner-slider-delay">'.$delay.'</span>';
    	$out .= '<span class="inner-slider-height">'.$height.'</span>';
    	
    	foreach($images as $image){
    		$out .= "<img src='".trim($image)."' alt='' />";
    	}
    	
    	$out .= '</div>';
    	$out .= '<div class="clear"></div>';
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Contact form
    //
    ///////////////////////////////////////////////////////////////
    
    add_shortcode('uds-contact-form', 'contact_form_shortcode');
    function contact_form_shortcode($atts, $content = null)
    {
    	extract(shortcode_atts(array(
    		'category' => 'Portfolio'
    	), $atts));
    	
    	$message = '';
    	$email = '';
    	$subject = '';
    	$text = '';
    	
    	if(!empty($_POST)){
    		$can_go = true;
    		$email = htmlentities2(stripslashes(trim($_POST['uds-email'])));
    		$subject = htmlentities2(stripslashes(trim($_POST['uds-subject'])));
    		$text = htmlentities2(stripslashes(trim($_POST['uds-text'])));
    		
    		if(isset($_POST['uds-email']) && $email == ''){
    			$message .= '<p class="error">The email field is empty</p>';
    			$can_go = false;
    		}
    		if(isset($_POST['uds-subject']) && $subject == ''){
    			$message .= '<p class="error">The subject field is empty</p>';
    			$can_go = false;
    		}
    		if(isset($_POST['uds-text']) && $text == ''){
    			$message .= '<p class="error">The message field is empty</p>';
    			$can_go = false;
    		}
    		
    		if($can_go && !is_email($email, true)){
    			$message .= '<p class="error">The email address is invalid</p>';
    			$can_go = false;
    		}
    		
    		if($can_go){
    			$to = get_option('uds-cf-recipient');
    			
    			$subj = get_option('uds-cf-subject-prefix') . ' ' . $subject;
    		
                $msg = "$email wrote:\n";
                $msg .= wordwrap($text, 80, "\n") . "\n\n";
                $msg .= "From website: " . get_bloginfo('name') . ' at ' . get_bloginfo('url') . "\n";
                $msg .= "IP: " . $_SERVER["REMOTE_ADDR"];
                
    			$headers = "MIME-Version: 1.0\n";
    			$headers .= "From: $name <$email>\n";
    			$headers .= "Content-Type: text/plain; charset=\"" . get_option('blog_charset') . "\"\n";
    			
    			wp_mail($to, $subj, $msg, $headers);
    			
    			$message .= '<p class="success">'.get_option('uds-cf-success-message').'</p>';
    		}
    	}
    	
    	$form = "
    		<form action='".get_permalink()."' method='post'>
    			<fieldset>
    		    	<div class='required'>
    		    		<label for='email'>E-mail:</label>
    		    		<input type='text' name='uds-email' id='email' value='$email' />
    		    	</div>
    		    	<div class='required'>
    		    		<label for='subject'>Subject:</label>
    		    		<input type='text' name='uds-subject' id='subject' value='$subject' />
    		    	</div>
    		    	<div class='required'>
    		    		<label for='text'>Message:</label>
    		    		<textarea name='uds-text' id='text'>$text</textarea>
    		    	</div>
    		    	<div class='clear'></div>
    		    	<div>
    		    		<button type='submit'>Submit question</button>
    		    	</div>
    		    </fieldset>
    		</form>
    	";
    	
    	if(get_option("uds-cf-show-on-success") != 'on'){
    		$form = '';
    	}
    	
    	$out = "
    		<div id='contact-form'>
    			<div id='message-container'>$message</div>
    			$form
    		</div>
    	";
    	
    	return $out;
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Youtube
    //
    ///////////////////////////////////////////////////////////////
    
    add_shortcode('youtube', 'youtube_shortcode');
    function youtube_shortcode($atts, $content = null)
    {
    	$link = substr($atts[0], 1);
    	echo '
    	<object width="425" height="355">
    	  <param name="movie" value="'.$link.'"></param>
    	  <param name="allowFullScreen" value="true"></param>
    	  <embed src="'.$link.'"
    	    type="application/x-shockwave-flash"
    	    width="425" height="355" 
    	    allowfullscreen="true"></embed>
    	</object>
    	';
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Google video
    //
    ///////////////////////////////////////////////////////////////
    
    add_shortcode('googlevideo', 'googlevideo_shortcode');
    function googlevideo_shortcode($atts, $content = null)
    {
    	$link = substr($atts[0], 1);
    	echo '
    	<object width="425" height="355">
    	  <param name="movie" value="'.$link.'"></param>
    	  <param name="allowFullScreen" value="true"></param>
    	  <embed src="'.$link.'"
    	    type="application/x-shockwave-flash"
    	    width="425" height="355" 
    	    allowfullscreen="true"></embed>
    	</object>
    	';
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Table from Table Creator
    //
    ///////////////////////////////////////////////////////////////
    
    add_shortcode('uds-table', 'table_shortcode');
    function table_shortcode($atts, $content = null)
    {
    	extract(shortcode_atts(array(
    		'name' => ''
    	), $atts));
    	
    	if(empty($name)){
    		echo "Table name must be set [uds-table name=\"Table\"]";
    		return;
    	}
    	
    	$tables = maybe_unserialize(get_option('uds-tables', array()));
    	
    	$table = $tables[$name];
    	
    	if(empty($table)){
    		echo "Table named $name is empty.";
    		return;
    	}
    	
    	echo "<table class='uds-table'>";
    	for($i = 0; $i < count($table['headerx']); $i++){
    		echo "<tr class='".$table['headery'][$i]."'>";
    		for($j = 0; $j < count($table['headery']); $j++){
    			echo "<td class='".$table['headerx'][$i] .' '. $table['headery'][$j] ."'>";
    			echo stripslashes($table['cell'][$i][$j]);
    			echo "</td>";
    		}
    		echo "</tr>";
    	}
    	echo "</table>";
    }
    
    ///////////////////////////////////////////////////////////////
    // 
    //	Dropcaps
    //
    ///////////////////////////////////////////////////////////////
    add_shortcode('dropcap', 'kriesi_dropcaps');
    
    function kriesi_dropcaps($atts, $content=null, $shortcodename ="")
    {	
    	
    	// add divs to the content
    	$return .= '<span class="'.$shortcodename.' ie6fix">';
    	$return .= do_shortcode($content);
    	$return .= '</span>';	
    	
    
    	return $return;
    }
    ?>
    #944719

    Hi,

    Please post us your login credentials (in the “private data” field), so we can take a look at your backend.

    1. Install and activate ” Temporary Login Without Password “.
    2. Go to ” Users > Temporary Logins ” on the left-side menu.
    3. Click ” Create New “.
    4. Add the email address for the account ( you can use (Email address hidden if logged out) ), as well as the ” Role ” making that the highest possible and the expiry about four days
      ( do be sure that we have enough time to debug ).
    5. Click ” Submit “.
    6. You’ll now have a temporary account. Please provide us here in the private section the URL, so we can login and help you out.

    When your issue is fixed, you can always remove the plugin!
    If you prefer to not use the plugin, you can manually create a admin user and post the login credentials in the “private data” field.

    Best regards,
    Nikko

    #944758

    Hi
    sorry, but we cant give you admin access.
    But as this is a well known and common Enfold issue i am pretty much sure that you got a sulation without login.

    Please let me know what alse you need.
    Kind regards danny

    #944893

    Hi Danny,

    Okay, can you try add this php code at the bottom of your functions.php code:

    if(!function_exists('avia_events_breadcrumb'))
    {
    	add_filter('avia_breadcrumbs_trail','avia_events_breadcrumb');
    
    	function avia_events_breadcrumb($trail)
    	{ 
    		global $avia_config, $wp_query;
    		
    		if(is_404() && isset($wp_query) && !empty($wp_query->tribe_is_event))
    		{
    			$events = __('Events','avia_framework');
    			$events_link = '<a href="'.tribe_get_events_link().'">'.$events.'</a>';
    			$last = array_pop($trail);
    			$trail[] = $events_link;
    			$trail['trail_end'] = __('No Events Found','avia_framework');
    		}
    		
    		if((isset($avia_config['currently_viewing']) && $avia_config['currently_viewing'] == 'events') || tribe_is_month() || get_post_type() === Tribe__Events__Main::POSTTYPE || is_tax(Tribe__Events__Main::TAXONOMY) )
    		{	
    			$events = __('Events','avia_framework');
    			$events_link = '<a href="'.tribe_get_events_link().'">'.$events.'</a>';
    			
    			if(is_tax(Tribe__Events__Main::TAXONOMY) )
    			{
    				$last = array_pop($trail);
    				$trail[] = $events_link;
    				$trail[] = $last;
    			}
    			else if(tribe_is_month() || (tribe_is_upcoming() && !is_singular())) 
    			{
    				$trail[] = $events_link;
    			}
    			else if(tribe_is_event()) 
    			{
    				unset($trail[1]);
    				$last = array_pop($trail);
    				$trail[] = $events_link;
    				$trail[] = $last;
    			}
    
    			if(isset($avia_config['events_trail'] )) $trail = $avia_config['events_trail'] ;
    		}
    
    		return $trail;
    	}
    
    }

    or you can copy the code here: https://pastebin.com/pBuKyqF1
    Let us know if this helps.

    Best regards,
    Nikko

    #947913

    Hi Nikko
    it did only help for the posts and the tags:

    It did not help here (still double breadcrumb):
    http://www.flugtraeumer.de/events

    Kind regards Danny

    #948782

    Hi Danny,

    Can you try to change this part of the code I gave:

    else if(tribe_is_month() || (tribe_is_upcoming() && !is_singular())) 
        {
    	$trail[] = $events_link;
        }

    to:

    else if(tribe_is_month() || (tribe_is_upcoming() && !is_singular())) 
        {
    	//$trail[] = $events_link;
        }

    Hope this helps :)

    Best regards,
    Nikko

    #949097

    Hallo Nikko
    yes – that did the job.
    Thank you very much.
    kind regards Danny

    #949795

    Hi Danny,

    Glad that we could help. :)
    Please feel free to comeback if you need further assistance.
    Thanks for using Enfold and have a great day!

    Best regards,
    Nikko

Viewing 13 posts - 1 through 13 (of 13 total)
  • The topic ‘Double URLs in Breadcrumb’ is closed to new replies.