Member Avatar

I''m trying to process a form without page reload using jQuery post as shown below: <script type="text/javascript"> $('#settingsForm').submit( function(){ $('input[type=submit]', this).attr('disabled', 'disabled ');}); function scheck(){ var oldanswer = $("#oldanswer"); var newquestion = $("#newquestion"); var newanswer = $("#newanswer"); var url = "settingsupdate.php"; //This part of the code works fine. Errors are displayed normally if(oldanswer.val() == ""){ $('#output').html('Oops you left a field empty. Please fill it').show().fadeOut(6000); } else if (newquestion.val() == ""){ $('#output').html('Oops you left a field empty. Please fill it').show().fadeOut(6000); } else if (newanswer.val() == ""){ $('#output').html('Oops you left a field empty. Please fill it').show().fadeOut(6000); } else{ $('#FormProcessor').show(); $.post(url,{oldans: oldanswer.val(), newquest: …

Member Avatar
+0 forum 6
Member Avatar

I'm working on a website with a sign-up form. I've been able to perform validation without page reload, printing appropriate error messages.However i'm trying to implement an interface i've seen on a couple of websites, where a user is guided to fill certain fields like password that come with restrictions, as shown in the attached image (the nice blue guide on the right). I tried to 'inspect element' on pages where i've seen this but i wasnt able to decipher the code. How can i implement such fucntionality or where can i learn to do so. Thank you in advance.

Member Avatar
+0 forum 4
Member Avatar

I have an HTML dropdown list which i'm populating from a database. My question is how can i retrieve the value of a selected item from this dropdown list using AJAX? Thanks in advance.

Member Avatar
+0 forum 25
Member Avatar

Here is what i want to do, check the image attached, javascript to sum the values of text boxes in a row having individual total, i have this but not working function sum() { var txtFirstNumberValue = document.getElementsByName('ca_score[]').value; var txtSecondNumberValue = document.getElementsByName('score[]').value; if (txtFirstNumberValue == "") txtFirstNumberValue = 0; if (txtSecondNumberValue == "") txtSecondNumberValue = 0; for(var i=0;i<txtFirstNumberValue.length;i++) { var result = parseInt(txtFirstNumberValue[i]) + parseInt(txtSecondNumberValue[i]); } if (!isNaN(result)) { document.getElementsByName('total[]').value = result; } }

Member Avatar
+0 forum 3
Member Avatar

Guys please, i really need your help real urgently. I've search the web times without number but couldnt get anything tangible. I have a php loop like this . 'While($row=mysql_fetch_array($dbquery)){$username=$row['username']; print("<input type='submit' value='$username'>");}' now i have a jquery code to select each value contained in the hidden input 'var x=$("input").attr('value');' ! Then value x is sent to a php code via ajax when each button displayed is clicked. but in my success function in the ajax code, i set it that if there is a success, the value x should be alerted on the webpage. I.e, 'success: function(){alert("" x);}' but …

Member Avatar
+0 forum 4
Member Avatar

<html> <head><title>hi</title> </head> <body> hi deni </body> </html>

Member Avatar
+0 forum 1
Member Avatar

[CODE]<html> <script> function startEQ() { quake=5; parent.moveBy(0,quake); parent.moveBy(0,-quake); parent.moveBy(quake,0); parent.moveBy(-quake,0); timer=setTimeout("startEQ()",10); } function stopEQ() { clearTimeout(timer); } </script> </head> <body> DEMO IT HERE <form> <input type="button" onclick="startEQ()" value="Start an earthquake"> <input type="button" onclick="stopEQ()" value="Stop the earthquake"> </form> </body> </html>[/CODE]

Member Avatar
+0 forum 2
Member Avatar

I am not understanding this at all. I have to have 3 fish swim across the screen in different direction. But I can only get the one fish to swim. I have been looking ont he web and can not find anything that helps me. If someone can help me a web site or something thank you. I am ready to pull my hair out. For some reason I think it is something that is very small.But here is my code [CODE]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Fish tank</title> <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" /> <script …

Member Avatar
+0 forum 3
Member Avatar

Hi, I try to create a menu for the website of my friend. But I have a probleme with the reaction of event. My submenu close when i quit the section div. Someone can help me please? my code: [CODE] <html> <head> <title>test menu</title> <script language="javascript"> function ouvrir_menu(cible){ liens_cible="liens"+cible; document.getElementById(liens_cible).style.visibility="visible"; } function fermer_menu(cible){ liens_cible="liens"+cible; document.getElementById(liens_cible).style.visibility="hidden"; } </script> </head> <body> <div id="menu" style="position:relative;top:50px;width:200px;"> <div id="section1" style="width:200px;position:absolute;top:0px;background-color:grey;" onMouseOver="ouvrir_menu('1')"> Section 1 </div> <div id="liens1" style="width:198px;height:40px;position:absolute;top:0px;visibility:hidden;z-index:2;border:1px solid red" onMouseOut="fermer_menu('1')"> <div style="position:relative;top:18px;background-color:lightgrey;"> Lien 1 </div> </div> </div> </body> </html> [/CODE]

Member Avatar
+0 forum 1
Member Avatar

I am looking for a way to achieve the layout shown below using CSS or any other method that can accommodate the design and implementation. The "top" portion is a fixed area. The "left" area will be a list of text links that target to the "main" area.To be more specific, a list of links to profiles will be in the "left" area and I want the associated profile to show in the "main" area. I can do it with frames, but since it is not the best way or is not supported by html 5 i want some other …

Member Avatar
+0 forum 1
Member Avatar

how to show a javascript warning message for some specific words from a textfield. if a user write [B][COLOR="Red"]http://[/COLOR][/B] and [B][COLOR="Red"]/[/COLOR][/B] in a textfield and click on the Submit button of my form then a javascript will show a error message to the user and submission will stop. How to do it? Please give me a example regarding this. How i should edit this below given code: [CODE]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Javascript warning</title> </head> <body> <form name="formSurfwebtips" style="display:inline" method="post" action="http://example.com/sendmail.php"> <h1>Demo form</h1><br />URL<br /> <input name="reciprocal" type="text" value="http://" …

+0 forum 0
Member Avatar

I would like to place a footer at the bottom of my DHTML web page. The simple footer tag doesn't do what I want because the text in the footer is simply placed underneath the current text on the web page. What I want s for the footer to stay at the bottom of the window, regardless of what appears on the page. Here's a code for something similar to my page without a footer; [CODE]<HTML> <HEAD> <SCRIPT TYPE="TEXT/JAVASCRIPT"> function setup(ans) { lit = '' if (ans == 'anim') { lit = '<br><br>How many legs? ' lit = lit + …

+0 forum 0
Member Avatar

Hey all, I have the following HTML, adapted from a more complicated one I'm creating; [CODE] <HTML> <HEAD> <SCRIPT TYPE="TEXT/JAVASCRIPT"> function setup(ans) { lit = '' if (ans == 'anim') { lit = '<br><br>How many legs? ' lit = lit + '<SELECT NAME="q2" ONCHANGE="print(document.quest.q2.value)">' lit = lit + '<OPTION VALUE="">- Please select -</OPTION>' lit = lit + '<OPTION VALUE="Cat">4</OPTION>' lit = lit + '<OPTION VALUE="Sparrow">2</OPTION>' lit = lit + '<OPTION VALUE="Snake">0</OPTION>' lit = lit + '</SELECT>' } if (ans == 'min') { lit = '<br><br>What colour? ' lit = lit + '<SELECT NAME="q2" ONCHANGE="print(document.quest.q2.value)">' lit = lit + '<OPTION VALUE="">- …

Member Avatar
+0 forum 2
Member Avatar

Hi guys, I've got the following, very basic, working DHTML; [CODE] <HTML> <HEAD> <SCRIPT TYPE="TEXT/JAVASCRIPT"> function setup(ans) { lit = '' if (ans == 'anim') { lit = '<br><br>How many legs? ' lit = lit + '<SELECT NAME="q2" ONCHANGE="alert(document.quest.q2.value)">' lit = lit + '<OPTION VALUE="">- Please select -</OPTION>' lit = lit + '<OPTION VALUE="Cat">4</OPTION>' lit = lit + '<OPTION VALUE="Sparrow">2</OPTION>' lit = lit + '<OPTION VALUE="Snake">0</OPTION>' lit = lit + '</SELECT>' } if (ans == 'min') { lit = '<br><br>What colour? ' lit = lit + '<SELECT NAME="q2" ONCHANGE="alert(document.quest.q2.value)">' lit = lit + '<OPTION VALUE="">- Please select -</OPTION>' lit = …

Member Avatar
+0 forum 2
Member Avatar

What is the best book to learn ,PHP,Javascript,DHTML, and AJAX?

Member Avatar
+0 forum 1
Member Avatar

I'd like to modify a form on [url]www.formsite.com[/url] (form builder app): username: testuser password: password I would like to use the nicedit.com's inline content editor's js to transform my textarea's into a richtext area. At present the nicedit editor works well in creating the richtextarea. However, the KEY point is that I would like formsite's form to pipe in the the created html and render it with the html component of formsite. Currently, the pipe function in formsite will only put out the html syntax in it's html module. action seen here: [url]http://fs8.formsite.com/testform/form1/index.html[/url] So this would be: 1. checking out …

+0 forum 0
Member Avatar

hi i would like to know that how to create dropdown menu in mysite. anyone help me? thanks umesh daiya

Member Avatar
-1 forum 1
Member Avatar

hi on my blog page, i'm trying to manually add in group check boxes under groups. initially there is a list of group checkboxes from user's "my groups" to choose from, but i want to add more groups that don't exist in "my groups". drupal code for the form looks like this [CODE] <form action="/node/add/blog?" accept-charset="UTF-8" method="post" id="node-form" enctype="multipart/form-data"> <div> <div class="node-form"> <div class="standard"> <div class="form-item" id="edit-title-wrapper"> <label for="edit-title">Title: <span class="form-required" title="This field is required.">*</span></label> <input type="text" maxlength="128" name="title" id="edit-title" size="60" value="" class="form-text required" /> </div> <div class="body-field-wrapper"><div class="teaser-checkbox"><div class="form-item" id="edit-teaser-include-wrapper"> <label class="option" for="edit-teaser-include"><input type="checkbox" name="teaser_include" id="edit-teaser-include" value="1" checked="checked" class="form-checkbox" …

+0 forum 0
Member Avatar

Ok i have been working on this for a few days. I am having a hard time on this one. I am still new to the javascript/DHTML. I am suppose to use the fish images to create a fish tank on a Web page.The fish should swim across the screen from both directions. I was only able to get on of the fish to swim.. Can someone help me understand what to do. [CODE]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Fish tank</title> <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" /> <script type="text/javascript"> // <![CDATA[ var fish1Position = 0; horizontal …

Member Avatar
+0 forum 1
Member Avatar

Hi there all, just joined today loved this site already. My Question is that. i am trying to create 6 Menus for my Web. like Eg { home, about us, service ..... } and i want the images to change whenever the users mouse hovers the menu's. I got the scrip actually from online souce. But it was an example for one image Here are the codes: [CODE]function roll_over(img_name, img_src) { document[img_name].src = img_src; }[/CODE] And for the body [CODE]<A HREF="some.html" onmouseover="roll_over('but1', 'icon2.gif')" onmouseout="roll_over('but1', 'icon1.gif')"> <IMG SRC="icon1.gif" WIDTH="100" HEIGHT="50" NAME="but1" BORDER="0"> </A>[/CODE] Now i tried to multiply these five times, …

Member Avatar
+0 forum 2
Member Avatar

Hy! A friend of mine recently told me that, now, in 2011, [I]Ajax [/I]is a [B]pure [/B]synonym of [I]DHTML[/I], and that DHTML is an old world that we should not use anymore. He told me that it is called "Ajax" as long as you use standard technologies (XHTML, JavaScript, XML, DOM, CSS, etc.) to make dynamic webpages, even if there is no data exhange with the server. I'm not convinced of that. What do you think about it? What will be a "formal" definition of Ajax in 2011? ...not in 2005 or 2009... in [B]2011[/B]! :icon_wink: Is DHTML an "outdated" …

Member Avatar
+0 forum 1
Member Avatar

Hi! I want to parse data from tables in webpages , there are no problems when I parse regular HTML tables, but it seems to be impossible to get any data from dynamic pages that update themself automatically. Do you have any clue how to extract data from dynamic web pages? My goal is to read webpages with an application written in java, parse the page and clean the data and store it in a database.

Member Avatar
+0 forum 1

The End.