Vertical search result evenly below search box on all devices

Home Forums Product Support Forums Ajax Search Pro for WordPress Support Vertical search result evenly below search box on all devices

This topic contains 3 replies, has 2 voices, and was last updated by Ernest Marcinko Ernest Marcinko 8 months, 3 weeks ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #45592
    vannie
    vannie
    Participant

    hi Ernest,

    Another issue I’m facing is that my vertical search result box is going in all vertical directions accros mobile, tablet and desktop. I tried to play with the verical margin, but I can’t seem to get grip on it.
    The setting Layout Options > Results layout and fields > Results container margin does not seem to have any impact, even if I remove the below CSS:

    /*Ajax search result position change*/

    #ajaxsearchprores1_1, #ajaxsearchprores1_2, div.asp_r.asp_r_1 {
      z-index: 2000;
      position: relative;
    	margin-top: 500px!important;
    	}

    /*same on mobile*/

    	@media screen and (max-width: 960px) {
    #ajaxsearchprores1_1, #ajaxsearchprores1_2, div.asp_r.asp_r_1 {
      z-index: 2000;
      position: relative;
    	margin-top: 125px!important;
    	}}

    Any advise is be highly appreciated!
    Thanks,
    Tom

    #45594
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi Tom,

    I think the problem arises from this custom CSS: https://i.imgur.com/ciAFRXf.png
    This moves the search box outside the content flow and -130px upwards. So when the calculation is done, this can’t be accounted for.
    I see this margin also changes from device to device.

    I suggest adding the same positive margin (minus the gap you need) for each case for the results box as well, so they align at the final calculation.
    So if you add -130px to the main box, then do something like 120px to the results box and so on..

    Please note that I can’t guarantee anything for customizations, but in this case that should do the trick.

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


    #45596
    vannie
    vannie
    Participant

    Amazing, this works, thanks Ernest!
    Have a nice day

    #45602
    Ernest Marcinko
    Ernest Marcinko
    Keymaster
    You cannot access this content. Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.