Quick Form
Dec 28, 2007What I am trying to make this script do is a user adds in a ID and it will execute that the URL with the user input. So for the user puts in, 123 the excuted URL is http://XXXXXXXXXXXXXXXX.com?u=123
View 2 RepliesWhat I am trying to make this script do is a user adds in a ID and it will execute that the URL with the user input. So for the user puts in, 123 the excuted URL is http://XXXXXXXXXXXXXXXX.com?u=123
View 2 Repliesif (document.getElementById('layer_s').style.visibility = "visible") {
if (form.s_size.value == ""){
alert("You must enter a size for your product.");
form.s_size.focus();
return (false);
}
}
Code:
<div name="layer_s" id="layer_s" style="visibility: hidden;">
<table>
<tr><td class="arial10bold">Size: </td><td><input type="text" name="s_size" value="" /></td></tr>
</table>
</div>
When I submit my form, it keeps giving me an alert box. It works when the layer is visible, but when its hidden, it doesn't work. After the alert box pops up, the layer becomes visible because of the focus(). I'm trying to bypass that condition when the layer is hidden.
I've got the following code being used to make a checkbox selected and readonly when a radio button value is selected:
document.myForm.valueName.checked = true;
document.myForm.valueName.disabled = true;
However when submitting the form values in email, the value of the checkbox won't submit with the checkbox value being disabled (if I comment out that second line, it works). Of course, I don't want the value able to be unselected.
Any suggestions? Can I make it readonly instead?
I'm trying to protect a form from being submitted by the website it resides on. I'm using the following code, but this just stops the form submitting if '@email.com' is in the form field. How can I say 'if this field contains @email.com then do not submit'?
Whilst we are at it, I also need to do the same with php if anyone also knows this?
Code:
if(value.itech03.value == "@itech.com") {
alert("Message here.");
value.itech03.focus();
value.itech03.select();
return false;
}
I am just wondering if dreamweaver still has a timeline or animations
section. I was able to quickly do this with dreamweaver 2 or 3, not sure,
and it was a bit like the flash timeline. Is there anything like this in
2004 MX?
I'm having one of those moments right now. Can someone explain why the following alerts "undefined" instead of "George"?
function test(){
this.worker='George'
[code]....
I have an array that I want to loop through and display the values of the array on the page as it loops (so I guess there should be a slight delay before the next one appears over it).
I want to loop though until a button is clicked.
I'm using quick search plugin (URL...) in filtering rows in a group of tables.The problem is that the old vesion of Quick search may act on multiple tables as long they have the same table_id while the new vesion acts on the first table only.
1-the number of tables is very large (in some pages may be 500 tables).
2-the action of Quick search is applied automaticaly as the user type any text in the input text box. so i don't know any way to make a loop to call the function once for each table.
I'm trying to do something a Quick Add like Google Calendar.
I found http://developer.apple.com/internet/...les/popup.html, but that isn't exactly that I want.
I need some guides or examples for create Divs with DOM, Css... and Show/Hide with DOM too. Google Calendar have Quick Add div with an input into it. I want to do that.
[URL] I solved the menu situation. Now, when a window isn't fully maximized, the page scrolls both horizontally and vertically. When it goes vertically, the image gets off-track. I just need to remove the vertical scroll capability from this javascript file: [URL]
View 1 Replies View RelatedI have a website at: [URL] The page works on Google Chrome, Mozilla Firefox, and IE-9. It sort-of works on IE-8, however, the problem is that on IE-8, there is about 2 seconds where everything is shown on top of everything else in a mess. This is bad.
The website is unusual in that it uses a menu to slide screens from right to left. This has implications. For instance, I need the menu to appear on all screens, so I use absolute positioning, and then use javascript to calculate the center position. The same goes for a logo image. And on top of that, some screens (which are really DIVs) have items positioned by absolute and relative positioning within them, and those positions are often calculated via javascript (and then set).
On IE-8, the result is not good. I think what is happening is that the browser first shows everything as it appears before javascript is run, and then slowly the javascript is run, which puts everything in the correct position. So initially, not only is everything in the wrong position, but different DIVs appear on top of each other.
I'm trying to set up a quick poll using AJAX which all works fine when using Firefox but running into issues via IE.
$(function() {
$('.error').hide();
$(".button").click(function() {[code]....
The issue I'm having is that although the form is being processed OK with data being captured in the database, once the form is submitted, the above script just seems to stop the rest of the page from loading. This only happens on IE and it must be something to do with the success function but as I'm new to JavaScript I don't know what I'm doing wrong.
I have a page on a website I am creating that has both a lightbox rel link and a quick calculator to work out a size of a product.Here are the links to the java files I am using:
<link rel="stylesheet" href="css/style.css" type="text/css" media="all" />
<link rel="stylesheet" href="css/jquery.lightbox.css" type="text/css" media="screen" />
<script type="text/javascript" src="scripts/jquery.js"></script>
[code].....
I have a form built and on the onclick event I validate all of the
fields and then if the form is ok, on the submit event I run a
javascript function to set a cookie and download a file from the
current window.
I have a cgi script provided by my web host to send the contents of the
form through email but they only show me how to use the cgi script to
send email through the submit event of the form.
ie. <form name="downloadform" method="post"
action="/cgi-bin/cgiemail/mailtemp.txt" onSubmit="return
Validate(this)">
Can I utilize the cgi script/link from my javascript function and still
send the contents of the form through the cgi email??
I've been struggling trying to get a small order form to work the way I want it to. Here is a link to the live page: [URL] And here is the code in question:
[Code]...
I have two questions...
Question 1 How can I make this piece of script act a little smarter. Look at the order form, I'm catering for up to 4 people and providing lunch for them. If they select 3 people and the spaghetti bol for lunch, it's only adding $10 where it should be adding $30. Obviously this is simple multiplication but since the values in my form are prices it makes it a little tricky. I'm guessing an onselect on the first part of the form which changes the pricing of the other items would be the way to go, but how do I do this?
Question 2 The "Total Price" is placed before the <form> tag by the script. This is ok but it's not where I want it. How can I position this text elsewhere in the document?
How does one cause a form element to appear ONLY if a certain form selection is made before it?
That is for example say there is a form element of type Radio called "format" so only if they select format value = normal then the form input fields called URL and Name are to appear as the next choices otherwise form input field Group and checklist Places are to appear as the next choices.
How would I put this together so,
<input name="input1" type="text">
<input name="input2" value="whatever is typed into input1" type="text">
I would like to be able to type something in input1, and see it type
into input2
I am having a problem with the submit() method that is driving me nuts. I'm using document.form.submit() with large text fields (approx. 2000 characters) and am getting a "Invalid Syntax" error. If I do the same thing with a text field of under 1500 characters, it works fine.
Is there some size limit here that I don't know about?
I've have a function to take the value entered in a form text box, add 50 to it and put the result in another text box.
When I enter 650.5 I get 700.5 exactly how I'd expect. But when I enter -650.5 instead of getting -600.5 I get -650.050 as though it is failing to parse the float due to it being negative. My understanding of parseFloat was that it recognises negative numbers. Is there a nice simple way to get this to work?
Is it possible to read a web page on some web site that contains a form. Then identify the fields in the forms. Then fills the fields with my data. and then submits the form as it submitted normally. I need to do this to automate for my final proyect , i need to fill many web pages remotly
View 2 Replies View RelatedI would like to have a main form (written in PHP) that has a "lookup" button next to a text field. When the user clicks "lookup", it should open a new window that lets them search (child.page1). When they enter a name or DOB into the search form, it submits the form through PHP (via POST), to a results page (child.page2). This displays all persons in the database which have a name or DOB == to the search term(s), with a checkbox next to each match. They click the checkbox (or alternenatively, a link), and return the checkbox value to the main window.
I have everything working right now, except that (child.page2) doesn't recognize the main window. If the data is entered on (child.page1), it works fine. I'm not very familiar with javascript.. is this even possible? I've considered using frames, to keep the parent-child relationship evident to the computer, but figured I'd check to see if there's an easier way.
I need to pass user input from a form to one database field. I'm relatively new to JS but the idea I had was to have several form elements and use JS to collect the users input and send all the values through a hidden element. What's happening is the variable names are being sent rather than the values. The code below is only passing to the next page. Limitations: I am editing an intranet site built by a 3rd party so a lot of the files we've been given are encrypted. I cannot change the method to post.
[Code]....
Here is the issue I am having: In my project, I have a index.php page with a sidebar menu and a div id called œcontent.The user can select different menu items and perform searches from the database and make updates to their account. Im using ajax to load all of the menu items and all of the forms into the div id "content" on the index page. The Forms all load into the target div as they are suppose to with ajax.
However, on the mysettings page I have two forms and two different buttons, one called save and the other called update. When a user wants to edit their account information and makes changes to their account they clicks on either button and the form processes the information and updates or inserts data into the database correctly but the problem is that after that the form or page does not display the form back in the div id "content" like how it was loaded originally in the index.php page. The problem is that it reloads or refreshes the form page without the index.php page being involved. That is does not get reloaded or updated inside the index.php page content div again.
What I would like do is have all of my forms process whatever is submitted on the page and display the results back inside the same content div on the index.php page again. I know I am missing something because all of my forms are doing the same thing. I am hoping someone can help me out. I would be very grateful for example code that I can learn from since I am still relatively new to web development. I am posting some sample code below.
[Code]...
Having a few problems with a form validation script. Its supposed to stop sending the form if key fields are missing, but it just sends them anyway!
Below is the code i use in the header to check for blank fields:
Code:
And now the code i use to action it:
Code:
From what i can see the fields match, it all links up correctly but still it will allow blank forms to be sent.
I've put together what I think is an illustration of my problem at [URL] Quite simply, I need to be able to access the elements of the form without referring to them by ID as the whole form is intended to be cloned. I intended to do this using parentNode and childNodes[] together with the 'this' keyword. My understanding of 'this' in this context is that it should refer to the HTML element calling the function, i.e. one of the radio button inputs. However this gives the error "Error: this.parentNode is undefined"
View 1 Replies View RelatedI have a simple three-field form in a UI Dialog that, prior to POSTing, I need to validate using the jQuery Validation plugin.Currently, if the user clicks the form's Submit button (the form's action for the PHP form handling is the page with the link that opens the Dialog in the first place) with a field not properly filled out, the Dialog just closes.Clicking again on the link that opens the Dialog form will show the form with the error message(s) that the Validator generated on the previous click of the submit button.How can I keep the Dialog open and prevent a POST until the form validates?
View 1 Replies View Related