Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter briangardenofone

    (@briangardenofone)

    Hi Hannah!
    (Hi Ben!)

    I didn’t use any classes. ..and I’m not sure what you mean by the “Normal Hierarchy”

    We have a custom woocommerce e-mail:
    class our_class extends WC_Email { …

    The table is generated in the email class with a loop:

    ...
    $temp_running_total_output .= '<tr>';
    $temp_running_total_output .= '<th {attr_th_style}>' . $temp_display_name . '</th>';
    $temp_running_total_output .= '<td {attr_td_style}>' . $temp_field . ' ' . $temp_info['units'] . '</td>';
    $temp_running_total_output .= '</tr>’;
    ...

    It’s passed to the email template which adds the style:

    ...
    		$search = array(
    			'{attr_table_style}',
    			'{attr_th_style}',
    			'{attr_td_style}' );
    		$replace = array(
    			'style="border-collapse: collapse; border: 2px solid #959c97; background-color: #fafafa;"', //Table Style
    			'border: 1px solid #959c97;',  //Table Header Style
    			'border: 1px solid #959c97;'  //Table Element Style
    			
    		);
    		str_replace( $search , $replace , $guides['attributes-display'] ) ;
    ...

    Any inline styling then gets stripped out by Kadence. The table still shows, but not with the borders, etc.

    Thread Starter briangardenofone

    (@briangardenofone)

    Oops! I take it back – theres no link

    “Ferns (#1696) is low in stock. There are 2 left.”

    Thread Starter briangardenofone

    (@briangardenofone)

    When I say “it” goes away, I mean the problem goes away and everything displays like it should.

Viewing 3 replies - 1 through 3 (of 3 total)