This website uses cookies to personalize your experience. By using this website you agree to our cookie policy.

Reply To: Search results

#51254
Ernest MarcinkoErnest Marcinko
Keymaster

Hi,

1. I’m not sure if this is possible without major customizations. The advanced title/content field feature is to display the whole custom field value. However I can try suggesting a custom code to “find” the closest matching line and trim the title accordingly:

add_filter(
	'asp_results',
	function ( $results, $id, $is_ajax, $args ) {
		foreach ( $results as $r ) {
			$s = str_replace(array( "\r", "\n" ), '', $r->title);
			$s = explode(',', $s);
			$s = array_filter(
				$s,
				function ( $city ) use ( $args ) {
					return str_contains($city, $args['s']);
				}
			);
			if ( isset($s[0]) ) {
				$r->title = $s[0];
			}
		}
		return $results;
	},
	10,
	4
);

Try adding this code via the Code Snippets plugin or to the functions.php file in your theme/child theme directory – make sure to have a full server back-up first for safety. For more details you can check the safe coding guidelines.

2. I recommend switching to a vertical theme: https://i.imgur.com/mlCYfDC.png
There should be vertical version of the same layout you are using right now.

3. Yes that is correct, Envato market is our only seller platform. Can you please tell me which page are you experiencing that dead link as well as which browser? I have tried a few pages on the website but every time I’m correctly redirected to Envato Market on a new tab. I will keep testing until then.