Hi, not sure if this is the right place for this, butI installed the module on an instance of wordpress, had a few issues with the way that the plugin, as currently released, is doing a couple of things.
In the migrate_thecontent function I explicitly set the posts_per_page value to -1 to force the query to run through all available posts and pages, rather than potentially having the limit set on that query.
In the new_the_content function I added an else condition to the main test to allow the plugin to handle installs with custom post types or to fail gracefully if a particular piece of content hasn’t been correctly imported to the new flexible_columns format.
see diff file below:-
diff start >>>>
— acf-flexible-columns/acf-flexible-columns.php 2018-04-19 17:45:18.000000000 +0100
+++ acf-flexible-columns/acf-flexible-columns.php 2018-05-04 10:10:26.218934108 +0100
@@ -91,7 +91,8 @@
global $wpdb;
if (isset($_GET[‘acffc_nonce’]) && wp_verify_nonce($_GET[‘acffc_nonce’], ‘migrate_content’)):
$args = array(
– ‘post_type’ => array( ‘post’, ‘page’)
+ ‘post_type’ => array( ‘post’, ‘page’),
+ ‘posts_per_page’ => -1,
);
$query = new WP_Query( $args );
if( $query->have_posts() ):
@@ -381,6 +382,7 @@
function new_the_content($content){
global $post;
$opts = get_option(‘acf_flexcol_opts’);
+ $old_content = $content;
$content = ”;
if( have_rows(‘rows’) ):
while( have_rows(‘rows’) ):
@@ -502,6 +504,8 @@
if( isset($opts[‘enablecontainers’]) && $opts[‘enablecontainers’] == true) $content .= ‘</div>’; //End .container/container-fluid
$content .= apply_filters( ‘flexible_columns_wrap_outer_end’, false );
endwhile; //end rows
+ else:
+ $content = $old_content;
endif;
if ( !post_password_required() ) {
<<< diff end
]]>Does this plugin still get support on? I’m not sure how to get this to work.
]]>Sorry, this plugin looks great but can’t make it work, I′ve got a flexible content flieds with about 10 layouts more with fields.
what do I need to do? I created a new layout whit a WYSIWYG editor…. I need to create custom columns as the images in the installation plugin.
What am I doing wrong? maybe I did not understood the instructions at all.
thanks
]]>