Forum Replies Created
-
AuthorPosts
-
Ernest Marcinko
KeymasterHi!
Sure! Open the search instance settings, go to the Theme Options -> Custom CSS panel, it should be there: http://i.imgur.com/vC1avcb.png
Ernest Marcinko
KeymasterHi!
I see the following text in the “No results text” parameter:
[code]<a href=/calificar>No se encontraron empresas. <strong>Agregala!</strong></a>[/code]
Unfortunately this is no longer possible to use HTML in the parameter there. It raised security concerns and I had to remove it.
Please remove HTML tags from the No results text option on the Layout Options -> Results layout panel.You can still use that HTML though, by using result templating, which is much safer and update proof as well. Here is a quick tutorial link.
In your case you will have to first copy the wp-content/plugins/ajax-search-pro/includes/views/results/no-results.php file into a new folder named “asp” in your current theme folder. Then make the change on that copied file on line 30 to:
[html]<a href=/calificar>No se encontraron empresas. <strong>Agregala!</strong></a>[/html]
That should fix the problem 🙂
Ernest Marcinko
KeymasterThank you very much.
Ernest Marcinko
KeymasterThank you for your kind words, and you are welcome, I’m glad I could help 🙂
If you want, you can leave a rating on it on your codecanyon downloads page, it’s greatly appreciated 🙂
Ernest Marcinko
KeymasterHi!
Thanks, I didn’t notice, sorry about that.
Seems like either the theme or othe custom CSS is overriding the color. I’ve added the following custom CSS code to the Theme options -> Custom CSS panel to fix it:
[html]p.asp-try a {
color: rgb(30, 217, 184) !important;
}[/html]It should display correctly now.
Ernest Marcinko
KeymasterHi!
I think I have great news for you 🙂 I didn’t manage to finish on friday, sorry about that.
So I just finished testing and it looks very promising. I’m attaching the changed version to this reply.
In this version the comments respect the category exclusions, and also they should be display when you click on the “view more” link as well.Please let me know how it works.
Ernest Marcinko
KeymasterHi!
The theme might be overriding the color attributes of the links. Can you please link me to a page where the search is visible?
Then I might be able to suggest a custom CSS rule to change the color.
Ernest Marcinko
KeymasterYes, you probably need to increase the description length. By default it’s 130 characters. You can change that on the Layout Options -> Results Layout panel with the Description (content) length option. I recommed trying like 730 at first, and perhaps increasing it until you start seeing the description.
Ernest Marcinko
KeymasterHi!
Only by using a custom code, but luckily you don’t have to edit any of the plugin files, so this should be update-proof as well.
Try putting this code to your currently active theme folder, into the functions.php file:
[php]
add_filter( ‘asp_result_content_after_prostproc’, ‘asp_cut_from_content’, 1, 1 );function asp_cut_from_content( $content ) {
// Change this to the number of characters you want to cut
$charaters_to_cut = 50;return substr($content, $charaters_to_cut);
}
[/php]Change the $characters_to_cut variable to the number of characters you want to remove from the beginning.
Ernest Marcinko
KeymasterHi!
Looks like the host detected the plugin as a false-positive. I have no idea why, perhaps some code parts resemble something for the heuristics filter.
Have you tried to install the plugin via the plugin manager? It’s much better than using FTP to upload, and might not give you this warning.
Otherwise I guess you will have to whitelist that file somehow. Maybe there is an option on your CPanel or equivalent hosting settings page, where you can whitelist files. Maybe you will have to contact the hosting provider to do it for you.
Ernest Marcinko
KeymasterHi!
Good news. I finished a possible release candidate for version 1.4, I’m attaching it to this reply for testing. I have fully optimized the database queries based on the table indexes and best practices from the MySQL manual. From this point on I’m almost sure the performance only depends on the configuration and the server speed.
After installing, please change the Maximum Keywords count option to 4 on the Relevance Options -> Keywords options panel: https://i.imgur.com/YDEJ0tb.png
I have found that 4 is more than enough and optimal for the performance.Let me know how this one works!
Ernest Marcinko
KeymasterHi!
1. I just tried and it works on my end: http://i.imgur.com/uTi66iY.png
I disabled the resources and feeds post type filter, and the two posts are there in the results list. I didn’t uncheck the “Free Project Management Courses” and the “Articles” checkbox – it would exclude both of them, because one is in the first category, the other is in the second.2. Might be possible actually. The plugin has a built in highlighter script, which could be used to highlight terms on the search page. Try putting this custom script code to the search.php file in your theme directory:
[html]
<script>
jQuery(function($) {
aspjQuery("main").highlight(aspjQuery(".probox input.orig").val(), { element: ‘span’, className: ‘highlighted’, wordsOnly: 0 });
});
</script>
[/html]and also, you need some custom CSS for it:
[html]
span.highlighted {
font-weight: bold;
color: #d9312b;
background-color: #eee;
background-color: rgba(253, 181, 48, 0.57);
}
[/html]I’m just guessing here, this might not work though.
3. I guess those pages have either some kind of shortcodes as content or custom code or maybe they are just a permalink for a theme file. The plugin tries to get any content possible. However for example the “Blog Articles” page does not actually have any content, it’s only a permalink to redirect to a theme file. It basically orders wordpress to show something on that permalink. I don’t think it’s possible to show any kind of content on these pages within the search results.
4. As I can see your current theme already does that for you, you only need the custom styling CSS code. Every article element on the results page is marked with a CSS class based on the post type. I can see these:
-
type-post
type-page
type-feedso you can easily make custom CSS to distinguish each type like. For example to change some styles only on “post” results:
[html]
article.type-post {
/* generic custom CSS code */
}article.type-post p {
/* paragraph, post content custom CSS code */
}article.type-post h1,
article.type-post h1 a {
/* post title custom CSS code */
}
[/html]Ernest Marcinko
KeymasterNice, I’m glad it’s working despite the restrictions.
I’ll close this ticket and mark as resolved. Have a nice day!
Ernest Marcinko
KeymasterI’m going to release a bugfix version soon (in few days), where I’m fixing this and other potential issues as well.
Can you wait a few days for the update?Ernest Marcinko
KeymasterOh I see the problem now 🙂
Your solution was actually almost correct. The problem was that the custom field “design” returned the term ID not the term name. Instead of that solution I’ve changed the custom code to this:
[php]
add_filter( ‘asp_pagepost_results’, ‘asp_add_term_titles’, 1, 1 );function asp_add_term_titles( $pageposts ) {
foreach ($pageposts as $k=>$v) {$colorway = "<span class=colorway>" . get_post_meta($v->id, "colorway", true) . "</span>";
$design = get_post_meta($v->id, "design", true);if ( $design !== false ) {
$d_term = get_term($design, "designs");if ( isset($d_term->name) )
$pageposts[$k]->title = $d_term->name . " " . $colorway;}
}return $pageposts;
}
[/php]this one additionally parses the design custom field, then gets the term from that field accordingly.
As for the margin, I’ve forgotten to implement that option in the current version, I noticed too late 🙂 It’s a parameter of the isotope calculation script, so it’s hard coded right now.
However there is a workaround with CSS, but it’s not nearly as good as changing the isotope parameter. Basically adding transparent left, right border to the items appears as space, like so:[html]
.isotopic .results .item {
border-right: 5px solid transparent !important;
border-left: 5px solid transparent !important;
}
[/html]this basically adds 10 pixels inbetween, but 5 pixels on each side as well, so it’s not near perfect.
-
AuthorPosts