label – PHP Database Form https://phpdatabaseform.com Generate web form from database. Simple. Fri, 26 Dec 2014 16:02:10 +0000 en-US hourly 1 https://wordpress.org/?v=7.0.4 set_label() https://phpdatabaseform.com/docs/set_label/ Tue, 15 Jul 2014 04:18:00 +0000 http://phpdatabaseform.com/?p=336 set_label(mixed $col, mixed $label) : $this

Set form element label

Parameters

mixed $col
  • Database table column name
mixed $label
  • Label

]]>
Change Form Element Label https://phpdatabaseform.com/examples/change-label/ Sun, 06 Jul 2014 00:39:35 +0000 http://phpdatabaseform.com/?p=295 By default form displays database column name as input element label. You can change it with method set_label().

$dbForm = new C_DatabaseForm("SELECT * FROM Employees", "EmployeeID", "Employees");
$dbForm -> set_label("EmployeeID", "Employee ID");
$dbForm -> set_label("LastName", "Last Name");
$dbForm -> set_label("FirstName", "First Name");
$dbForm -> set_label("BirthDay", "DOB");
$dbForm -> display();

Live demo

]]>