Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8241515
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T20:51:32+00:00 2026-06-07T20:51:32+00:00

I am trying to implement a search form which would show results gotten from

  • 0

I am trying to implement a search form which would show results gotten from the db when given (a) keyword(s), then updating a grid or lister with the search results.
Only i’m a bit lost as to how to update the grid…

I’ve looked at some similar questions (ie: How to refresh grid after update from modal form in atk4? ) but I can’t seem to get the grid to update after submitting my form.
code follows, any tips on what i’m doing wrong, or a better way to do this?
later i’d like the search and update several grids/listers from different db tabels, but if I’d get one to work that would already be a start… 🙂

$f=$this->add('Form');
$f->addField('Search','buscar', 'Enter keywords:');
$f->addSubmit('Search');

$g=$this->add('Grid');
$g->js(true)->addClass('myreload');
$g->js('myreload')->reload();
$g->setSource('conflicto');
$g->addColumn('nombre');        
$g->addColumn('idconflicto');

if($f->isSubmitted())  
{
     $keywords=$f->getElement('buscar')->get();
     $g->dq->where("nombre LIKE '".$keywords."'");
     $this->js(null,$this->js()->_selector('.myreload')->trigger('myreload')) ->univ() ->closeDialog() ->successMessage('Actualizado') ->execute();
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T20:51:34+00:00Added an answer on June 7, 2026 at 8:51 pm

    okay, so what you should do is following:

    if (isset($_GET["q"])){
        $q = $_GET["q"];
        $g->dq->where("field like '%" . mysql_real_escape_string($q) . "%');
    }
    
    if ($f->isSubmitted()){
        $g->js()->reload(null, array("q" => $f->get("q")))->execute();
    }
    

    not tested, but should work.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying implement a search activity which gets data from a mysql table
Im trying to implement the search feature in my website. when the search keyword
I am trying to implement Listview with search functionality, in which i am successful
I'm trying to implement search functionality in my app, which is very basic at
Trying to implement a search similar to here .This searches properties based on city,locality,property
I am trying to implement country search in my dummy application. Initially on home
Hey folks I am trying to implement a search functionality in a website using
I'm trying to implement a database search, by using match , against and fulltext
I am trying to implement depth first search algorithm using adjacency list representation of
I'm currently trying to implement some kind of search system in a program of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.