Viewing 29 results - 31 through 59 (of 59 total)
  • Author
    Search Results
  • #595889

    Topic: Page title stuck

    in forum Enfold
    david-potter
    Participant

    Hi.

    When editing my Frontpage, I find that changing my blog title, blog description (in customizer) or page title (on page edit screen) make no impact on the html <title> attribute.

    I did a little troubleshooting, and found that this line of code is changing it to “intoto systems”. Don’t know why.

    
    php/function-set-avia-frontend.php:
    if(!function_exists('avia_set_title_tag'))
    <snip>
           $title = apply_filters('avf_title_tag', $title, wp_title('', false));
    </snip>
        }
    }
    
    

    Can you help me figure out why this is happening, and how I might be able to prevent this from occurring? is it safe for me to simply comment out that line?

    Thanks,
    David

    • This topic was modified 9 years, 10 months ago by david-potter. Reason: edited code snippet to focus on the specific line that is altering the title

    Hi!

    The theme has its own filter for situation like this and its called “avf_title_tag”. You can use that to modify the title according to your needs. Example: https://kriesi.at/support/topic/duplicated-titles-w-yoast-seo-plugin/#post-367661

    Regards,
    Ismael

    #536538

    Hi!

    Please undo the changes you made in header.php file and add following code to Functions.php file in Appearance > Editor

    add_filter('avf_title_tag','avia_new_title');
    function avia_new_title() {
    if(is_home()){
    $title = get_bloginfo('name');
    }
    return $title; 
    }

    Regards,
    Yigit

    #529089

    In reply to: Title Problem

    Hi boscotwcheung!

    Thank you for using Enfold.

    You can use the “avf_title_tag” filter or install the Yoast SEO plugin to override the theme’s html title settings: https://wordpress.org/plugins/wordpress-seo/

    Examples of the filter:

    https://kriesi.at/support/topic/wrong-site-name-in-browser-tab/#post-504651
    https://kriesi.at/support/search/avf_title_tag/?avia_filter_search=yes&avia_search_forums=all&avia_search_dates=all&avia_search_include=no

    Regards,
    Ismael

    #506470
    Vincent
    Participant

    We have noted that there are duplicate titles appearing in Google’s search results for some of our pages.
    At first we thought this may be an issue with Yoast plugin and we followed various advice about rectifying this and performed the following in functions.php

    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle)
    {
    return $wptitle;
    }
    

    This also did not solve the problem. We then changed the title output in header.php to:
    <title><?php wp_title(''); ?></title>
    This also has not helped and the problem remains. You cannot visually see or find the extra words it keeps adding to the title. But it shows up on some important pages in Google’s search.

    #504651

    Hi Munford!

    Please add following code to Functions.php file in Appearance > Editor

    add_filter('avf_title_tag','avia_new_title');
    function avia_new_title() {
    if(is_home()){
    $title = get_bloginfo('name');
    }
    return $title; 
    }

    Regards,
    Yigit

    #474800
    Carsten
    Participant

    Hi,

    searched the whole forum and Google, but didn’t find a solution.

    Enfold outputs the title I put into the Yoast widget on pages. E.g. [PAGE TITLE]

    But it doesn’t output the title structure set in Yoast settings. E.g. [PAGE TITLE] – [SITE TITLE]

    And this filter does nothing – found in an older thread:

    
    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle) {
      return $wptitle;
    }
    

    Is there a new filter available?

    #468039

    Hi!

    Please add following code to Functions.php file as well

    add_filter('avf_title_tag','avia_new_title_blog');
    function avia_new_title_blog() {
    if(is_single())
    {
    $title = get_the_title(). ' | ' get_bloginfo('name');
    }
    return $title; 
    }

    Regards,
    Yigit

    #466593

    Hey heavymetaller!

    Please add following code to Functions.php file in Appearance > Editor

    add_filter('avf_title_tag','avia_new_title');
    function avia_new_title() {
    if(is_front_page())
    {
    $title = get_bloginfo('name');
    }
    return $title; 
    }

    You can find image sizes in Functions.php file

    $avia_config['imgSize']['widget'] 			 	= array('width'=>36,  'height'=>36);						// small preview pics eg sidebar news
    $avia_config['imgSize']['square'] 		 	    = array('width'=>180, 'height'=>180);		                 // small image for blogs
    $avia_config['imgSize']['featured'] 		 	= array('width'=>1500, 'height'=>430 );						// images for fullsize pages and fullsize slider
    $avia_config['imgSize']['featured_large'] 		= array('width'=>1500, 'height'=>630 );						// images for fullsize pages and fullsize slider
    $avia_config['imgSize']['extra_large'] 		 	= array('width'=>1500, 'height'=>1500 , 'crop' => false);	// images for fullscrren slider
    $avia_config['imgSize']['portfolio'] 		 	= array('width'=>495, 'height'=>400 );						// images for portfolio entries (2,3 column)
    $avia_config['imgSize']['portfolio_small'] 		= array('width'=>260, 'height'=>185 );						// images for portfolio 4 columns
    $avia_config['imgSize']['gallery'] 		 		= array('width'=>845, 'height'=>684 );						// images for portfolio entries (2,3 column)
    $avia_config['imgSize']['magazine'] 		 	= array('width'=>710, 'height'=>375 );						// images for magazines
    $avia_config['imgSize']['masonry'] 		 		= array('width'=>705, 'height'=>705 , 'crop' => false);		// images for fullscreen masonry
    $avia_config['imgSize']['entry_with_sidebar'] 	= array('width'=>845, 'height'=>321);		            	// big images for blog and page entries
    $avia_config['imgSize']['entry_without_sidebar']= array('width'=>1210, 'height'=>423 );						// images for fullsize pages and fullsize slider
    $avia_config['imgSize'] = apply_filters('avf_modify_thumb_size', $avia_config['imgSize']);

    If you would like to change them, please do not forget to regenerate thumbnails using this plugin afterwards – https://wordpress.org/plugins/regenerate-thumbnails/

    Cheers!
    Yigit

    #423932

    Hi!

    Please try using a plugin such as this one – https://wordpress.org/plugins/wordpress-seo/ to have more control over page titles.

    Or you can add following code to Functions.php file in Appearance > Editor

    add_filter('avf_title_tag','avia_new_title');
    function avia_new_title() {
    $title = "Enfold | Here is my custom tag";
    return $title; 
    }

    Best regards,
    Yigit

    • This reply was modified 10 years, 9 months ago by Yigit.
    #405959

    Hi jamietroost!

    Please add following code to Functions.php file in Appearance > Editor

    add_filter('avf_title_tag','avia_new_title');
    function avia_new_title() {
    $title = get_bloginfo('name');
    return $title; 
    }

    Best regards,
    Yigit

    #402764

    Hi Cindy

    Please add following code to Functions.php file of your child theme in Appearance > Editor

    add_filter('avf_title_tag','avia_new_title');
    function avia_new_title() {
    $title = get_bloginfo('name');
    return $title; 
    }

    You no longer need to edit theme files :)

    Best regards,
    Yigit

    #367661

    Hi!

    Try to disable the title & meta settings or reset it to default then add this on functions.php:

    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle)
    {
    if(is_front_page()) { 
    $title = get_bloginfo('name');
    }
    return $title;
    }
    

    Regards,
    Ismael

    #367043
    SobeIT
    Participant

    We have a static homepage setup within WordPress and we just installed the Yoast SEO plugin on our site. The site is now displaying SITE TITLE | HOMEPAGE TITLE (which are both named the same, so we get duplication…).

    I searched through the forums here and found this code (which was posted in another thread about a similar issue…):

    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle)
    {
    return $wptitle;
    }

    We placed the code at the bottom of functions.php — however it doesn’t seem to have changed anything for us… Basically we just want to remove the Homepage Title, so that its simply SITE TITLE when on the homepage…. is this possible?

    THANKS!!

    • This topic was modified 11 years, 1 month ago by SobeIT.
    #341925

    In reply to: Browser tab title

    Hi bicounet!

    Please go to Enfold/framework/php folder and open function-set-avia-frontend.php file and edit

    function avia_set_title_tag()
        {
            $title = get_bloginfo('name').' | ';
            $title .= (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
    
            $title = apply_filters('avf_title_tag', $title, wp_title('', false));
    
            return $title;
        }

    Regards,
    Yigit

    #297257

    Hi Animationink!

    Insert this code into the child theme functions.php or enfold/functions.php file:

    
    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle)
    {
    $title = str_replace('|', "", $title);
    return $title;
    }
    

    Regards,
    Peter

    #271202

    Hi Michael!

    Tbh I’m not sure if we want to add this to the core files. We’ll discuss this with Kriesi. I recommend to use a filter and your child theme functions.php to modify the output – then you don’t need to customize the header.php file. Use the filter like:

    
    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle) {
    	$page = get_query_var( 'paged' ) ? get_query_var( 'paged' ) : get_query_var( 'page' );
    	if(!empty($page) && $page > 1) $title .= ' - ' . $page;
            return $title;
    }
    

    Best regards,
    Peter

    Hi!

    Please insert this code into your child theme functions.php or enfold/functions.php file:

    
    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle) {
            if(!is_front_page() && !is_home()) $title = get_bloginfo('name').' | '.$wptitle;
            return $title;
    }
    

    Best regards,
    Peter

    Hey!

    That should not be happening, i tested on my install and it worked fine, make sure it’s exactly like this:

    if(!function_exists('avia_set_title_tag'))
    {
        /**
         * generates the html page title
         * @return string the html page title
         */
        function avia_set_title_tag()
        {
            
            $title = (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
    		$title .= ' | '.get_bloginfo('name');
    
            $title = apply_filters('avf_title_tag', $title, wp_title('', false));
    
            return $title;
        }
    }

    I tweaked the position of the pipe separator.

    Do you have access to your PHP log?

    Cheers!
    Josue

    In the file mentioned, change:

    if(!function_exists('avia_set_title_tag'))
    {
        /**
         * generates the html page title
         * @return string the html page title
         */
        function avia_set_title_tag()
        {
            $title = get_bloginfo('name').' | ';
            $title .= (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
    
            $title = apply_filters('avf_title_tag', $title, wp_title('', false));
    
            return $title;
        }
    }

    To:

    if(!function_exists('avia_set_title_tag'))
    {
        /**
         * generates the html page title
         * @return string the html page title
         */
        function avia_set_title_tag()
        {
            $title = (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
            $title .= get_bloginfo('name').' | ';
    
            $title = apply_filters('avf_title_tag', $title, wp_title('', false));
    
            return $title;
        }
    }

    Best regards,
    Josue

    You are right, the workaround provided can’t be applied in the latest version of Enfold, now you’d need to edit:
    /framework/php/function-set-avia-frontend.php, line 396-411:

    if(!function_exists('avia_set_title_tag'))
    {
        /**
         * generates the html page title
         * @return string the html page title
         */
        function avia_set_title_tag()
        {
            $title = get_bloginfo('name').' | ';
            $title .= (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
    
            $title = apply_filters('avf_title_tag', $title, wp_title('', false));
    
            return $title;
        }
    }
    

    What structure would you like to have?

    Best regards,
    Josue

    #261575

    Hey webfordj!

    Thank you for visiting the support forum!

    Please add this on functions.php to remove the separator:

    add_filter('avf_title_tag', 'avf_change_title_tag');
    
    function avf_change_title_tag($title) {
    	$title = get_bloginfo('name') . ' ';
        $title .= (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
    
    	return $title;
    }
    

    Cheers!
    Ismael

    #260796

    Hi falki!

    Füge diesen Code in die enfold/functions.php oder deine child theme functions.php ein:

    
    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle) {
    	$title = str_replace('|', '', $title );
            return $title;
    }
    

    Regards,
    Peter

    #220763

    Hey Serge!

    You can add this to your functions.php file to filter the title as needed:

    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle) {
    	    
    
    	    $title = get_bloginfo('name').' | ';
            $title .= (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
    
            return $title;
    }

    Cheers!
    Devin

    Hi,

    1.) My bad, please try this:

    add_filter('avf_title_tag','new_avf_title_tag');
    function new_avf_title_tag($title)
    {
    if ( is_front_page() ) {
    $title = get_bloginfo('name').'';
    return $title;
    } else {
    $title = get_bloginfo('name').' | ';
    $title .= (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
    return $title;
    }
    }

    2.) Edit footer.php, find this code:

    <span class='copyright'><?php echo $copyright . $kriesi_at_backlink; ?></span>

    Below, add this code:

    <?php

    $social_args = array('outside'=>'ul', 'inside'=>'li', 'append' => '');

    echo avia_social_media_icons($social_args);

    ?>

    Edit custom.css or Quick CSS, add this code:

    #socket .social_bookmarks {
    float: right;
    }

    #header_meta .social_bookmarks {
    display: none;
    }

    Regards,

    Ismael

    Hi,

    1.) Please replace the code with this:

    add_filter('avf_title_tag','new_avf_title_tag');
    function new_avf_title_tag($title)
    {
    if ( is_home() ) {
    $title = get_bloginfo('name').'';
    return $title;
    } else {
    $title = get_bloginfo('name').' | ';
    $title .= (is_front_page()) ? get_bloginfo('description') : wp_title('', false);
    $title = apply_filters('avf_title_tag', $title, wp_title('', false));

    return $title;
    }
    }

    2.) You can use wordpress social media plugins like addthis and sharethis.

    Regards,

    Ismael

    #131951

    In reply to: Meta Title

    I think I’ve found the issue:

    function avia_set_title_tag()

    {

    $title = get_bloginfo(‘name’).’ | ‘;

    $title .= (is_front_page()) ? get_bloginfo(‘description’) : wp_title(”, false);

    $title = apply_filters(‘avf_title_tag’, $title, wp_title(”, false));

    return $title;

    }

    Your theme is fantastic!!!

    However, from an SEO point of view it’s generally considered best practice to go for 100% keyword prominence in the title tag.

    EG:

    Plumber London | Plumbers.Com

    is better than

    Plumbers.Com | Plumber London

    because each page will start with a unique phrase and if designed right would have 100% keyword prominence.

    What is the best way to fix this?

    Do I need to create a child theme?

    Kind Regards,

    Adrian

    PS: If it were me I would upgrade the theme and then add as a selling point that…

    Our title tags are designed for 100% keyword prominence.

    Hi,

    1.) Edit functions.php, add this code:

    add_filter('avf_title_tag','new_avf_title_tag');
    function new_avf_title_tag($title)
    {
    $title = get_bloginfo('name').'';
    return $title;
    }

    2.) Edit footer.php, find this code:

    echo "<div class='sub_menu_socket'>";
    $args = array('theme_location'=>'avia3', 'fallback_cb' => '', 'depth'=>1);
    wp_nav_menu($args);
    echo "</div>";

    Replace it with:

    $social_args = array('outside'=>'ul', 'inside'=>'li', 'append' => '');

    echo avia_social_media_icons($social_args);

    echo "<div class='sub_menu_socket'>";
    $args = array('theme_location'=>'avia3', 'fallback_cb' => '', 'depth'=>1);
    wp_nav_menu($args);
    echo "</div>";

    Add this on your custom.css or Quick CSS

    #socket .social_bookmarks {
    position: relative;
    float: right;
    }

    Regards,

    Ismael

    #123651

    In reply to: SEO site title

    Add following code to functions.php (at the very bottom):

    add_filter('avf_title_tag', 'avia_change_title_tag', 10, 2);
    function avia_change_title_tag($title, $wptitle)
    {
    return $wptitle;
    }

    Enfold will then use the result of “wp_title()” and Yoast SEO hooks into this function to generate the seo optimized title.

Viewing 29 results - 31 through 59 (of 59 total)