Forum Replies Created

Viewing 15 replies - 136 through 150 (of 173 total)
  • Forum: Fixing WordPress
    In reply to: WordPress error
    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    @tylerthedude its was all plugins deactivated when i made the test

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    @gagan0123
    when i start prebuild pages my site works very very hard and i thought the timeout is the problem but after i spoke with the hosting they answer that i have something using too many ram and cpu i had before 1gb ram and was working find but suddenly everything changed
    i install a plugin to show the memory usage and this is the results please have a look : this is on wordpress
    Memory: 44 of 512 MB (9%) | WP LIMIT: 256 MB | PHP 7.3.16 @64BitOS version 5.4
    and at the same moment this is on cpanle
    Physical Memory Usage
    1.81 GB / 2.2 GB (82.3%)
    its normal like this ? my cache plugin not working i have tired to rename Plugins folder to stop them to work and nothing memory usage the same i tried to change theme also the same i cleaned database files and optimise them and still the same.
    i cant find which the things which consume all these memory

    • This reply was modified 4 years, 10 months ago by mohdaljaraba.
    • This reply was modified 4 years, 10 months ago by mohdaljaraba.
    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    @gagan0123 i deactivate all plugins and theme but still the same the 2nd step not really i can check it

    Forum: Fixing WordPress
    In reply to: Redirects
    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    hello @carike ill contact them thank you

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    I have downgrade to version 5.1.4 and everything works fine even faster ,Is there a connection if my theme doesn’t support wordpress new version ?

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    Thank you very much its working

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    its working thank you

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    @amboutwe this is the what i found on theme markup , its possible to change it just for there or need to add more , i tried to edit data-vocabulary.org schema to schema.org but but not woking

    <?php
    /**
     * Display breadcrumbs for posts, pages, archive page with the microdata that search engines understand
     *
     * @see https://support.google.com/webmasters/bin/answer.py?hl=en&answer=185417
     *
     * @param array|string $args
     */
    function mrbara_breadcrumbs( $args = '' ) {
    	$args = wp_parse_args( $args, array(
    		'separator'         => '<i class="ion-ios-arrow-right"></i>',
    		'home_class'        => 'home',
    		'before'            => '<span class="before">' . esc_html__( 'You are here: ', 'mrbara' ) . '</span>',
    		'before_item'       => '',
    		'after_item'        => '',
    		'taxonomy'          => 'category',
    		'display_last_item' => true,
    		'show_on_front'     => true,
    		'labels'            => array(
    			'home'      => esc_html__( 'Home', 'mrbara' ),
    			'archive'   => esc_html__( 'Archives', 'mrbara' ),
    			'blog'      => esc_html__( 'Blog', 'mrbara' ),
    			'search'    => esc_html__( 'Search results for', 'mrbara' ),
    			'not_found' => esc_html__( 'Not Found', 'mrbara' ),
    			'portfolio' => esc_html__( 'Portfolio', 'mrbara' ),
    			'author'    => esc_html__( 'Author Archives:', 'mrbara' ),
    			'day'       => esc_html__( 'Daily Archives:', 'mrbara' ),
    			'month'     => esc_html__( 'Monthly Archives:', 'mrbara' ),
    			'year'      => esc_html__( 'Yearly Archives:', 'mrbara' ),
    		),
    	) );
    
    	$args = apply_filters( 'mrbara_breadcrumbs_args', $args );
    
    	if ( is_front_page() && ! $args['show_on_front'] ) {
    		return;
    	}
    
    	$items = array();
    
    	// HTML template for each item
    	$item_tpl      = $args['before_item'] . '
    		<span itemscope itemtype="https://data-vocabulary.org/Breadcrumb">
    			<a href="%s" itemprop="url"><span itemprop="title">%s</span></a>
    		</span>
    	' . $args['after_item'];
    	$item_text_tpl = $args['before_item'] . '
    		<span itemscope itemtype="https://data-vocabulary.org/Breadcrumb">
    			<span itemprop="title">%s</span>
    		</span>
    	' . $args['after_item'];
    
    	// Home
    	if ( ! $args['home_class'] ) {
    		$items[] = sprintf( $item_tpl, get_home_url(), $args['labels']['home'] );
    	} else {
    		$items[] = sprintf(
    			'%s<span itemscope itemtype="https://data-vocabulary.org/Breadcrumb">
    				<a class="%s" href="%s" itemprop="url"><span itemprop="title">%s</span></a>
    			</span>%s',
    			$args['before_item'],
    			$args['home_class'],
    			get_home_url(),
    			$args['labels']['home'],
    			$args['after_item']
    		);
    	}
    
    	// Front page
    	if ( is_front_page() ) {
    		$items   = array();
    		$items[] = sprintf( $item_text_tpl, $args['labels']['home'] );
    	}
    	// Blog
    	elseif ( is_home() && ! is_front_page() ) {
    		$items[] = sprintf(
    			$item_text_tpl,
    			get_the_title( get_option( 'page_for_posts' ) )
    		);
    	}
    	// Single
    	elseif ( is_single() ) {
    		// Terms
    
    		$taxonomy = $args['taxonomy'];
    
    		if( is_singular( 'portfolio_project' ) ) {
    			$taxonomy = 'portfolio_category';
    		}
    
    		if( is_singular( 'portfolio_project' ) ) {
    			$taxonomy = 'portfolio_category';
    		}
    
    		$terms   = get_the_terms( get_the_ID(),  $taxonomy );
    		if( $terms ) {
    			$term    = current( $terms );
    			$terms   = mrbara_get_term_parents( $term->term_id, $taxonomy );
    			$terms[] = $term->term_id;
    
    			foreach ( $terms as $term_id ) {
    				$term    = get_term( $term_id, $taxonomy );
    				$items[] = sprintf( $item_tpl, get_term_link( $term, $taxonomy ), $term->name );
    			}
    		}
    
    		if ( $args['display_last_item'] ) {
    			$items[] = sprintf( $item_text_tpl, get_the_title() );
    		}
    	}
    	// Page
    	elseif ( is_page() ) {
    		if( (function_exists( 'is_cart' ) && is_cart() ) || (function_exists( 'is_checkout' ) && is_checkout()) ) {
    			if( $page_id = get_option( 'woocommerce_shop_page_id' ) )
    			$items[] = sprintf( $item_tpl, esc_url(get_permalink( $page_id )), get_the_title( $page_id ) );
    
    		} else {
    			$pages = mrbara_get_post_parents( get_queried_object_id() );
    			foreach ( $pages as $page )
    			{
    				$items[] = sprintf( $item_tpl, esc_url(get_permalink( $page )), get_the_title( $page ) );
    			}
    		}
    
    		if ( $args['display_last_item'] )
    			$items[] = sprintf( $item_text_tpl, get_the_title() );
    	} elseif ( function_exists( 'is_shop' ) && is_shop() ) {
    		$title = get_the_title( get_option( 'woocommerce_shop_page_id' ) );
    		if ( $args['display_last_item'] ) {
    			$items[] = sprintf( $item_text_tpl, $title );
    		}
    	} elseif ( is_tax() || is_category() || is_tag() ) {
    		$current_term = get_queried_object();
    		$terms        = mrbara_get_term_parents( get_queried_object_id(), $current_term->taxonomy );
    
    		if( $terms ) {
    			foreach ( $terms as $term_id )
    			{
    				$term    = get_term( $term_id, $current_term->taxonomy );
    				$items[] = sprintf( $item_tpl, get_term_link( $term, $current_term->taxonomy ), $term->name );
    			}
    		}
    
    		if ( $args['display_last_item'] )
    			$items[] = sprintf( $item_text_tpl, $current_term->name );
    	}
    	elseif ( is_post_type_archive( 'portfolio_project' ) ) {
    		$items[] = sprintf( $item_text_tpl, $args['labels']['portfolio'] );
    	}
    	// Search
    	elseif ( is_search() ) {
    		$items[] = sprintf( $item_text_tpl, $args['labels']['search'] . ' &quot;' . get_search_query() . '&quot;' );
    	}
    	// 404
    	elseif ( is_404() ) {
    		$items[] = sprintf( $item_text_tpl, $args['labels']['not_found'] );
    	}
    	// Author archive
    	elseif ( is_author() ) {
    		// Queue the first post, that way we know what author we're dealing with (if that is the case).
    		the_post();
    		$items[] = sprintf(
    			$item_text_tpl,
    			$args['labels']['author'] . ' <span class="vcard"><a class="url fn n" href="' . get_author_posts_url( get_the_author_meta( 'ID' ) ) . '" title="' . esc_attr( get_the_author() ) . '" rel="me">' . get_the_author() . '</a></span>'
    		);
    		rewind_posts();
    	}
    	// Day archive
    	elseif ( is_day() ) {
    		$items[] = sprintf(
    			$item_text_tpl,
    			sprintf( esc_html__( '%s %s', 'mrbara' ), $args['labels']['day'], get_the_date() )
    		);
    	}
    	// Month archive
    	elseif ( is_month() ) {
    		$items[] = sprintf(
    			$item_text_tpl,
    			sprintf( esc_html__( '%s %s', 'mrbara' ), $args['labels']['month'], get_the_date( 'F Y' ) )
    		);
    	}
    	// Year archive
    	elseif ( is_year() ) {
    		$items[] = sprintf(
    			$item_text_tpl,
    			sprintf( esc_html__( '%s %s', 'mrbara' ), $args['labels']['year'], get_the_date( 'Y' ) )
    		);
    	}
    	// Archive
    	else {
    		$items[] = sprintf(
    			$item_text_tpl,
    			$args['labels']['archive']
    		);
    	}
    
    	echo  implode( $args['separator'], $items );
    }
    
    /**
     * Searches for term parents' IDs of hierarchical taxonomies, including current term.
     * This function is similar to the WordPress function get_category_parents() but handles any type of taxonomy.
     * Modified from Hybrid Framework
     *
     * @param int|string    $term_id  The term ID
     * @param object|string $taxonomy The taxonomy of the term whose parents we want.
     *
     * @return array Array of parent terms' IDs.
     */
    function mrbara_get_term_parents( $term_id = '', $taxonomy = 'category' ) {
    	// Set up some default arrays.
    	$list = array();
    
    	// If no term ID or taxonomy is given, return an empty array.
    	if ( empty( $term_id ) || empty( $taxonomy ) ) {
    		return $list;
    	}
    
    	do {
    		$list[] = $term_id;
    
    		// Get next parent term
    		$term    = get_term( $term_id, $taxonomy );
    		$term_id = $term->parent;
    	} while ( $term_id );
    
    	// Reverse the array to put them in the proper order for the trail.
    	$list = array_reverse( $list );
    	array_pop( $list );
    
    	return $list;
    }
    
    /**
     * Gets parent posts' IDs of any post type, include current post
     * Modified from Hybrid Framework
     *
     * @param int|string $post_id ID of the post whose parents we want.
     *
     * @return array Array of parent posts' IDs.
     */
    function mrbara_get_post_parents( $post_id = '' ) {
    	// Set up some default array.
    	$list = array();
    
    	// If no post ID is given, return an empty array.
    	if ( empty( $post_id ) ) {
    		return $list;
    	}
    
    	do {
    		$list[] = $post_id;
    
    		// Get next parent post
    		$post    = get_post( $post_id );
    		$post_id = $post->post_parent;
    	} while ( $post_id );
    
    	// Reverse the array to put them in the proper order for the trail.
    	$list = array_reverse( $list );
    	array_pop( $list );
    
    	return $list;
    }
    • This reply was modified 5 years, 1 month ago by mohdaljaraba.
    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    and this is how it looking on google
    https://prnt.sc/qq3nto

    • This reply was modified 5 years, 1 month ago by mohdaljaraba.
    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    Hi @amandasjackson thank you , i mean to show it under long description on the same page .

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    i active “also aggregate inline JS” and the cache size in hours around 1gb its good ?
    and is there a way to auto delete it ?

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    beautysecrets.ro

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    Hi frank thank you for your fast respond , and these https://prnt.sc/qisq11 https://prnt.sc/qisqdh its can be fixed ? and why even we get high score still the loading time its more than 5s every time is there missing settings should be done !

    best regards

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    Theres no ready code for this ?

    Thread Starter mohdaljaraba

    (@mohdaljaraba)

    on page speed i have this results
    https://prnt.sc/qa14pw
    https://prnt.sc/qa15b2
    its about the same thing ?

Viewing 15 replies - 136 through 150 (of 173 total)