Single line text (textbox) field
One of the field types used most is the single line text, also known as a textbox. It can be used to record anything from name, number to YouTube video ID.
Textbox settings
The above images show the possible settings including length of the textbox (in the form), maximum length (number of characters) of the text.
Example attribute: class="textbox"
Adding the the textbox data in your article
The template parameter used to 'paste' the content into the article is very simple and only consists of the unique field name in CAPITALS.
Template parameter: {$FIELDNAME}
*(where FIELDNAME = the unique field name filled out in the settings)
Example: Using a textbox for YouTube video ID
In this example we will alow users to submit a YouTube video ID. We use the AllVideo plugin from JoomlaWorks to render the video in the Joomla article. The YouTube video id can be found in the URL:
http://www.youtube.com/watch?v=k-OOfW6wWyQ
The Joomla article plugin code for AllVideo is:
{youtube}k-OOfW6wWyQ{/youtube}
In F2C we want to create this code in our F2C Template and add a field to our form for collecting the YouTube video ID.
1) Create a field in your submission form with (unique) field name called: youtube_id
2) In your F2C (main) article template add this code:
3) Create an article through the F2C Article Manager and see the result ... make sure to publish the AllVideo plugin!

