Jump to content

Recommended Posts

  • 1 year later...
Posted
4 hours ago, MaryMatlow said:

This may be a dumb question, but how do in call it on the page? What would be the markup? Thanks.

Hi, Did you see this?

 

Posted
10 hours ago, szabesz said:

Hi, Did you see this?

 

No, I had not. Thanks, it did help. Also, I want show just the search button or icon and on click make the search field open up. Is there a way to do that? Thanks.

  • 2 years later...
Posted
4 hours ago, flydev said:

Hi again,

257146394_Sanstitre.png.124c1376769313afb3b593e3c2747663.png

look like you forgot to include jQuery ?

 

It's here at the end of the page. It's including itself with the plugin . 

2055987737_PrtScrcapture_4.jpg.491a630113721f054c6042b1d6d9021a.jpg

But I added this at the end of my search.php template whihc was missing. 

<?php 

if(!$config->ajax) include("./head.inc");
echo $out;
if(!$config->ajax) include("./foot.inc"); 

?>

 

Still nothing shows up!

 

Posted

Nope jQuery (the third party JavaScript library) isn't added by the module.

 

Try to add this piece of code just after the footer then refresh your page :

<script src="https://code.jquery.com/jquery-3.3.1.js" crossorigin="anonymous"></script>

 

  • Like 1
  • Thanks 1
Posted
17 hours ago, flydev said:

Nope jQuery (the third party JavaScript library) isn't added by the module.

 

Try to add this piece of code just after the footer then refresh your page :


<script src="https://code.jquery.com/jquery-3.3.1.js" crossorigin="anonymous"></script>

  

?‍♂️ Great it works now! 

P.S Perhaps it should added to the readme of the plugin. 

  • Like 1
  • 3 months later...
Posted

In case someone else stumbles over similar demands like me, I put my modified AjaxSearch.js here: AjaxSearch.js

It allows to use an existing #ajaxSearch element, so you may place the result anywhere in your markup (for example an overlay like I did here: https://pwflex.team-tofahrn.de/).

Then I had a problem with excess GET requests which do not cancel server-side processing, so getting the result after typing many characters took seconds. That script uses a different scheduling.

Its a direct replacement, so you may try and revert to the original safely.

Edit: I've updated the script to send the value URI encoded like this:

        data: param_name+"="+encodeURIComponent(value),

Allows to send queries containing special chars like &

  • Like 2

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...