Jon Christopher
Forum Replies Created
-
Forum: Plugins
In reply to: [SearchWP Live Ajax Search] Remove (media) from result titleForum: Plugins
In reply to: [SearchWP Modal Search Form] Missing search iconI can’t say for sure what’s causing that problem specifically, but I do notice what may be an interesting console error:
downloadable font: OS/2: Bad sTypoLineGap, setting it to 0: -32 (font-family: "so-slider-pointers" style:normal weight:400 stretch:100 src index:1) source: https://www.portagewi.gov/wp-content/plugins/so-widgets-bundle/css/slider/fonts/slider.woff?8p86w5
It looks to be related to a plugin
so-widgets-bundle
— does deactivating that plugin change how the form is displayed?Additional question: does deactivating SearchWP Live Ajax Search affect the button?
Forum: Plugins
In reply to: [SearchWP Modal Search Form] installation causes fatal errorHi James, I’m sorry about that oversight! This issue has been resolved in version
0.2.1
.Forum: Reviews
In reply to: [SearchWP Modal Search Form] If this developer makes a search plugin use itThank you, I hope you enjoy!
Forum: Reviews
In reply to: [SearchWP Live Ajax Search] No settingsIt’s true that there’s no settings screen (that’s by design) but there’s a filter to allow full customization of the search query arguments:
https://github.com/jchristopher/searchwp-live-ajax-search/blob/1.3.1/includes/class-client.php#L64
??
Forum: Developing with WordPress
In reply to: wp_redirect issuewp_redirect()
needs to be fired before any output is sent to the browser, but by the time a Shortcode is parsed it’s too late.With the goal of wanting to redirect to page Y when viewing pages A, B, or C, you can use something like this:
add_action( 'wp', function() { // IDs of posts that when visited will be redirect $to_redirect = array( 1, 10, 15, 19 ); // The destination when redirecting $destination = home_url(); // If we're viewing a post where we should redirect, redirect if ( in_array( get_the_ID(), $to_redirect ) && ! is_home() ) { wp_redirect( $destination ); } });
You can replace your existing code in your child theme’s
functions.php
with the above, and customize the variables as necessary, and you should be all set.Forum: Fixing WordPress
In reply to: Procedure WP server migrationI might suggest an automated solution such as Duplicator which I have used many times with great success:
Forum: Plugins
In reply to: [Jilt for Easy Digital Downloads] Fatal error in 1.4.0Good to go! ??
Forum: Plugins
In reply to: [Duplicate Menu] Is this plugin still workingCan someone with this issue email an export of their site content to [email protected] so I can reproduce the error and get a fix out? I’ve tried using my test menus but they duplicate as expected. Thanks!
Forum: Plugins
In reply to: [SearchWP Live Ajax Search] How to remove the (Post) after the name?Forum: Plugins
In reply to: [SearchWP Live Ajax Search] PHP fatal error in latest version?Sorry about that! 1.3.1 was just released with a fix.
Forum: Reviews
In reply to: [Hierarchy] menu items not restored after deactivatingThere must be something else hiding them, or maybe even a caching issue. If Hierarchy isn’t active, that means the functionality built into the plugin to hide the menu entries is also not active.
Forum: Plugins
In reply to: [SearchWP Live Ajax Search] Exclude CategoryHi there, you can filter the arguments used to find results using this hook: https://github.com/jchristopher/searchwp-live-ajax-search/blob/1.2.0/includes/class-client.php#L64
Hi there, editing the plugin code isn’t recommended, instead there is a hook to disable the output of the styles: https://searchwp.com/extensions/live-search/#gist11538762
Forum: Plugins
In reply to: [SearchWP Live Ajax Search] Add link to view all results?Hi there! Just to follow up on the original inquiry:
You’re right,
get_search_query()
doesn’t work here because the plugin is using a different variable, you can use this instead:$search_query = isset( $_POST['swpquery'] ) ? sanitize_text_field( $_POST['swpquery'] ) : '';
From there you can follow the results template customization guide to output a link to
$full_results_link = add_query_arg( array( 's' => $search_query ), site_url() ); echo '<a href="'; echo esc_url( $full_results_link ); echo '">All results</a>';
and that should do it!
- This reply was modified 7 years, 7 months ago by Jon Christopher. Reason: Formatting to prevent horizontal scroll