Alosio, this is not the proper way to do it.
The proper and poweful way to do it is to create a template override:
1.
Inside your Joomla Template create folder:
templates/mytemplate/html/com_flexicontent/items/
2.
Inside this folder copy paste the file form.php from components/com_flexicontent/view/items/tmpl/form.php
3.
Find "foreach ($this->fields as $field) {"
Immediately after this line you can do something:
Code:
if ($field->name=='myfieldname1') {
// do something
}
Like skip the field:
Code:
if ($field->name=='myfieldname1') {
continue; // ...
}
To JUST PRINT the field without creating an editable html form field do:
Code:
if ($field->name=='myfieldname1') {
echo $field->label .": ". $field->html;
continue; // ...
}
To create a hidden form field that will have some default value, without letting the user change it:
Code:
if ( $field->name=='myfieldname1' && JRequest::getVar("id",0)==0 ) {
echo "<input type="hidden" name="myfieldname1" value="geographia" />";
continue;
}
The JRequest::getVar("id",0)==0 will detect that you are submitting new item, and not editing existing item.
If you were a developer you could do a lot more !!!
Regards