jimbox1985
Forum Replies Created
-
Forum: Plugins
In reply to: [WP Recipe Maker] Manage AD on wprm blockI see… anyway i think i can get something by playing with the hook. Thanks!
Forum: Plugins
In reply to: [WP Recipe Maker] Manage AD on wprm blockThanks for your help!
Correct, i need to display the same structure (like an AD below instruction steps 1, 4 and 7) for every recipe.
I’m actually using the plugin base without set up any hook. I’ve just a personalized template made with the plugin editor.Forum: Plugins
In reply to: [WP Recipe Maker] Manage AD on wprm blockHi Brecht and thanks for your answer… this will help some way, but yes, i need to insert between instruction steps ; as i’m not the best php programmer what i actually got is content (ad) between steps, but it appear on every single step, while i need to make it appear in some specific 2 , maybe 3…
Thank You so much, your help is gold!
Thanks for your suggest, really appreciate.
You think something like this will work to get only “en” category in the slug as domain.com/en/ ?
function custom_rewrite_rule() { add_rewrite_rule('^en/?','top'); } add_action('init', 'custom_rewrite_rule', 10, 0);
or
function append_query_string( $url, $post, $leavename=false ) { if ( $post->post_type == 'post' ) { $url = add_query_arg( 'en', $url ); } return $url; } add_filter( 'post_link', 'append_query_string', 10, 3 );
I think must be insert an if for the category in this last one, or will rewrite all post url, am i wrong? Sorry i’m not very well at this
anyway thanks for your answer.
- This reply was modified 3 years, 11 months ago by jimbox1985.
Forum: Plugins
In reply to: [Yoast SEO] Recipe structured and schemaThanks for help Michael. Really appreciate.
Forum: Plugins
In reply to: [Yoast SEO] Generate a specific category sitemapI’m still looking to resolve that problem. Anyway, may i ask a question?
As i already said, i have a multilanguage version addedd into a category, and it look likemywebsite.com
mywebsite.com/eneverything is right setting up, hreflang, ogtype ecc… just with a if is_category tag. The last thing remain is an external sitemap for the /en/ category, but still i didnt resolve the problem.
Anyway, the posts inside the /en/ category are, obviously, inside the mywebsite.com/sitemap_index.xml , so… it is really necessary to have a separated sitemap for that particullary category? may i get SEO problems? or everything is ok with the main sitemap?
Thanks for your support.- This reply was modified 4 years, 1 month ago by jimbox1985.
Forum: Developing with WordPress
In reply to: Look like language_attributes broke my theme with php 7.2 +ok, solved. i miss ‘en’ inside is_category()
Forum: Developing with WordPress
In reply to: Look like language_attributes broke my theme with php 7.2 +Thanks,
i solved for single page, but in archive the error is still there…
this is my functionfunction new_language_attributes($lang){
if (is_single() || in_category() || is_category()) {
$ar = get_the_category();
foreach($ar as $c) {
if($c->slug==’en’) {
return “lang=\”en\””;
}
}
}
return $lang;
}
add_filter(‘language_attributes’, ‘new_language_attributes’);- This reply was modified 4 years, 1 month ago by jimbox1985.
- This reply was modified 4 years, 1 month ago by jimbox1985.
Forum: Developing with WordPress
In reply to: Look like language_attributes broke my theme with php 7.2 +Here is.,
As I though, something with language_attributes cause the problem. I dont know if problem is closely bound to that, but sure is something around it. Here’s what i get from error log :[Tue Feb 02 05:05:39.893168 2021] [lsapi:error] [pid 3883382:tid 140348714063616] [client 5.89.122.223:53410] [host x.com] Backend fatal error: PHP Fatal error: Uncaught ArgumentCountError: Too few arguments to function in_category(), 0 passed in /home/a8r31gjube9a/public_html/wp-content/themes/wip_theme/functions.php on line 27 and at least 1 expected in /home/a8r31gjube9a/public_html/wp-includes/category-template.php:255\nStack trace:\n#0 /home/a8r31gjube9a/public_html/wp-content/themes/wip_theme/functions.php(27): in_category()\n#1 /home/a8r31gjube9a/public_html/wp-includes/class-wp-hook.php(289): new_language_attributes(‘lang=”it-IT”‘)\n#2 /home/a8r31gjube9a/public_html/wp-includes/plugin.php(212): WP_Hook->apply_filters(‘lang=”it-IT”‘, Array)\n#3 /home/a8r31gjube9a/public_html/wp-includes/general-template.php(4095): apply_filters(‘language_attrib…’, ‘lang=”it-IT”‘, ‘html’)\n#4 /home/a8r31gjube9a/public_html/wp-includes/functions.php(3485): get_language_attributes()\n#5 /home/a8r31gjube9a/public_html/wp-includes/functions.php(3420): _default_wp_die_handler(‘<div class=”wp-…’, ‘WordPress &rsaq…’, Array)\n#6 /home/a8r31gjube9a/public_html/wp-includes/class-wp-fatal-e in /home/a8r31gjube9a/public_html/wp-includes/category-template.php on line 255\n, referer: x
Some idea?
Forum: Developing with WordPress
In reply to: Look like language_attributes broke my theme with php 7.2 +Thanks for your replay. I will take a look to the log when come back to the office.
Anyway, problem can be the doctype or the html type?
Because what i see when i switch to php 7.1 and + is a blank page and by view the source I notice that the page source stop after <html
This is what I see :
<!DOCTYPE>
<htmlso the page source stop right before lang=“en” … That’s what make me think about language attribute… maybe some function that is not working properly in function.php…
Anyway I will take a look to the log and let you know ??Forum: Plugins
In reply to: [Yoast SEO] Generate a specific category sitemapThanks!
Forum: Plugins
In reply to: [Yoast SEO] Sitemap and w3 total cache conflictthanks.
Forum: Plugins
In reply to: [Yoast SEO] Sitemap and w3 total cache conflictsure,
here’s the sitemap. https://designtegrator.com/sitemap_index.xmlAs i sayd, by view the source of sitemap_index i notice also the lazyload option. you think this can be the problem?
Forum: Plugins
In reply to: [Yoast SEO] Duplicated sitemap in search console?thank you so much Maybellyne!