On Sun, Feb 16, 2020 at 12:22 AM Dick Arnold <[email protected]> wrote:

> I have a personnel database which has to be edited to keep it current.
> I have created search parameters to find the person to edit.
> The exact name of the person is not always known, therefore the name field
> for searching can contain only a few of the characters.  This can create a
> list of several people.
> After the search parameters are entered a "Search" button is clicked and
> the output, if any, is displayed in a table.
> If the search parameters need to be improved, I want the original
> (current) search argument to be retained in the argument field so I do not
> need to re-type ALL the search parameters, just the ones I want to change.
>
> I have not been able to find a way to retain the value in the search input
> box,
>
> Does anyone know how to accomplish this?
>
> Here's the input for one of the input boxes.
>
> <input type="text" id="name_id" name="name_id" placeholder="Enter a few
> characters">
>

Set an attribute of value in your input tags, and use the form object in
your view to populate it. For reference
https://stackoverflow.com/questions/4880306/django-multiple-forms-and-keep-field-data-input-after-submission?rq=1


> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/92cfccd1-5916-4817-ae46-c612aa462610%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/92cfccd1-5916-4817-ae46-c612aa462610%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAD%3DM5eS8moJTCzxTt_ufn9qOxuhyXQkYAw-N2TS249oVKcweqQ%40mail.gmail.com.

Reply via email to