FAQ Database Discussion Community
jquery,forms
I have the following delegated event installed on a checkbox inside a form that is present in every row of a table: jQuery(function() { var isChecked; $('#order-statuses-onweek tbody').on('change', 'form #order_status_p', function(event) { return $(this).parents('form').find('#order_status_s').attr('disabled', isChecked($(this))).toggleClass('disabled'); }); isChecked = function(el) { return $(el).prop('checked'); }; My problem is that no matter which...
php,forms,post,radio-button,radio
I am new to PHP and hope someone can help me with this. I have an HTML form with a number of inputs and textareas. On Submit I pass the form to another PHP page that generates an email with its values. For text inputs and textareas everything works as...
php,forms,post,radio-button
The code is given below shows the errors : <div class="field form-inline radio"> <form method="post" action=""> <div> <label><input type="radio" name="eatable" value="fruit_in"/> Fruit</label> </div> <div> <label><input type="radio" name="eatable" value="vegetable_in"/> Vegetable</label> </div> <div> <label><input type="radio" name="eatable" value="bread_in"/> Bread</label> </div> <div> <label><input type="radio"...
php,forms,symfony2,runtime-error
I have a form with a drop down and a set of checkboxes, i've used entity form field type to get the values via DB. it works with one of the entity but not with the other. i have this code seperately inside AddBadgesType there is NO AddBadges entity <?php...
jquery,forms,select,text,options
I'd like to change the text shown in a select form, without changing the HTML elements. This is an example: <select class="myclass" name="myselect"> <option value="0">1</option> <option value="1">2</option> </select> I would like to change the "2" string into "TWO", for example, like: <option value="1">TWO</option> I'm not able to select the right...
php,html,forms
Is it possible to use PHP variables as attributes in form inputs? I have the following variable already declared: $InStock //number of items in stock I would like to use this variable per below, but the code isn't working (the max constraint is not being applied to the field): print...
php,forms,exception,laravel,request
I am currently creating a website that, once the user arrives, they are greeted by a form with which they input their unique id and DoB. Upon entering the information and clicking submit, they are sent to the main form which has only a little information on it and the...
javascript,php,ajax,forms
ajax/javascript problem: I have an app which consist of multiple forms. What i want to achieve is to make a generic js function to submit forms to their respective controllers by getting form id.. I m successfully getting form ids in form_id variable but m unable to use them. I...
php,forms,post
I'm trying to submit a form to same page, so I want submit data, and then save into DB... And then update my page with new data... I do it in this way: <?php if (isset($_POST["matricola"]) && isset($_POST["pc"])){ echo "QUI"; $conn = dbConnect($USERDB, $PASSWORDDB, $NAMEDB); //seleziono il database e mi...
php,mysql,forms,variables,post
What i am trying to accomplish is Getting data from MySQL database into a table only containing rows where a user forgot to log in or out(done) Change the data in the table (done) Click submit and it updates all the data in the table into the MySQL database I...
php,forms,symfony2
I've inherited a Symfony2 project that has a form built as such: $builder ->add('Status', 'choice', array( 'choices' => array('' => '', 'PASS' => 'PASS', 'FAIL' => 'FAIL', 'INCOMPLETE' => 'INCOMPLETE', 'DROPPED' => 'DROPPED',), 'required' => FALSE, )) ->add('First_Name', 'text', array('label'=>'First Name', 'required' => FALSE)) ->add('Last_Name', 'text', array('label'=>'Last Name', 'required' =>...
html5,forms,twitter-bootstrap,bootstrap,html-form
I am using bootstrap and currently created form with 5 tabs in it. I have a form field called layer time in which I have 3 input fields namely hours, minutes,seconds. I want to set the maxlength of 2 for each field.But it is not working when I specify it....
javascript,html,forms
I can't seem to stop my form from submitting, even when it is shown that it is returning false. Could someone please help me spot out the error? Here is my html code: <form role="form" onsubmit="return login()" action="03_select_survey.html"> <!-- Username --> <div class="form-group"> <label for="user">Username:</label> <input type="text" class="form-control" id="user" placeholder="Enter...
forms,alfresco,alfresco-share
I am working on a custom form control, and need to define a new control-parameter of type string called helptext. I understand how to call it in my share-config-custom, how to use it in my custom form control, but not how to initially declare it. I see other control-params use...
javascript,jquery,html,html5,forms
As the image below illustrates, I have two forms and two buttons. Currently all the forms are visible. How can I only show the requested form "according to the option they have selected (from the blue buttons on the top)"? So, if the user clicked on the "send an invite"...
ruby-on-rails,forms,scaffolding
I have a scaffold, but it fails because the text of the users is longer than string permits. So I would like to change the kind of data, rails g scaffold Dreams Dream:string for Dreams:text, It is possible?
php,mysql,forms,get
I wrote a simple PHP survey application about movies and I am using one of the crowdsourcing services to collect data. In order to verify and rate workers, I have to generate VCODE (https://microworkers.com/vcode.php) in the final page and so workers can submit it as their proof of finishing my...
django,forms,error-handling,emailfield
When using an email field, attempting to submit a form with an invalid email address raises and error like this: What I like about this: doesn't reload the page, rather doesn't submit at all and instead displays an error the look Here is what I am able to accomplish currently...
javascript,forms,select,checkbox,tabular
I seem to only be able to find the answer to this problem in JQuery and I would really like a pure JS solution. I have a dynamically generated table that I build from a parsed JSON file. I added a checkbox for each row. My question is, do I...
python,html,forms,beautifulsoup,html-parsing
I'm trying to use BeautifulSoup to extract input fields for a specific form only. Extracting the form using the following: soup.find('form') Now I want to extract all input fields which are a child to that form only. How can I do that with BS?...
html,forms,twitter-bootstrap-3
I am using Twitter Bootstrap (version 3) and in the form, I am trying to put these fields two per line, but i cant figure it out how to do it.. Here you can see it in bootply what i have done.. <div class="col-md-10"> <div class="form-group"> <legend>1st sth</legend> <div class="col-md-2">...
javascript,html,angularjs,forms
I am currently working with AngularJS. Now I am wondering how can you save data in an html form between routes (angularjs routeprovider)? Does anyone has an example, experience or a link, which can help me to solve this problem? It would be nice to know, because like that a...
javascript,jquery,forms,validation
I got most of this form validation to work properly but the only issue is that when the form detects an error on submit and the user corrects the mistake, the error text won't go away. This can be confusing for the user but I can't seem to figure out...
python,django,forms
I am creating an application in django and I have the next problem: I create a form class in django, as I show here: class A(forms.ModelForm): class Meta: model = ModelA This way, the form will show a drop-down list with ALL the elements in the modelA, but what I...
ruby-on-rails,ruby,forms,ruby-on-rails-3,devise
I am having trouble viewing the nested attributes field in my form. I am in the jobs/new view and I want have a User form that creates a job as well as a user. I have everything in this answer Rails 4.0 with Devise. Nested attributes Unpermited parameters I have...
php,forms,symfony2,doctrine
I would like to know if symfony/doctrine can manage automaticaly the fact that instead of setting the value of my entity to null it could symply remove it. (by removing it I mean the records where the value equal null) exemple: I have a PICTURE entity linked to a VOTE...
javascript,angularjs,forms
I'm creating a form in Angular with Ionic. I don't want a red error class to be displayed unless a user has submitted the form. As such, my code looks like this: <form ng-submit="submit()" name="form"> <ion-radio ng-repeat="item in items" ng-model="data.type" name="type" ng-value="item.value" ng-class="{'error' : form.type.$invalid && formSubmitted }" </form> And...
javascript,forms,variables
I've created a form whereby the user enters details which are stored in variables or calculated depending on user entry. When clicking the button, a message will be displayed showing a message with the cost variable. The form clears but the message remains. The problem I have is that the...
php,forms,validation,drop-down-menu,server-side
I created a form using PHP. The form needs to be validated and it works for every field but the "rate our site" drop down menu. I'm using the same code from the form from other questions (name, email, etc.) for the "rate our site" drop down menu but the...
javascript,angularjs,forms,validation
The task is kinda primitive. I got a simple Angular form with various inputs and I'd like to highlight invalid inputs manually (e.g. on submit action). I tried to loop over invalid inputs, assuming that they must have some method to highlight an error, but unfortunately they don't. Same with...
php,html,forms
I am outputting all of my user's into a table on a page I have called admincustomers.php. I am then attempting to select EDIT on a specific users record. I then route that to a page called editusers.php. I then want all of that specific users information to be outputted...
php,forms,server,storage
I have an assignment that calls for data entries from a php form to be stored in a plain text file on the same web server. I created the php form page and the plain text file but I am unsure how to connect the two. I've searched the internet...
javascript,jquery,asp.net,forms
I have a form in asp.net page. Whenever enter key is pressed the page is posted back. I don't have any submit button in my form and using javascript to submit form. <div class="row-fluid" align="center"> <a id="saveConfirm" class="textDecorationNone"> <div class="btn btn-primary"> <i class="icon-ok icon-white"></i> Add </div> </a> <asp:LinkButton ID="btnCancel" runat="server"...
javascript,jquery,ajax,wordpress,forms
I have a form where and AJAX function runs on form submission to make sure that the data in the form doesn't conflict with data in the database. If a conflict is found, the AJAX function pops up a confirm() box. If the user clicks "OK", the form is submitted....
php,forms
This question already has an answer here: PHP: “Notice: Undefined variable” and “Notice: Undefined index” 11 answers The php code below echoes the image by using the variables $cat & $var, but when I fill the form & press submit, it shows following error redirecting to the same page...
javascript,jquery,wordpress,forms
I have a link set with display: none with the URL of a file that my users can download after correct submission of a Gravity Form. The things is I only want to show this link if submission was successfull. The only event I have found so far is gform_post_render,...
html5,forms
My sign up form works on HTML5 inputs (email,password,username..) also using patterns . Do i need to check the inputs with php to before inserting them in to mysql?
javascript,php,jquery,ajax,forms
There are a load of forms on the page with the same id: <form id="ok"> ... </form> <form id="ok"> ... </form> <form id="ok"> ... </form> I am using jQuery AJAX so that when the user submits one of the forms, the page doesn't refresh - the user can submit as...
php,forms,symfony2,twig
I'm trying to disable the frontend HTML5 validation for a filed in a form built in Symfony. In Twig, i use this code: {{ form_widget(form.email, {'attr': {'class': 'form-control input-lg','novalidate': 'novalidate}}) }} but the field is still considered as required. What am I doing wrong?...
javascript,html,angularjs,forms,validation
On event change the overflow value must get rejected. I have an input box in my form, where I want to restrict the user to enter only the numbers between 0 and 99999 only. But I don't want to disable the tab button functionality. The below code is working fine...
php,mysql,forms,redirect
I haven't found any solutions for my problem so I decided to ask. I would like to redirect my php script page after submitting a form, so I use header at the end of my codes! Interestingly, when I test it in my localhost, it works and redirects the page...
php,jquery,ajax,forms,email
I am trying to set up my page so that when I a form is submitted it emails and a message is displayed without refreshing the page. I have tried to do this using jQuery/Ajax however I cannot get any emails sent now Without the Ajax/jQuery, the PHP works just...
c#,asp.net,asp.net-mvc,forms,razor
I created an editor template to display text boxes included in a form. @model WebApplication1.Models.PersonViewModel <input type="text" class="form-control" name="@ViewData.TemplateInfo.HtmlFieldPrefix" value=""/> I simply want to include the 'form-control' class in all my input text boxes used to collect data for this model. public class PersonViewModel { [UIHint("_TextFormControl")] public string FirstName {...
python,mysql,django,forms,e-commerce
In models.py my Product model is class Product(models.Model): productName = models.CharField(max_length=20, default='1',blank=False,null=False, primary_key = True) userPhone = models.CharField(max_length=20, default='1') userid = models.ForeignKey(Account, default='1',null=True) productDesc = models.TextField(blank=False,null=False, default='1') productCategory = models.ForeignKey(Category, null=False, default='1') productPrice = models.DecimalField(default='0',blank=False,null=False, max_digits=6, decimal_places=2) picture =...
jquery,forms
Given the following very simplistic fiddle: http://jsfiddle.net/ofy3bhuf/ I want to prevent the form from being submitted if enter is pressed on the #no_return input, but it should be submitted as normal if return is pressed on any other input. As you see in the fiddle, I have actions on the...
jquery,forms,unobtrusive-validation
I have a form in an mvc application. If validation is triggered it disables every other button on the screen. I would like to allow the user to navigate away from the page where the form is, but I don't know how to do that. I tried to remove the...
javascript,jquery,forms,parsley.js
I am trying to set-up the multi steps form validation using the Parsely.js validation plugin. I followed the documentation here: "http://parsleyjs.org/doc/examples/multisteps.html" - but the only problem is I am going to have few forms that will have multi steps across the site and on some pages there will be more...
javascript,jquery,html,forms
I have a bit of javascript that finds an existing id and replaces it with a form. Within that form I'd like to be able to add javascript variables to the submit url. I'm not sure if that's possible or if I'm just implementing it incorrectly. $(document).ready(function () { $("#FB_cs_redirectTextBox")...
php,forms,fuelphp
Hello I just migrated from CI to Fuel.... I am using Fieldset class to auto generate form in the view.... The problem i am facing is I have multiple types of form templates i.e some of my models use twitter bootstrap horizontal inline form where as few models use custom...
php,html,forms
After inputting a color of choice the page should change its background color. It should be done using html forms. <body bgcolor="<?php $_GET["color"]; ?>"> <form method="get" name="color"> Background color:<br> <input type="text" name="color"> <input type="submit" value="submit"> </form> </body> ...
php,forms
I am trying to create a login page and have it to submit to itself and then redirect based on if user is authenticated. But for some reason everytime i submit, with wrong username or password, i would like it to show the log in screen again but it just...
ruby-on-rails,forms
In my app, I have a range_field where a user can select 0..100. But if they don't select anything, I want the form to submit "null" or nil as the value rather than a numerical value. Is this possible? If I use the below syntax, then everything works except value...
ruby-on-rails,ruby,forms,ruby-on-rails-4,controller
I have a contact form on a special page dedicated to this form. The dedicated controller includes: def new @message = Message.new end def create @message = Message.new(message_params) if @message.valid? MessageMailer.new_message(@message).deliver_now flash[:success] = "Thank you!" redirect_to contact_path else render 'new' end end Now I would also like to include this...
django,forms,django-forms
I have a form - class PermissionForm(forms.Form): def __init__(self, *args, **kwargs): super(PermissionForm, self).__init__(*args, **kwargs) permissions = Permissions.objects.all() for permission in permissions: self.fields[permission.name] = forms.CharField() Now since I don't know the field names, so how do I write the save method for this form?...
javascript,jquery,html,forms,twitter-bootstrap
I have a bunch of popover buttons that will open the same form. Now I need the button id value as hidden field inside the form. html buttons: <a type="button" class="pop" data-toggle="popover" id="1">Button 1</a> <a type="button" class="pop" data-toggle="popover" id="2">Button 2</a> <a type="button" class="pop" data-toggle="popover" id="3">Button 3</a> ... popover form: <div...
javascript,jquery,html,html5,forms
I have this form working almost perfect. If I apply discount to default price is changes, if I apply taxes it autofills too. But the last field with the sum of price after discount plus taxes is not working. Any idea? Here is the code and a Fiddle <html> <body>...
ruby-on-rails,forms
Ok so this is a noobie question. I have made a form that saves the data to a database from a form. I want to then display the data in a view or a controller that i got from the form. Here is my code for the form. Controller: msgs_controller.rb...
javascript,php,html,forms
I've programmed a contact form that sends out an email with the details of the inputs. On submission,(action="send_form_email.php") it takes me to the actual PHP file page. Is there any way to prevent this? I currently use this code below to bring me back to the page where the form...
php,mysql,forms,mamp
Customer will complete a form and enter a pathway where they will want the CSV to be exported to. The pathway is entered using the top section of the php (below): <form action="register.php" method="post"> Enter file pathway where CSV will be saved: <input type="text" name="username" required="required"/> <br/> <input type="submit" value="Enter"/>...
php,forms,woocommerce
I have a button that I've added to my product page, and I want to query the quantity in the woocommerce_quantity_input() control. For the life of me I can't find how to do that. I can get $product information, and $cart information, but I can't find how to get the...
php,ajax,forms
I'm trying to get a value from a form, then display it on posting of the form. I can get the value to appear in the second text field, once I have chosen an option using the Ajax Auto-Select, but how do I get that value shown stored into a...
php,html,forms
In my form a user can choose to upload a file. So, here's the correspondent field in the form. here is the html code: <p> <label>Allega fattura</label> <span class="field"> <input type="file" name="allegato_fattura" id="allegato_fattura" value="Sfoglia..." /> </span> and when the submit button is clicked, here we go: ... define("DIR_FATTURE","fatture/"); $fatturaFileName; $addedFattura...
javascript,jquery,ajax,forms,button
I have form validation set up to where it will create some Google Documents using Ajax requests and then submit the form to create an entry in a database, once everything in the form is validated. The actions to be taken after validation are specified by the submitHandler: submitHandler: function(form)...
javascript,php,jquery,ajax,forms
I have a form, that after validation, it executes two Ajax requests and then submits the form to create an entry in a MySQL database. The two Ajax requests return URLs (links) to Google Documents which are created by upload.php. However, the Ajax request for "agenda" comes across an error...
javascript,html,forms
Hi I am trying to implement a HTML form. Let's suppose it has 4 fields- Name , Age , City (dropdown- contains A,B,C,D) and Region. I want Region field to appear only when City selected is A or B and disappears if city is changed to C and D. Could...
javascript,angularjs,forms,binding
I'm looking for Angular to not update the model until the user submits the form. Or, in another way, to update the model only when the user has submitted the form. <form ng-submit="process()"> Value is : {{ model.property }} <input type="text" ng-model="model.property"> <button type="submit">Submit</button> </form> I was thinking of something...
javascript,php,html,html5,forms
After 2 days searching I give up. I have a form and need to add (autofill) taxes to the input total price but in a easy simple way: <form name="form" action="go.php"> <input name="cost" type="text"> <input name="costplustax" type="text" value=" here we autofill cost +19%> <input type="submit" value="ready to mysql"> I can...
php,forms,symfony2,events,entities
I'm working on a webapplication in Symfony2. I came to a point in which I need some advice/explanation from some one more advanced in Symfony. I have a part of my database that is set up as follows: I have cards that belong to a card attribute set and consists...
python,forms,input,flask,args
I'm working with Flask, and I am trying to submit some data that is not in input fields, to be added to the database. jinja code with the form(s) looks like this: {% for item in items %} <tr> <form id="adauga_{{ item.stoc_id }}" action="{{ url_for('adauga') }}" method="POST"> <td>{{ item.stoc_id }}</td>...
php,html,mysql,forms,search
This is a difficult one but easy for professionals. I have in mysql the fields: product name, mycost, sellprice and stock. Because I need to know how much I have in investment in my store by each product I created the follow on the fly calculation and is working fine:...
css,forms,jsp,servlets,post
My form: <form method="POST" action="AController"> <div class="userInput"> <table class="userInput"> <tr> <td><input type="text" id="username" name="login"></td> </tr> <tr> <td><input type="submit" id="submitRegInput" name="reg" value="Submit"></td> </tr> </table> </div> </form> I'm trying to style <input type="submit" id="submitRegInput" name="reg" value="Submit"> like this: #submitRegInput { background: no-repeat...
php,forms,laravel,model,laravel-5
I have form and i am using form model binding. My form is {!! Form::model($vehicle,['url' => '/pages/store']) !!} <table style="width:650px; margin-left: 4px;" > <tbody> <tr> <td>ID</td> <td>Model</td> <td>Brand</td> <td>License Plate</td> </tr> <tr> <td>{!! Form::text('id' ,null , ['readonly'], ['class' =>'textboxlong form-control', 'style'=>'height:23px;']) !!}</td> <td>{!! Form::text('model' ,null ,['class' =>'textboxlong...
vb.net,forms,button,focus
(I would say hello here, but Stackoverflow always removes it for some reason) My problem is that on my Visual Basic form the button that I use to close the form can be triggered by the enter key. This is a problem because my form opens a webpage that frequently...
php,forms,symfony2,entity,symfony-2.6
I got this error and I'm stuck since many hours Catchable Fatal Error: Argument 1 passed to Thinking\ThinkBundle\Entity\InYourMind::setThinkFriend() must be an instance of Thinking\ThinkBundle\Entity\InYourMindFriend, array given, called in /var/www/html/thinkroulette/vars/vendor/symfony/symfony/src/Symfony/Component/PropertyAccess/PropertyAccessor.php on line 410 and defined I searched for this issue and lots of results came up but I wasn't capable to...
javascript,php,jquery,ajax,forms
I have two AJAX newsletter subscribe forms on the same page (top and bottom). Both forms have the same ID. The top form works perfectly, however I'm unable to get the alert messages to appear in the bottom form. I found this question but wasn't sure how to implement the...
ruby-on-rails,forms
I have a form that is being build from a Product model. One of the form elements is a select list that has qty/price information, the form is being posted to a Cart model: <%= form_for @product, url: add_cart_path, method: :post do |f| %> ... <%= f.select :prices, price_list %>...
javascript,html,forms,window.open
I have one form with 2 submit buttons. The form generates a URL. The 2 outputs of the form are: It writes a URL to a hidden div which displays when they click the Preview button, and It launches the same URL in a new window when they click the...
javascript,forms,table
I am using javascript to show a sort of menu box with clickable links but I changed my mind and want to use links as forms now. <script type="text/javascript"> $('.mouseon-examples div').data('powertipjq', $( [ '<table class="tabulkajazyku"><form id="myformen" action="member" method="POST"><input type="hidden" name="jazyk" value="en"><tr><td><a class="odkaz_cerveny odkaz_cerveny_block" href="#" id="mylinken"><img src="/images/flag_en.jpg" class="vlajky"><div...
html5,forms,spring-boot,thymeleaf
I have to submit a form with around 30 input parameters(text, select, datepicker ). The fields are mapped to two classes. How to map each field to get the value in the controller. HTML: <form id="searchPersonForm" action="#" th:object="${person}" method="post"> <input type="text" class="form-control" id="person_id" th:field="*{person_id}"></input> <input type="text" class="form-control" id="child_id" th:field="*{child_id}"></input> </form>...
javascript,jquery,forms,google-analytics
i´m trying to track the selected option values. I´m getting this error in console when i track the form: Expected a number value for the field: "eventValue". but found: "string". html code: <select name="fornoyd_service_nybil" id="liste_nybil" class="liste"> <option value=""></option> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> <option value="5">5</option> <option...
php,html,forms,joomla
This question already has an answer here: How to get the client IP address in PHP? 13 answers Hello I have created an email form but am very unfamiliar with how to code in a section that displays a users IP address in the email that is sent. Here...
forms,ember.js
I have a form like this in a template: <form {{action 'add' on='submit'}}> <label for="name">Name</label> {{input value=name placeholder='Enter name' required="required"}} </form> Then I have the following route: import Ember from 'ember'; export default Ember.Route.extend({ actions: { add: function() { alert(this.get('name')); } } }); The alert is fired, but the output...
javascript,jquery,html,ajax,forms
The context: I have a form that asks for a zipcode, state, and city. Next to each input field I have two spans, one that shows a green checkmark if the input is good, and one that shows a red x if the input is bad. Naturally only one is...
javascript,forms,validation
I am trying to make my form validation work but I somehow can't make my name field to validate properly. When I write names in the field it will say that I need to write a proper name. What am I doing wrong? HTML: http://pastebin.com/EfNSkQkS JavaScript: http://pastebin.com/c6iUCYvr
html,css,forms
I'm tryin to write a form in html and css.my knowledge in html and css is not enough.i need help in creating this form.anybody have any idea how can i create this?please refer to jsfiddle.net thanks.
javascript,html,forms
So I have a dynamic form where certain inputs should only become available (and visible) based upon what a user has already entered. The way I'm starting to go about it has a wrong smell. It is straightforward enough to add material to the DOM <script> function addStuffToTheDOM(s1, s2){ var...
c#,windows,forms,lines
got a problem that can't deal with. I'm trying to number all lines in richTextBox, program does work, but it crashes when I click on my numbering button. Can anyone explain me please why? Code: public string temp = null; private void button1_Click(object sender, EventArgs e) { int i; for...
python,django,forms,django-forms
My form class from django import forms class Form(forms.Form): your_name = forms.CharField(label='Your name ', max_length=100) My app file __init__.py from django import forms from my_app.forms import Form from captcha.fields import ReCaptchaField def register(form): form.captcha=CaptchaField() register(Form) Code in __init__.py add an attribute captcha but it is not on the page. I...
jquery,forms
I have multiple forms on a single MVC view. When a submit button on any of the forms is clicked, I need to get all the elements of type input belonging to that form and enable them. This is what I tried but doesn't seem to be working. $(this).parents('form:first').getElementsByTagName("input").prop("disabled", false);...
php,forms,validation
This question already has an answer here: PHP: “Notice: Undefined variable” and “Notice: Undefined index” 11 answers I am trying to follow a PHP contact form tutorial from here! Seems pretty simple and I'm completely new to PHP. However, when running my project, I get so many "Notice" messages...
javascript,jquery,html,forms
I have following form, <form method="post" action="test.php" id="offer1Form"> <input type="hidden" name="c" value="3883316"> <input type="hidden" name="qtyadd" id="qtyadd" value="1"> <input type="hidden" name="buyid" id="buyid" value="multi"> <input type="hidden" name="multi" id="multi" value="11,1;150,1;182,1;27,1; "> <input type="hidden" name="promocode" value="<?php echo $promote_code1?>"> <input type="hidden" name="continue" value="<?php echo "...
javascript,jquery,forms
I have an web page that has a submit button. My submit button looks like the following: <button type="submit" class="btn btn-primary wait-on-click"> <span>Submit</span> </button> When a user clicks the submit button, I want to disable the button and let the user know that something is happening. To do that, I...
php,forms,codeigniter,validation
I am trying to write Form validation rules in my Controller to submit Change Password form in which I am checking the old password too. I am getting the old password(current) from db and placing it in a hidden input field. My Rules are simple and are given below $config=array(...
javascript,html,arrays,forms
I am attempting to create an online solver for the maximum subarray problem. https://en.wikipedia.org/wiki/Maximum_subarray_problem I planned on taking user-input numbers from a textbox and converting them into an int array in JS, however my JS does not seem to be running at all. Here is my HTML <!DOCTYPE html> <html>...
c#,forms,winforms,user-interface,user-controls
I'm making a console application that shows a form. I created the form from scratch. When I run the program, the form shows, but the controls I added don't show. My code: using System; using System.Windows.Forms; using System.Drawing; namespace form { public class main { public static void Main() {...
javascript,jquery,html,forms,popupwindow
I want to pop up the #popUpDiv after submit a form Script $(document).ready(function(){ $('#form').on('submit',function(e){ e.preventDefault(); $.post('post.php', $(this).serialize(), function(response){ $('#result').html(response); $('#popUpDiv').fadeIn(); } }); }); Form code below <form id="form"> Number: <input type="text" name="number" /> <input class="show" type="submit" Value="Submit" name="submit" /> </form> Result will be display here <div id="popUpDiv" style="display:none"> <div id="result">...
jquery,html,forms
I have a jQuery button that every time is pressed appends the inputs below to a form. My problem is that i need a way to also give name attributes (numbers) to the new inputs that jQuery produces. 1: <input type="file"> 2: <input type="file"> 3: <input type="file"> 4: <input type="file">...
javascript,php,html,forms
I want to pass the value of the selected radio to another page <div> <input type="radio" name="radio" id="return" value="return" /> <label for="return">Retour</label> </div> <div> <input type="radio" name="radio" id="oneway" value="oneway" checked /> <label for="oneway">Enkel</label> </div> </div> <div class="form-group right"> <button type="submit" class="btn medium black">Bereken rit</button> </div> I use the post method...
php,forms,preg-match
I'm trying to add some code that prevents a form entry if the phone number starts with 07405. I've tried the following with no such luck, any ideas? HTML field: <input type="tel" name="required[phone]" placeholder="Telephone Number" data-required="strict"> PHP: case 'phone'; $phone = (sanitize_text_field($fields['phone'])); if (preg_match('07045', $phone)) { $fields['valid_phone'] = $phone; unset($fields['phone']);...
html5,forms,indentation
I am replicating a page, and wanted to know if I need to indent the form tag, if it is nested inside of a div tag. e.g. <div class="signup-form"> <form method="post"> <input type="text" value="First Name"> <input type="text" value="Last Name"> </form> Or do I write it without the indentation. e.g. <div...