Pedro
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Unwanted on redirected pages.Thank you for pointing out the cause!
Forum: Fixing WordPress
In reply to: Unwanted on redirected pages.For anyone facing a similar issue:
I’ve managed to solve it (so it doesn’t add the “noindex” nor “nofollow” tags on filtered pages) and overcome the need for editing the plugin files everytime there’s an update by adding another code snippet to the end of my redirect function, so it becomes:
// Redirect product categories, attributes, and custom taxonomy ambiente to shop filtered page
add_action('template_redirect', 'custom_redirect_shop_filters');
function custom_redirect_shop_filters() {
if (is_product_category() || is_tax('ambiente') || is_tax('pa_mat-estrutura') || is_tax('pa_mat-acabamento-revestimento') || is_tax('faixa-em-promocao') || is_tax('faixa-pronta-entrega')) {
$term = get_queried_object();
$base = '/catalogo/?';
if ($term && $term->taxonomy === 'ambiente') {
$url = $base . '_ambiente=' . $term->slug;
} elseif ($term && $term->taxonomy === 'product_cat') {
$url = $base . '_categoria=' . $term->slug;
} elseif ($term && $term->taxonomy === 'faixa-em-promocao') {
$url = $base . '_em-promocao=' . $term->slug;
} elseif ($term && $term->taxonomy === 'faixa-pronta-entrega') {
$url = $base . '_pronta-entrega=' . $term->slug;
} elseif ($term && $term->taxonomy === 'pa_mat-estrutura') {
$url = $base . '_material-da-estrutura=' . $term->slug;
} elseif ($term && $term->taxonomy === 'pa_mat-acabamento-revestimento') {
$url = $base . '_material-do-acabamento-revestimento=' . $term->slug;
} else {
$url = wc_get_page_permalink('shop');
}
wp_safe_redirect($url);
exit;
}
}
// Prevent Filter Everything from adding noindex and nofollow tags in redirected filtered Shop page from respective Archive pages
// Function to start output buffering
function start_output_buffer() {
ob_start('remove_noindex_nofollow_meta_tags');
}
add_action('wp', 'start_output_buffer');
// Function to remove noindex, nofollow meta tags from the buffer
function remove_noindex_nofollow_meta_tags($buffer) {
$buffer = str_replace('<meta name="robots" content="noindex, nofollow">', '', $buffer);
return $buffer;
}
// Function to end output buffering and flush the buffer
function end_output_buffer() {
if (ob_get_length()) {
ob_end_flush();
}
}
add_action('shutdown', 'end_output_buffer');Thanks, Victor.
I’ve managed to remove both tags programatically, your help was indeed crucial.
For anyone facing a similar issue:
I’ve managed to solve it and overcome the need for editing the plugin files everytime there’s an update by adding another code snippet to the end of my redirect function, so it becomes:
// Redirect product categories, attributes, and custom taxonomy ambiente to shop filtered page
add_action('template_redirect', 'custom_redirect_shop_filters');
function custom_redirect_shop_filters() {
if (is_product_category() || is_tax('ambiente') || is_tax('pa_mat-estrutura') || is_tax('pa_mat-acabamento-revestimento') || is_tax('faixa-em-promocao') || is_tax('faixa-pronta-entrega')) {
$term = get_queried_object();
$base = '/catalogo/?';
if ($term && $term->taxonomy === 'ambiente') {
$url = $base . '_ambiente=' . $term->slug;
} elseif ($term && $term->taxonomy === 'product_cat') {
$url = $base . '_categoria=' . $term->slug;
} elseif ($term && $term->taxonomy === 'faixa-em-promocao') {
$url = $base . '_em-promocao=' . $term->slug;
} elseif ($term && $term->taxonomy === 'faixa-pronta-entrega') {
$url = $base . '_pronta-entrega=' . $term->slug;
} elseif ($term && $term->taxonomy === 'pa_mat-estrutura') {
$url = $base . '_material-da-estrutura=' . $term->slug;
} elseif ($term && $term->taxonomy === 'pa_mat-acabamento-revestimento') {
$url = $base . '_material-do-acabamento-revestimento=' . $term->slug;
} else {
$url = wc_get_page_permalink('shop');
}
wp_safe_redirect($url);
exit;
}
}
// Prevent Filter Everything from adding noindex and nofollow tags in redirected filtered Shop page from respective Archive pages
// Function to start output buffering
function start_output_buffer() {
ob_start('remove_noindex_nofollow_meta_tags');
}
add_action('wp', 'start_output_buffer');
// Function to remove noindex, nofollow meta tags from the buffer
function remove_noindex_nofollow_meta_tags($buffer) {
$buffer = str_replace('<meta name="robots" content="noindex, nofollow">', '', $buffer);
return $buffer;
}
// Function to end output buffering and flush the buffer
function end_output_buffer() {
if (ob_get_length()) {
ob_end_flush();
}
}
add_action('shutdown', 'end_output_buffer');Hello there, Victor (@fesupportteam)!
Thank you very much for your quick response time.
It worked.
Just one more thing: will this function be reset to default when the plugin gets updated or will it retain my modifications?
If it’s the first option, how can I make this change to be permanet?
Thank you very much!
Forum: Fixing WordPress
In reply to: Unwanted on redirected pages.Thank you very, very much, @threadi, you just saved me a lot of trouble on further searching for its cause and possible solutions.
I’ll leave it open for now and possibly come back with a workaround to comment here.
You have a great week ahead, my friend!
Regards,
PedroForum: Plugins
In reply to: [White Label CMS] Possible to rename menu items?Not possible with White Label CMS as fas as I know, but a good plugin to do that is ASE (Admin and Site Enhancements), also it replaces a bunch of other plugins as it brings a lot of functionalities.
Something worth mentioning is: while the “::marker” does not show up in the front end HTML for bullet point list, it DOES show up for the numbered list (along with its proper styling).
Hello there!
Thanks for the quick response, that means a lot from you guys!
due to certain assets not loading in the backend
Yeah!Been diggin into the matter since I posted, found just some JS loading errors both for the “elementor” and “page” options, couldn’t do anything about neither;
Kept digging to see if I could reach a practical solution, but coudn’t get a solid workaround for vertically stretching the main container as the accordion unfolds, as the height is based upon the current iframe script loading, so CSS auto/fit-content/100% would just shrink the whole custom dashboard narrowing it down to a few pixels.
For now, the most practical solution-ish approach to avoind clipping when unfolding the accordion was to extend the page itself beyond the main container’s content bottom, but it screams “NOT PROFFESSIONALY WHITELABLED!!!”.
Looking forward to the next updates!
Thank you guys for the great work and the awesome plugin!
Best of luck to you!
Forum: Plugins
In reply to: [White Label CMS] Dashboard Elementor Template Styling ErrorHello there! Hope this isn’t too late.
Yes, there’s a solution for this!Unfortunately for you, who handled your support case here wasn’t aware or wasn’t willing enough to go for a real solution, as this has already been dealt with and already has another support case that’s pointed out the correct response more than 2 years ago.
The short answer consists in these few steps:
? You have to set every styling option by yourself (can’t go with default nor global properties);
? You have to save as a new page template after finishing every change;
? You have to reasign the Custom Dashboard template in Whitelabel CMS settings to this new saved template.
Here’s the link with the complete support case showing the working solution (video included):
https://www.ads-software.com/support/topic/custom-elementor-dashboard-broken-style/Hope this helps…
Cheers, best of luck for you!