Aricie
Intégrateur de vos solutions d'avenir
DNN Community Forums

Autocomplete configuration

Sort:
You are not authorized to post a reply.
Author
Messages


samyb











New Member



Posts:




New Member



    I am not able to get the "Autocomplete settings" feature to work. I "Enable autocomplete", but then do not understand what really goes in the "Server settings" fields of "Add field to return/AdditionalFields" nor to the "Sorting fields". I also do not understand what goes in the "Client settings" fields. Again, I have read the manual that I downloaded, but perhaps some examples would help.

    This question comes from the dotnetnuke support and is transferred here for follow-up purposes



    samyb











    New Member



    Posts:




    New Member



      The autocomplete system is used by the LuceneSearch search skin object. You must currently use the skin object to be able to use the autocomplete service.

      Once activated the skin object will display results from what was typed in the textbox. We will use the following image from the autocomplete on our website http://dotnetnuke.aricie.com as a reference

      The server settings configure what is the autocomplete behavior on the server.

      First there are at what point the autocompletion is triggered (you may want your users to type more info to return more precise results) and how many results are returned.

      The Fields returned property allows you to indicate what fields will be sent to the autocomplete client; not all fields are interesting for what you want to display so you can choose what is used. These fields can then be used on the client either for display or for other features which we will talk about in the client section.

      You can also customize how the results are sorted: the Sorting fields option allow you to indicate what fields and what order your query will be sorted against.

      The Client settings configures how the client will handle data sent by the server.

      Positioning is used to control where the autocomplete will appear. It follows the jQueryUI framework positioning configuration.

      Header text allows you to add a custom text at the top of the autocomplete box; in our example on the aricie website, this is the "Suggestions de résultats" text in light gray.

      Then you can decide to use grouping which will reorganize the items you receive into logical blocks. When you use grouping, each group starts with a template which you define in the Group template text property. Important: since the autocomplete works in javascript, the DotNetNuke token system isn't used; rather a javascript micro templating engine is used, which you'll find a link to in the template help popup. This template and the following has access to the data sent back by the server.

      In the example above, we decided to regroup the results according to which section they live in on the website; each section name is then used as a header

      Next you customize the Item template text; this template is used for each item that the server returned matching the search it was sent.

      Finally you can define what will appear in case there are no results returned.



      Finally, you can enable highlights; these highlights are different from the highlights in the results settings; it is just a style that is applied to your autocomplete window to allow users to see what they were searching for. In the example, this corresponds to the purple text that matches what was typed in the textbox above. The color and style are defined through a css class so you can change its appearance as needed.

      The opening a new window parameter allows you to customize where links clicked in the autocomplete will open, based on the data the server sent back to you.

      Finally there are "convenience" parameters that will handle script and style inclusion for you. If you're working on a DotNetNuke 5 installation, you don't have access to jQuery.UI natively. Or you may want to link to a custom jQuery.UI script; these parameters allow you to customize what scripts and styles will be included but shouldn't be necessary for most installations.


      I hope this overview of the autocomplete in Aricie.LuceneSearch will help you configure the system to your liking!

      You are not authorized to post a reply.