mcyzyk
Forum Replies Created
-
Forum: Plugins
In reply to: [Zotpress] Spinning Wheel: Error in JSONBig BUMP!
Our project using this is about to have a magazine article written about it. Sure would be good if this issue were fixed.
Mark
Same issue here: Scan starts, then immediately gets a Stop command.
Reading this in the docs:
If you see a FORBIDDEN message, then you have probably set up a “.htaccess” file that blocks access to your “wp-admin” directory and you will need to add an exclusion for the WordPress AJAX handler.Do you have an example of what specifically to add to .htaccess?
Mark
Forum: Plugins
In reply to: [Zotpress] Spinning Wheel: Error in JSONBump! Hoping this issue can be resolved.
Mark
Forum: Plugins
In reply to: [Grid Shortcodes] Via do_shortcode() in template?Well OK! The issue was my Row tags needed to be outside my foreach loop:
$output = '[GDC_row]';
foreach ($selected_comparisonIDs as $thisComparisonID) {
// Define the specific post ID you want to display
$specific_post_id = $thisComparisonID; // Replace 26 with your actual post ID
// Arguments for WP_Query
$args = array(
'p' => $specific_post_id, // Query the specific post ID
'post_type' => 'any', // Set post type to 'any' to ensure it finds pages, custom post types, etc.
);
// Create a new WP_Query instance
$the_query = new WP_Query( $args );
// Start The Loop
if ( $the_query->have_posts() ) :
while ( $the_query->have_posts() ) : $the_query->the_post();
$output .= '[GDC_column size="third"]';
$output .= '<h2><a href="' . get_permalink() . '">' . get_the_title() . '</a></h2>';
// Capture the template part output
ob_start();
get_template_part( '/template-parts/content-fulldisplay' );
$output .= ob_get_clean();
$output .= '[/GDC_column]';
endwhile;
endif;
// Reset Post Data to restore the original query (important if you have a main loop elsewhere on the page)
wp_reset_postdata();
}
$output .= '[/GDC_row]';
// Process all shortcodes at once
echo do_shortcode( $output );Forum: Plugins
In reply to: [Grid Shortcodes] Via do_shortcode() in template?Ok, Claude clued me in. Looks like you need to build a big string of your content first, then feed it to the do_shortcode() function for interpretation/execution all at once:
// Build the entire shortcode string first
$output = '[GDC_row]';
// Start The Loop
if ( $the_query->have_posts() ) :
while ( $the_query->have_posts() ) : $the_query->the_post();
$output .= '[GDC_column size="third"]';
$output .= '<h2><a href="' . get_permalink() . '">' . get_the_title() . '</a></h2>';
// Capture the template part output
ob_start();
get_template_part( '/template-parts/content-fulldisplay' );
$output .= ob_get_clean();
$output .= '[/GDC_column]';
endwhile;
endif;
$output .= '[/GDC_row]';
// Process all shortcodes at once
echo do_shortcode( $output );
// Reset Post Data to restore the original query (important if you have a main loop elsewhere on the page)
wp_reset_postdata();This works, sort of. It gives me a single row with 1 column that’s a third of the screen. I want a single row with 3 columns.
- This reply was modified 3 months, 1 week ago by mcyzyk.
Forum: Plugins
In reply to: [Search Regex] RegEx valid; RegEx in Search Regex not findning anythingGood to know about the incompatibility.
Much appreciation for a very useful plugin.
Mark
Forum: Plugins
In reply to: [Search Regex] RegEx valid; RegEx in Search Regex not findning anythingDoes anyone have thoughts on why my RegEx works in regex101.com but not in Search Regex? Both are set to latest PHP RegEx config.
Forum: Plugins
In reply to: [PDF.js Viewer] ForbiddenIn that case, I guess it was idiosyncratic to my local setup. (I’m betting my Wordfence was blocking it, somehow…)
Thank you , this is very useful (and a much clearer and concise elaboration of the problem than what I initially provided!).
Regarding this:
“WordPress will reconstruct the correct path as long as the filename matches exactly.”
If I replace this HTML code in a Post:
<a href=”https://blogs.library.jhu.edu/wp-content/uploads/sites/23/2025/11/grad-student-space-area-scaled.jpg“><img src=”SomeFileInMyLocalMediaLibrary.jpg”></a>
With this:
<a href=”grad-student-space-area-scaled.jpg“><img src=”SomeFileInMyLocalMediaLibrary.jpg”></a>
WordPress will somehow find grad-student-space-area-scaled.jpg in my local Media Library?Much appreciated,
Mark
Forum: Plugins
In reply to: [Zotpress] Spinning Wheel: Error in JSONFrom the Zotero Forum:
https://forums.zotero.org/discussion/comment/504067#Comment_504067
It looks like it’s just zotpress that’s generating invalid JSON for the second request, by not properly escaping the quotes that are returned from Zotero’s API.
It stops after the 50 items in the first page, and then fails to parse the next JSON response, but that’s the JSON that’s built by zotpress, not directly from Zotero.
Yikes! My question is not about a commercial plugin, I was just answering your question about how I initially migrated.
My question remains: Any way to programmatically change a link in a Post like this:
OLD:
https://blogs.library.jhu.edu/wp-content/uploads/sites/23/2025/11/grad-student-space-area-scaled.jpgto this:
NEW:
https://www.library.jhu.edu/wp-content/uploads/sites/3/2025/12/grad-student-space-area-scaled.jpgSome kind of RegEx Search and Replace?
If I changed it just to: “grad-student-space-area-scaled.jpg” would WP “find” that image in the local Media Library?
Mark
Yes, it’s a site on a Multisite to another site on another Multisite.
For the migration, I used WP All Import/Export Pro (awesome plugin, I’ve used it for years.) It does NOT change links in the text of Posts as part of the migration process. (In fact, it does not preserve the coding of page builders such as WP Bakery, Avada, either.)
https://www.wpallimport.com/export-wordpress/
- This reply was modified 5 months, 2 weeks ago by mcyzyk.
And yet:
“I have WP-Optimize Network Activated, so it’s doing well with my single Site.”
Yes, using the Free version.
Forum: Fixing WordPress
In reply to: Import Posts With Images from Dev Server Inside FirewallJust reporting back: That technique worked!
https://www.library.jhu.edu/earl-arnett-pens-memoir-of-his-marriage-to-singer-ethel-ennis/
Thanks so much,
Mark