(Unfinished) Cómo crear un «Constructor de Código» (Code Builder)
Con Formidable Forms podemos crear un «Constructor de Código» en caso de tener la necesidad de escribir un código complejo y recurrente sin tener que copiarlo y editarlo de la última instancia.
En este caso de ejemplo, se construirá un código para un shortcode frm-set-get que incluirá varios parámetros en secuencia.
Paso #1
Crear el formulario
With Formidable Forms we can create a «Code Builder» in case we need to write a complex and recurring code without having to copy and editing from the last instance.
In this example, we’ll build a code for a frm-set-get shortcode that will include several parameters in a sequence. This shortcode is suitable to feed a «Dynamic poll system» (ANOTHER ARTICLE). The resulting code will be something like:
Step #1
Create a form by the usual procedure and name it Codebuilder form (or as you like). In Settings>Form permissions activate the options «Limit form visibility to ADMINISTRATOR» (or any role you like to use the code builder) and «Allow front-end editing» with the correspondent permissions.
Step #2
In our new form, we start by inserting a Text field, and in its Key Field we’ll name it codebuilder-code. This will be the field which will hold the main resulting code. The field label can be something like «Code».
Step #3
Add a Hidden Field. In Default Value of the codebuilder-code field, insert this code:
(Unfinished) Cómo crear un «Constructor de Código» (Code Builder) Leer más »