-
AuthorPosts
-
September 26, 2018 at 5:06 pm #1014875
Hello,
it seems the theme adds ?s= even to URL that are not search url, causing 404 and duplicated content.
Editing the function.php doesn’t work and neither blocking them in robots.txt.
However the robots.txt solution would be the last one, because I think it’s better if these URL wouldn’t be generated at all instead of blocking them.Thank you
September 26, 2018 at 5:23 pm #1014881Here are some examples, both normal and with ?s=:
https://www.seduzioneolistica.it/riconquistare-ex-ragazzo/come-tenersi-un-uomo/?s=
https://www.seduzioneolistica.it/sesso/come-superare-ansia-prestazione/?s=
https://www.seduzioneolistica.it/shop/ebook/progetto-eiaculazione-precoce/?s=
https://www.seduzioneolistica.it/seduzione/amicizia-tra-maschio-e-femmina/?s=
https://www.seduzioneolistica.it/seduzione/come-fare-colpo-su-una-ragazza/?s=
https://www.seduzioneolistica.it/riconquistare-ex-ragazzo/innamorarsi-del-proprio-ex-ragazzo/?s=
https://www.seduzioneolistica.it/riconquistare-ex-ragazza/tornare-con-lex-ragazza-impariamo-a-usare-la-gelosia/?s=
https://www.seduzioneolistica.it/amore-a-distanza/vacanze-separate-e-giusto/?s=
https://www.seduzioneolistica.it/page/11/?s=
https://www.seduzioneolistica.it/seduzione/?s=https://www.seduzioneolistica.it/articoli/page/2/?s
https://www.seduzioneolistica.it/articoli/page/2/https://www.seduzioneolistica.it/articoli/page/3/?s
https://www.seduzioneolistica.it/articoli/page/3/
https://www.seduzioneolistica.it/articoli/page/21/?s
https://www.seduzioneolistica.it/articoli/page/21/
https://www.seduzioneolistica.it/articoli/page/19/?s
https://www.seduzioneolistica.it/articoli/page/19/
https://www.seduzioneolistica.it/articoli/page/20/?s
https://www.seduzioneolistica.it/articoli/page/20/
https://www.seduzioneolistica.it/articoli/page/4/?s
https://www.seduzioneolistica.it/articoli/page/4/
https://www.seduzioneolistica.it/articoli/page/5/?s
https://www.seduzioneolistica.it/articoli/page/5/
https://www.seduzioneolistica.it/articoli/page/6/?s
https://www.seduzioneolistica.it/articoli/page/6/
https://www.seduzioneolistica.it/articoli/page/7/?s
https://www.seduzioneolistica.it/articoli/page/7/
https://www.seduzioneolistica.it/articoli/page/18/?s
https://www.seduzioneolistica.it/articoli/page/18/
https://www.seduzioneolistica.it/articoli/page/17/?s
https://www.seduzioneolistica.it/articoli/page/17/
https://www.seduzioneolistica.it/articoli/page/16/?s
https://www.seduzioneolistica.it/articoli/page/16/
https://www.seduzioneolistica.it/articoli/page/15/?s
https://www.seduzioneolistica.it/articoli/page/15/
https://www.seduzioneolistica.it/articoli/page/8/?s
https://www.seduzioneolistica.it/articoli/page/8/
https://www.seduzioneolistica.it/articoli/page/9/?s
https://www.seduzioneolistica.it/articoli/page/9/
https://www.seduzioneolistica.it/articoli/page/14/?s
https://www.seduzioneolistica.it/articoli/page/14/
https://www.seduzioneolistica.it/articoli/page/13/?s
https://www.seduzioneolistica.it/articoli/page/13/
https://www.seduzioneolistica.it/articoli/page/10/?s
https://www.seduzioneolistica.it/articoli/page/10/
https://www.seduzioneolistica.it/articoli/page/11/?s
https://www.seduzioneolistica.it/articoli/page/11/
https://www.seduzioneolistica.it/articoli/page/12/?s
https://www.seduzioneolistica.it/articoli/page/12/September 26, 2018 at 5:44 pm #1014888Hi,
Please refer to the following:
Best regards,
Jordan ShannonSeptember 27, 2018 at 11:41 am #1015232Hello,
thank you for your reply. I read that thread and other similar, but I saw they are dated 2016, so I though they became too old in the meantime.
Well I tried with function.php and robots.txt but screaming frog always finds these URLs
More I think robots.txt is not the best way, because it would be better if these useless URLs were not generated at all.
Any solution for that? Anyway removing the search box from the menu and using the stanadrd WordPress search widget in sidebar would be a good compromise.
Thank youSeptember 27, 2018 at 1:44 pm #1015278Hi,
Please use this code in your child theme functions.php to remove the search icon (from the menu):
add_action('init', 'avia_remove_search', 10); function avia_remove_search() { remove_filter( 'wp_nav_menu_items', 'avia_append_search_nav', 9997, 2 ); remove_filter( 'avf_fallback_menu_items', 'avia_append_search_nav', 9997, 2 ); }
You can then add the search widget to the sidebar to display the standard wordpress search form.
Best regards,
PeterSeptember 28, 2018 at 3:49 pm #1015768Hi, maybe I don’t understand but to remove the icon I can do it simply by theme options…
I’d like to keep the search icon and serach function, but I’d like it doesn’t create these duplicate URLs with ?s=
Now I blocked them by robots.txt but I think it’s better if it’s possible to eliminate them.Thank you
September 30, 2018 at 9:59 am #1016229Hi,
You can try to add following code to the child theme functions.php – it will add a rel=nofollow attribute to the search icon in the menu and will discourage search engines to follow/index the /?s url of the search icon.
add_filter( 'wp_nav_menu_items', 'avia_append_search_nav', 9997, 2 ); add_filter( 'avf_fallback_menu_items', 'avia_append_search_nav', 9997, 2 ); function avia_append_search_nav ( $items, $args ) { if(avia_get_option('header_searchicon','header_searchicon') != "header_searchicon") return $items; if(avia_get_option('header_position', 'header_top') != "header_top") return $items; if ((is_object($args) && $args->theme_location == 'avia') || (is_string($args) && $args = "fallback_menu")) { global $avia_config; ob_start(); get_search_form(); $form = htmlspecialchars(ob_get_clean()) ; $items .= ' <li id="menu-item-search" class="noMobile menu-item menu-item-search-dropdown menu-item-avia-special"> <a href="?s=" rel="nofollow" data-avia-search-tooltip="'.$form.'" '.av_icon_string('search').'><span class="avia_hidden_link_text">'.__('Search','avia_framework').'</span></a></li> '; } return $items; }
Best regards,
PeterSeptember 30, 2018 at 12:36 pm #1016244I have been seeing this issue too. I had no idea what it was. WHY does this happen?
Here we go with yet another “default” hack setting to turn something off / fix something that Enfold should really be doing themselves in errr, an update at any point in the future?
Working with Enfold and all these little issues is making the the theme far less attractive to use. It used to be an out of the box solution, but not any more :(I despair at suggestions to turn features off (like search), because your theme is so messed up in code. Why are you asking users to fix these issues instead of feeding it back to development and getting it fixed, making the theme better?
September 30, 2018 at 1:21 pm #1016254Hi,
Who claims I’m not reporting it back to our developers? I already wrote a fix and ask the developers to include it with the next update. The reason why we’re delaying the upcoming update at the moment is the new envato update api which must be included with the next update (otherwise this and the next update wouldn’t work with the automatic update feature and we want to avoid this situation).Best regards,
PeterSeptember 30, 2018 at 3:00 pm #1016279I’m sure you are @dude, but do they listen? This has been an issue for over 2 years ;) As are many many other issues that are not fixed. But we don’t know this because there is no roadmap, list of bugs, issues etc. We just keep adding to the gazillion posts here. ;)
-
AuthorPosts
- You must be logged in to reply to this topic.