Forums

Default Values

SwingeyP 18 Jan, 2021
Hi all,

Q1. I want to populate some of my form fields with default values. I can't see where you do this.
It's just a simple text entry set with a mask for integer but I want it to default to 0 (zero).

Q2. Also. How can I populate a form field with a value from a database? _ The youtube examples show a table being populated with data but how do I populate one of my text fields with database data? The scenario is that a user logs in to Joomla. I then want to get the username and populate that in a field.

At present I have used some php to extract the username from Joomla as per the 'Name' in the screen shot but I want that data in 'What is your name'

SwingeyP 18 Jan, 2021
Hi all. I have fathomed the default value using 'placeholder'

How can I add a value from a database variable to a text field? as above?
Max_admin 23 Nov, 2024
Answer

use any value in your field's "Default value" setting which can be found in the Default Value behavior

Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
You need to login to be able to post a reply.