Skip to Content Skip to Menu

🌟Discover the Joomla AI Plugin that wrote its own story! - CB Editor Assistant 1.1now for Joomla 3, 4 & 5!
✍️ 5-Day Free Trial, then 🎯 save up to 30% with our 🛍️ Intro Offer (First 50 users, ends Dec. 25th)
🌲 Merry Christmas! Great savings on Professional and Developer Memberships! Get 25% off now with code XMAS-2024!

[TIPS] Create an easy search bar with Auto actions and Convert Form (Tassos)

  • fg88
  • fg88
  • OFFLINE
  • Posts: 14
  • Thanks: 5
  • Karma: 1
1 year 1 month ago - 1 year 1 month ago #335961 by fg88
Hi,

I see that a lot of people are looking for an easy search bar, that they can display anywhere in there website. Since "Universal AJAX search" (from offlajn) is no more available on joomla 4, there is no more possibility to do that.


I did one using :
- "CB Auto Actions" from Joomlapolis
- "Convert Form" from Tassos

1/ In Community Builder, create a field to put all keyword you want to search with :
First create a "Text Field" named "keywords" which is not visible, not editable, not required by user, but searchable and published

Then in CB Auto Actions, create an Auto action :
Type = "Field",
Global Tab : Triggered = "onAfterUserProfileSaved"
Conditions Tab : <none>
Action Tab :
Field : the "keyword" field created in step 1
Operator : "Set (Field = Value)"
Value : put here all the value you want to be searchable. For instance "[name] [surname] [city] " etc (all substitutions are supported)

2/ Create a form with the Convert Form extensions :
1 text field nammed « searchfield »
1 submit button

Go to > Behavior > PHP Scripts
 After Form Submission script :

{    $submission->form->successurl = 'htt//your_url/searching?cb_keyword='.$submission->params;}


 /searching is a published CB userlist page.

It will open the CB userlist, with only users that match with keywords searched in searchfield

You can display the "Convert form" wherever you want : module, page

The only thing I didn't manage to be complete is to set an AJAX suggestion
Last edit: 1 year 1 month ago by fg88.
The following user(s) said Thank You: pepperstreet

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum