Mysidia Adoptables Support Forum

Mysidia Adoptables Support Forum (http://www.mysidiaadoptables.com/forum/index.php)
-   Questions and Supports (http://www.mysidiaadoptables.com/forum/forumdisplay.php?f=18)
-   -   Form Building (http://www.mysidiaadoptables.com/forum/showthread.php?t=4939)

Distortion 12-17-2015 09:21 PM

Form Building
 
I was wondering how to create a form? Any clues on how to do this is appreciated. :meow:

Hall of Famer 12-18-2015 09:42 AM

Well you can create/edit a form in a view class file(located at /view folder or admincp/view folder), and use Mysidia's Form or FormBuilder class. Below is an example of how to use the form builder:

PHP Code:

$form = new FormBuilder("login""""post"); 
$form->buildComment("username: "FALSE
     ->
buildTextField("username"
     ->
buildComment("password: "FALSE
     ->
buildPasswordField("password""pass"""TRUE
     ->
buildButton("Submit""submit""submit"); 

The above example creates a login form, similar to Mysidia's login form. You can look into the file class_form.php and class_formbuilder.php to see what methods these classes have for you to create a form dynamically.

Kyttias 12-18-2015 07:01 PM

I have some notes I made for myself that might help you with this here.

Distortion 12-18-2015 10:43 PM

Thanks! ^^


All times are GMT -5. The time now is 07:23 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.