Questions tagged [form]

A web form, also called html form, is a special html element consisting of several input elements, that allows the users to enter and send data to the server. One of the most common type of forms are the contact forms in websites.

Filter by
Sorted by
Tagged with
0
votes
1answer
59 views

Using a custom field with different names

I want to use a flexible field name for a field across different forms thru my extension. My custom example field looks like this: defined('_JEXEC') or die; use Joomla\CMS\Factory; use Joomla\CMS\...
0
votes
0answers
10 views

Translation file for Contact form module in French?

In my Joomla website, I'm using the module type "Perfect AJAX Popup Contact Form": The problem is that my website is multilingual, and a translation in French doesn't seem to be available. No when ...
0
votes
2answers
243 views

Convert article to PDF?

I was wondering if anyone knows of any way to take the HTML content of a custom module which is placed inside an article and convert the HTML to PDF via the click of a button or so. So basically the ...
3
votes
2answers
165 views

How can I change the Class of SELECT fields that Joomla generates'

I've disable chosen.js so that all my <select> tags are plain HTML, but am so far unable to change the default class of inputbox to one of my choosing, (specificially from the Search Tools ...
1
vote
1answer
149 views

Form inside a backend component redirects me to index page

I got the function addNew() that creates a form inside a backend component. function addNew() { $route= JRoute::_( 'index.php?option=com_pelatol&task=insertyo'); $html.='<form action=...
2
votes
2answers
1k views

Preprocessing form data before saving to the database

I have a series of checkboxes on my form that together form an array when POST'ed. I want to save this data as a string instead (e.g., "##,##,##") before committing to the database. Here's what I ...
2
votes
1answer
1k views

Create form in frontend in a module

Am creating a simple custom search , where users will search using a droplist of option , i have successfully created the module , however i do not know how to show the form in frontend and how to ...
1
vote
1answer
156 views

JFormFieldList in Frontend -> Notice: Array to string conversion

I'm facing a strange problem. I'm trying to define a custom field for the frontend-view of my component like this: defined('JPATH_BASE') or die; jimport('joomla.form.formfield'); jimport('joomla....
3
votes
1answer
1k views

Populate multi select data into the custom list field of form inside user management

I am trying to populate multi selected data on to the user management form below the name field of the user. Here is what I have added inside the form, in order to display multi selected data from db....
0
votes
2answers
54 views

How to bypass deny direct access to edit link

I managed to edit a file in controller to allow for the edit article link to be directly accessed if a user has a particular username. This is a core edit, but it's a local website only only my pc so ...
0
votes
1answer
57 views

Associate template to getMailer class

I have created a custom form, after submit send email to recipient with JFactory::getMailer With this class can add body, for example: $mailer = JFactory::getMailer(); $mailer->addRecipient('test-...
3
votes
2answers
47 views

Form with nested set dropdown

I have to write front-end form in my component with dropdown list of categories and subcategories. Categories and subcategories amount should be unlimited. Should I use a nested sets model to do that?
0
votes
2answers
1k views

Editing the Joomla Login Form

I had installed a template from joomshaper. I'm trying to edit the login form of it. I already try to overwrite the mod_login/.../default.html file, but the form used by the template is not being ...
0
votes
1answer
83 views

Joomla editor field type text not posted when submitted

I'm working on a custom joomla module. It has a form with an "editor" type field. The fields are defined in the related xml file: <form> <fields name="main"> <fieldset name=...
1
vote
1answer
379 views

Custom dynamic fields - SimpleXMLElement in model and data info fields

Good morning, I have a question. I create my own fields in my own component. I'm using the "SimpleXMLElement" class. The form generates via getForm work perfectly: $newfieldset = new ...
1
vote
0answers
52 views

Variables in XML form definition

I'm creating a form using the Joomla XML form definition, and I want to create a range of integer values a user can select from. The number/integer field is fine for this use-- but I need to allow the ...
0
votes
1answer
160 views

Get ajax post data from another module in plugin

is it possible to catch ajax post data from another module in my plugin? I'm using SimpleForm2 https://allforjoomla.ru/extensions/mod-simpleform2 So this module creates a form and pass post data via ...
1
vote
1answer
27 views

Joomla 3 - Text area in Editor field breaks the Admin section

I have an editor field with some HTML code in it. The HTML code consists of a form and one of the form fields is a text area. When this code is added to the editor field, the Admin section of the ...
1
vote
1answer
285 views

How to make form action to work?

I'm learning how to make my own module on Joomla. MyModule mod_planejamentomensal.php is like this: //No direct access defined('_JEXEC') or die; require_once dirname(__FILE__) . '/helper.php'; ...
0
votes
1answer
125 views

How to access user-submitted values from a dynamic form?

I want to insert a row in my db-table with inputs from users. The form the users fill out is made with a foreach-loop: foreach ($results as $row) { echo '<div class="vm_kampe"><input ...
1
vote
2answers
369 views

Save multiple list custom field for component

I 've created a custom form field type class JFormFieldCategories extends JFormFieldList { protected $type = 'categories'; public function getOptions() { $db = JFactory::getDBO(); $...
1
vote
1answer
67 views

Don't add empty fields to database after submission?

Is there any PHP code which will allow me to NOT submit any empty fields to the database. I have a form with about 200 fields, and a lot of the times many of them are empty. How can I not add the ...
0
votes
1answer
474 views

Assign user to a specific group based on custom field selected

I'd like to assign a user to a custom group instead a some standard Joomla group, based on a dropdown choice. I've created a user group named "students". Then I added a new custom custom field for ...
0
votes
1answer
27 views

How can I make it pssible for users to login and add their products?

I want to build a form for the users of my website to let them easily add their products in frontend page under the name of their shop. To this end, which plug-in, component, or extension ...
0
votes
1answer
35 views

Component/software recommendation?

I want to know if you guys know of any good components or extensions which can perform the following: I want a user to be able to submit a form, view this form and edit it when they require. Every ...
0
votes
1answer
426 views

How can I save multiple dynamic values using check boxes?

I have a form which fetches and displays data from two databases (sessions, students) and allows a curriculum manager to select different combinations of students and classes by clicking check boxes. ...
1
vote
0answers
69 views

Joomla Calendar for versions >3.7

I'm trying to get a calendar form field to display without using XML. For previous versions, I called JHTML::_('behavior.calendar') and initialized it with Calendar.setup({args}) that would pass ...
1
vote
0answers
12 views

Change possition on Registration form of extra fiels added to users

I have added an extra field for membership number to Users but I cannot see how to specify where the field is displayed on the registration form. It comes as a separate section at the end after the ...
1
vote
1answer
579 views

What controller does front end form data post to using a component

I have been using Joomla for the last couple weeks and it seems straightforward so far and I understand the code in examples. I've successfully created a custom module that displays on the front end. ...
1
vote
3answers
499 views

joomla loadFormData

I am new in Joomla component development. I have used this document to develop the component. In this document there is a function loadFormData in Helloworld model as below: protected function ...
1
vote
2answers
507 views

Joomla 3.7 change value in database after form button press

I want to do something really simple, but have to use Joomla what makes it probably complicated because I have less experience in Joomla development. I have field with a value (a number) which is ...
1
vote
1answer
63 views

Overriding layouts from your module

I have already copied the renderfield.php and renderlabel.php files from ~/layouts/joomla/form/ to ~/modules/mod_mymodule/layouts/joomla/form but the overrides don't seem to be recognised. I have ...
2
votes
1answer
588 views

Is it possible to render the same fieldset multiple times?

I'd like to render the same fieldset multiple times for batch create and batch update. Is it possible to do this with JForms? Currently I have a form like this: <?xml version="1.0" encoding="UTF-...
1
vote
1answer
491 views

Server side form validation always returns true

I am trying to validate the input of my form on server side, but I always get true from the validator. What am I doing wrong? .../templates/customer_registration.xml <?xml version="1.0" encoding="...
1
vote
1answer
185 views

XML form related fields

I need to make a form with dependent fields. I have already tried a lot of options, but have not found the right way. As in the picture below, I'm trying to load a new XML file when you select an ...
1
vote
2answers
73 views

what component allows me to open a Virtual tour in a popup? [duplicate]

I'm trying to create a popup by modifying the source code through the editor. the code is as follows: <a href="#" onClick="window.open('mypage.htm','pagename','resizable,height=260,width=370'); ...
0
votes
1answer
157 views

Ajax in custom handler on client side

Im making custom formular and for one field I need a username ajax validation. I prepared a custom handler in jQuery: document.formvalidator.setHandler('usernamecheck', function(value) { jQuery("...
2
votes
1answer
53 views

How to develop a survey extension which prevents respondents from taking a survey more than once?

I'm looking for advice on how to make a survey for my Joomla production (3.6.4) site. A key requirement is to restrict respondents to only taking the survey once (i.e. preventing 'ballot-box' ...
3
votes
1answer
52 views

How to to create a multi-layered form system

I am new to Joomla and I am trying to create a form system whose questions will change depending on what was previously answered. The idea is to store this data into a database and allow other users ...
0
votes
1answer
232 views

Make one of select fields required in a form

I have this form. <?php // No direct access to this file defined('_JEXEC') or die('Restricted access'); JHtml::_('behavior.keepalive'); JHtml::_('behavior.formvalidation'); JHtml::_('behavior....
0
votes
1answer
211 views

Joomla custom contact forms (e.g. subject)

I have several links on my page that should refer to a joomla contact form. I want to have automatically filled in email subjects to that contact form for each link. I tried to solve it with get ...
1
vote
0answers
35 views

How does com_contact caching work when it has a form token?

I've been looking into conservative caching recently and felt I'd got my head around it. However, when I added it to a site, I was surprised to see that the core component com_content caches forms. ...
0
votes
1answer
58 views

How to create form on frontend

I am working on fof 2.4 project. In that I need to create a form on frontend. I have seen form in fof 3.0 in contactus sample component. But my project is in fof 2.4 Any one created form on front ...
1
vote
0answers
189 views

Joomla 3.5.1 - Ajax with PHP not send email [closed]

I'm having some problems with the action of an Ajax form. Here is the Javascript: <script type="text/javascript"> var $j = jQuery.noConflict(); $j(document).ready(function() { $j(...
5
votes
3answers
748 views

Editor stripping Script

I have a form which has been created in a CRM and then the code copied in to the website and updated to make it look and read better. However, when I copy the code in, the "script" at the bottom of ...
2
votes
1answer
124 views

Save multiple fields in DB

Please help advice. How to save multiple Fields in the database. I have a form with X number of fields. Fields added using JQuery <input type="text" value="" name="jform[phone]"> <input type=...
1
vote
2answers
809 views

Where can I find a good tutorial and/or example for creating front-end forms in custom components?

I'm building my first component for Joomla 3.x (I don't need support for 2.x). I've created my models (and unit tested them). I'm now ready to create the views. To start I just want to create a simple ...
0
votes
1answer
562 views

How to get articles categories in config.xml - Categories / SQL form field type?

With this given category field I want to show the article categories. <field name="import_category" type="category"label="test" description="test" extension="com_test" /&...
22
votes
1answer
7k views

How to save Custom Fields in Core components

I'm trying to add a single, simple field to each #__content item, and I've very carefully followed the tutorial at Adding Custom Fields to Core Components, substituting "content" for "contact". I now ...
2
votes
2answers
469 views

Check a form field for duplicates before saving

I have a custom component where the user can add some data. Here are the two relevant fields: <field name="title" type="text" label="Title" description="Please enter a title" ...