vision64
Forum Replies Created
-
Forum: Plugins
In reply to: [WebP Express] WebP Express Doesn’t Rewrite Divi Background ImagesIf people are still having issues with this, i found that the following fixed this issue for me:
Webp Express settings > Alter HTML > How to Replace
If you change this setting to “The complete page (using output buffering)” the background images should use webp format, at least it does for me.
- This reply was modified 1 year, 4 months ago by vision64.
Forum: Plugins
In reply to: [Table Field Add-on for ACF and SCF] Using “Tablepress” causes issuesHi Johann
awesome – works like charm.
Thanks very much for the fast and good help
Uwe
Forum: Plugins
In reply to: [Table Field Add-on for ACF and SCF] Using “Tablepress” causes issuesI tried to replace all
$table
with$tabletest
but that doesnt seem to work either.WP display now the shortcode instead of [table “” not found /]
Hope you can help me ??
Uwe
Forum: Plugins
In reply to: [Table Field Add-on for ACF and SCF] Using “Tablepress” causes issuesHi
I currently do use the following code in my functions.php (copied from a support ticket here and modified it to output also the table caption:
function shortcode_acf_tablefield( $atts ) { $a = shortcode_atts( array( 'field-name' => false, 'post-id' => false, ), $atts ); $table = get_field( $a['field-name'], $a['post-id'] ); $return = ''; if ( ! empty( $table['caption'] ) ) { $return .= '<div class="table-title">' . $table['caption'] . '</div>'; } if ( $table ) { $return .= '<table class="product-tables">'; if ( $table['header'] ) { $return .= '<thead>'; $return .= '<tr>'; foreach ( $table['header'] as $th ) { $return .= '<th>'; $return .= $th['c']; $return .= '</th>'; } $return .= '</tr>'; $return .= '</thead>'; } $return .= '<tbody>'; foreach ( $table['body'] as $tr ) { $return .= '<tr>'; foreach ( $tr as $td ) { $return .= '<td>'; $return .= $td['c']; $return .= '</td>'; } $return .= '</tr>'; } $return .= '</tbody>'; $return .= '</table>'; } return $return; } add_shortcode( 'table', 'shortcode_acf_tablefield' );
The shortcode I am using to render the table is: [table field-name=”my-tablename”]
Thanks very much for you help in advance
Uwe
Forum: Plugins
In reply to: [Table Field Add-on for ACF and SCF] Using “Tablepress” causes issueshi
you mean in the functions.php?
can you send me an example code please?
Thanks a lot
Uwe