hkikis Posted October 22, 2015 Share Posted October 22, 2015 www.musclebody.gr You can see also the screenshoot. Last 1 month it doesn't show the fotos in the search... How can I fix it? Link to comment Share on other sites More sharing options...
NemoPS Posted October 23, 2015 Share Posted October 23, 2015 The image src reads undefined, you should check the tpl/js that generates it (hard to tell what's wrong since it's a custom template) Link to comment Share on other sites More sharing options...
NemoPS Posted October 23, 2015 Share Posted October 23, 2015 Yes, but that's how you'd debug for it, you need to understand where it breaks Link to comment Share on other sites More sharing options...
hkikis Posted October 23, 2015 Author Share Posted October 23, 2015 I didn't change something... After a restore of my database I have this problem :/ Link to comment Share on other sites More sharing options...
hkikis Posted October 23, 2015 Author Share Posted October 23, 2015 Can you give me steps of how to fix it? Link to comment Share on other sites More sharing options...
NemoPS Posted October 24, 2015 Share Posted October 24, 2015 Well not really, first off you have to check the tpl/js file and see what variable is using, then inspect the file it calls to get the ajax, and see what that one uses. Then going back further, the data assigned to this last template, and how it's formed. Link to comment Share on other sites More sharing options...
hkikis Posted October 24, 2015 Author Share Posted October 24, 2015 (edited) First of all the search is a module of the theme. The name of module is Omicron search. I tried to unistall and reinstall the module but nothing changed. I cannot understand how it doesn't work as I didn't change anything. I found the tpl file for instant search of this module. Can you check it? {if $instantsearch} <script type="text/javascript"> // <![CDATA[ function tryToCloseInstantSearch() { if ($('#old_center_column').length > 0) { $('#center_column').remove(); $('#old_center_column').attr('id', 'center_column'); $('#center_column').show(); return false; } } instantSearchQueries = new Array(); function stopInstantSearchQueries(){ for(i=0;i<instantSearchQueries.length;i++) { instantSearchQueries[i].abort(); } instantSearchQueries = new Array(); } $("#search_query_{$blocksearch_type}").keyup(function(){ if($(this).val().length > 0){ stopInstantSearchQueries(); instantSearchQuery = $.ajax({ url: '{if $search_ssl == 1}{$link->getPageLink('search', true)}{else}{$link->getPageLink('search')}{/if}', data: { instantSearch: 1, id_lang: {$cookie->id_lang}, q: $(this).val() }, dataType: 'html', type: 'POST', success: function(data){ if($("#search_query_{$blocksearch_type}").val().length > 0) { tryToCloseInstantSearch(); $('#center_column').attr('id', 'old_center_column'); $('#old_center_column').after('<div id="center_column" class="' + $('#old_center_column').attr('class') + '">'+data+'</div>'); $('#old_center_column').hide(); $("#instant_search_results a.close").click(function() { $("#search_query_{$blocksearch_type}").val(''); return tryToCloseInstantSearch(); }); return false; } else tryToCloseInstantSearch(); } }); instantSearchQueries.push(instantSearchQuery); } else tryToCloseInstantSearch(); }); // ]]> </script> {/if} {if $ajaxsearch} <script type="text/javascript"> // <![CDATA[ $('document').ready( function() { $("#search_query_{$blocksearch_type}") .autocomplete( '{if $search_ssl == 1}{$link->getPageLink('search', true)}{else}{$link->getPageLink('search')}{/if}', { minChars: 3, max: 5, width: 500, selectFirst: false, scroll: false, dataType: "json", formatItem: function(data, i, max, value, term) { //alert(term); return value; }, parse: function(data) { var mytab = new Array(); for (var i = 0; i < data.length; i++) mytab[mytab.length] = { data: data[i], value: ' <img src="'+ data[i].search_imgl + '" /><span class="listname">' + data[i].pname + ' </span> '}; return mytab; }, extraParams: { ajaxSearch: 1, id_lang: {$cookie->id_lang} } } ) .result(function(event, data, formatted) { if(data.pname!='not_link'){ $('#search_query_{$blocksearch_type}').val(data.pname); document.location.href = data.product_link; } else{ $('#search_query_{$blocksearch_type}').val(data.product_link); $("#searchbox").submit(); } }) }); // ]]> </script> {/if} Edited October 24, 2015 by hkikis (see edit history) Link to comment Share on other sites More sharing options...
hkikis Posted October 30, 2015 Author Share Posted October 30, 2015 Noone? Link to comment Share on other sites More sharing options...
El Patron Posted October 31, 2015 Share Posted October 31, 2015 Noone? Please don't bump topics unless you add value. Moving to development section. Link to comment Share on other sites More sharing options...
max0509 Posted February 29, 2016 Share Posted February 29, 2016 It seems like it's working again, how did you fix it? I'm having the same problem. Missing the data.search_imgl value in array. Link to comment Share on other sites More sharing options...
hkikis Posted February 29, 2016 Author Share Posted February 29, 2016 I haven't fixed it yet :/ If anyone knows I would like to fix it... Link to comment Share on other sites More sharing options...
max0509 Posted February 29, 2016 Share Posted February 29, 2016 If I do a search on your website it shows images. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now