forms

Storing Data from Forms without creating 100's of tables: ASP.NET and SQL Server

Let me first describe the situation. We host many Alumni events over the course of each year and provide online registration forms for each event. There is a large chunk of data that is common for each event: An Event with dates, times, managers, internal billing info, etc. A Registration record with info about the payment and total a...

jQuery: how to update a div when pasting in form (like facebook)

I have an input field where a user can paste a link. I would like to have a div appear as soon as the user adds a URL to the input field. Until now I used .blur and .onfocus, but the div only appears once I click outside the input field after pasting the URL. It's like on Facebook: as soon as you paste a link it will load a box without...

Saving form state after a page refresh

I have a list of checkboxes. If the page is refreshed before the user submits the form, I want the state of the checkboxes (checked or not checked) to be preserved. Ie: user selects option 1, option 4 and option 5. The page refreshes and option 1, option 4 and option 5 remain checked. I have looked into serialising then storing a cook...

Why put standard dialogs on a form?

I have some legacy code in C#, .Net 2.0 where someone dragged OpenFileDialog and SaveFileDialaog from the toolbox onto the form. This results in the open and save dialogs being instantiated when their parent dialog is created and remaining until the parent dialog is closed. The open/save forms are really only used in one place each for a...

vertical aligning text within dropdown or text input?

i have text input and select boxes be at a width of 40px... i want the text within these elements to be in the bottom half of the input field. I have successfully been able to do this in firefox (but NOT safari or chrome) by setting padding-top: 20px. i need this to work for safari and chrome however, these browsers seem to auto vertic...

CSS - Why file upload control doesn't follow the CSS width rule?

Hello all, I have the following HTML code: <input type='file' class="" maxlength="96" size="16" value="" name='headshot' id='headshot' style="width:21.5em;"/> It seems that the "size" value controls the real width of the "headshot" rather than CSS. In order to make it a idea width, I have to use the following code: <input type='file...

Form : sfWidgetFormDoctrineChoice, choose the method

Hello, In my form I want to use a widget Doctrine, but I can't change the method use to display the result of the doctrine query. I have make a function in my model : public function quartiers() { return $this->getQuartier(); } And in MyClassForm : $this->widgetSchema['list_quartiers'] = new sfWidgetFormDoctrineChoice(array('mode...

Disable Form Elements Using Event Capturing

Is it possible to make form elements unusable without setting the disabled property for each element? My idea was this: container.addEventListener('click', function(e) { e.stopPropagation(); e.preventDefault(); }, true); It behaves as intended for non form elements but it won't stop e.g. select elements from showing their opt...

Load Textboxes from array

My form has several rows of textboxes. The first row is named txtL000 through txtL009, the second row txtL100 through txtL109, and so on. Under each of these rows is another row of textboxes named txtT000 through txtT009, etc. When the user opens the form, I want to load the textboxes named txtL... with the strings in an array, depend...

vertical alignment for FORM INPUT FIELDS in safari and chrome

i have a select box with height: 60px. when i user clicks an option, i would want that option text to appear on the lower bottom of the select box...however safari and chrome automatically vertically aligns the text in the middle. I have tried increasing line-height, padding-top, margin-top...but these do NOT work for safari/chrome. ...

jquery - colorbox plugin, I need to submit form via ajax

If I'm using the colorbox plugin, how do I submit a form via ajax and then make a new modal out of the response? For example, the user clicks a link and a modal pops up. They fill out the form and click submit and then the modal should change to the next form. Then they fill out the next one etc... ...

Windows Forms look different in Powershell and Powershell ISE. Why?!

I have written a script which is basically a small wysiwyg signature generator for Outlook. We want our signatures to be in corporate colours, and semi-standardised - hence the requirement for this. I did the development work in Powershell ISE and all looked good. However, when I run the script just using powershell (as the users will) ...

Form POST returns 302 from within Joomla, works great outside

I have a form that submit a shopping cart to Google Checkout. The form works great on it's own, but when I put it inside of Joomla (using a content-type of wrapper), Google Checkout throws a 302, and the form page is loaded again. As I was writing this, I then decided to see what happens from the static form, outside of Joomla. It took ...

How do I create / access dynamic form fields in Django from within a View?

Hello, I have a system which keeps lots of "records" and need to integrate a component which will produce reports of any selected records. To the user, it looks like this: Click "Create Report" Select the records to be included in the report. Hit "Submit" and the report is displayed. To me I think: Load all records. Create a Repo...

CSS3 Animate/Translate DIV via onClick with Submit Button

I would like to see if anyone can direct me in the right direction to achieve the follow: When the user clicks on SUBMIT the DIV WRAP containing the form will slide off horizontally the page (ie, the 100% width container) showing a NEW DIV underneath (acknowledging confirmation). Of course everything is z-index'd and layered. Anyone w...

Forms are minimized on FormShow: random behaviour in Delphi application. Any idea?

I am experiencing an hard-to-track problem: when showing new forms (I create and show them at runtime) sometimes the form is minimized. I don't understand why, I say this problem in xp, Vista and 7. I tried to create samples to isolate the problem but on the samples I cannot reproduce it (=the forms always show not minimized). What ha...

Retreiving image uploaded from ASP.NET page

Hey guys, I've got an ASP.NET upload form on one page, where the user can upload an image. heres the code for that one: <%@ Import Namespace="System" %> <%@ Import Namespace="System.IO" %> <html> <head> <script language="VB" runat="server"> Sub Button1_Click(sender As Object, e As EventArgs) If imageupload1.HasFile Then ...

jquery - recursively attach "submit" handlers to forms with ajax?

I'm using a modal plugin (colorbox) that has an option "onComplete". I can do the following to achieve part of the effect I'm going for (this is just the "onComplete" option): onComplete: function(){ $('.ajaxform').ajaxForm({ success: function(responseText){ $.colorbox({html:responseText}); } ...

In Drupal 7, how do I show a new form that can edit data selected from a different form?

I have a tableselect form that lists several items. When a user selects one or more items, and clicks the edit button, I want a new form to show up that lets them edit the items. I have the new form structure being generated, but I can't get it to show up after the edit button is clicked. Currently, nothing seems to happen. I know that...

form action="javascript:block();" redirects to javascript:block(); url in firefox

Hi there, I have a function called block which simply return false; this is meant to stop the form being submitted so the ajax functions can capture its submit, however firefox seems to treat it as an actual url and loads the url javascript:block(); if i have action="javascript: return false;" then firefox doesnt even let the ajax fun...