ADvi
Forum Replies Created
-
Resolved.
This plugin doesn’t solve the problem.
How can I migrate?Forum: Plugins
In reply to: [Breadcrumb NavXT] Schema for each element in breadcrumb listThanks! I’ve got the needed result
Forum: Developing with WordPress
In reply to: Customize menuThanks! It works as expected!
Forum: Plugins
In reply to: [Breadcrumb NavXT] Schema for each element in breadcrumb listSite’s owner thinks that is the right way ??
So, can you please help to achieve this schema?
Thanks.Forum: Developing with WordPress
In reply to: Customize menuI’ve changed my code to combine first and second. I did everything right?
class my_Walker_Nav_Menu extends Walker_Nav_Menu { public function start_el(&$output, $item, $depth = 0, $args = array(), $id = 0) { // назначаем классы li-элементу и выводим его $class_names = join( ' ', $item->classes ); $class_names = ' class="' . esc_attr( $class_names ). '"'; $output.= '<li id="menu-item-' . $item->ID . '"' . $class_names . '>'; $attributes = ''; // назначаем атрибуты a-элементу $attributes.= !empty( $item->url ) ? ' href="' . esc_attr( $item->url ) . '"' : ''; $item_output = $args->before; if($args->walker->has_children) { $item_output.= '<div class="header__menu-top"><a' . $attributes . '>' . $item->title.'</a>'; } else { $item_output.= '<a'. $attributes . '>' . $item->title . '</a>'; }; if ( 'primary' == $args->theme_location && $item->description ) { $item_output = str_replace( $args->link_after . '</a>', '<div class="menu-item-description">' . $item->description . '</div>' . $args->link_after . '</a>', $item_output ); } $output .= apply_filters( 'walker_nav_menu_start_el', $item_output, $item, $depth, $args ); } public function start_lvl( &$output, $depth = 0, $args = array() ) { $indent = str_repeat("\t", $depth); $output .= "\n$indent<button class='header__menu-toggle-children'></button></div><ul class='sub-menu'>\n"; } public function end_lvl( &$output, $depth = 0, $args = array() ) { $indent = str_repeat("\t", $depth); $output .= "$indent</ul>\n"; } }
And I can’t understand how to add
<button class='header__menu-toggle-children'></button>
only for first level menu and<button class='header__menu-toggle-children2'></button>
for all submenus? Could you please help to integrate this condition to my code above?
Thanks for help!Forum: Plugins
In reply to: [Breadcrumb NavXT] Schema for each element in breadcrumb listNo, I want to make each item in bredcrumb list become separate element, like here https://search.google.com/structured-data/testing-tool/u/0/#url=https%3A%2F%2Fpravo.guru%2Fzzp%2Ftorgovlya-i-tovary%2Fsertifikatsiya%2Fproishozhdeniya-produktsii%2Fvidy-form.html
But now I have BreadcrumbList + ListItem.
I need Breadcrumb + Breadcrumb + Breadcrumb + Breadcrumb…Forum: Developing with WordPress
In reply to: Function gets wrong ID of postsThe result of error_log( print_r( $post, 1 ) );
https://pastebin.com/ESjCmeGFfunction ub_related_post_by_shop() { wp_reset_query(); //wp_reset_postdata(); global $post; error_log( print_r( $post, 1 ) ); $post_terms = wp_get_object_terms($post->ID, 'shop', array('fields'=>'ids')); .....
wp_reset_query(); and wp_reset_postdata(); don’t solve the problem.
Here is my template https://pastebin.com/te6mW98z that is called from index.php (https://pastebin.com/Xbc0QZvU)
And this is content-header.php that is called from template https://pastebin.com/L5KixpWV
Can you please take a look?
Thanks.- This reply was modified 6 years, 1 month ago by ADvi.
НИКТО. НИЧЕГО. НЕ ПРИШЛЁТ.
Я вот уже несколько лет жду.- This reply was modified 7 years, 3 months ago by ADvi.
Forum: Plugins
In reply to: [YITH WooCommerce PDF Invoice and Shipping List] Download Invoice ButtonThanks. I’ve already bought another plugin that has needed feature.
Forum: Plugins
In reply to: [WooCommerce] Moving the price of a chosen variationlorro, this doesn’t work
Hm. This code does not show selected attribute.
I’m trying this (Attr.Name in сyrillic)<td class="ed"><?php echo wc_get_order_item_meta( $item_id, 'Цена за', true ); ?></td>
and this (Attr.Slug in English)
<td class="ed"><?php echo wc_get_order_item_meta( $item_id, 'tsena-za', true ); ?></td>
My column stays empty.
P.S. Can I add ‘counter’ manualy? ?? without Premium extension?
- This reply was modified 7 years, 4 months ago by ADvi.
Also. About attributes in Order table.
I’ve inserted this in invoice.php
<td class="ed"><?php if(!empty($item['product'])) $this->product_attribute('My Attribute Name', $item['product']); ?></td>
But in PDF-file I got this https://prntscr.com/fy03fn (all of variation attributes are shown). I only need those one that my customer bought.
How can I change this?Is it possible to rename label for Taxes in Order totals? Where can I find this string?
Thanks. I’ve updated class-wcpdf-pdf-maker.php myself and it works!