15,127 Topics
| |
Hello guys, I want to validated in my textbox only numbers shoud be entered and i found this code. <script> function isNumberKey(evt){ var charCode = (evt.which) ? evt.which : event.keyCode if (charCode > 31 && (charCode < 48 || charCode > 57)) return false; return true; } </script> then i … | |
I want to compare two images side by side. I am trying to grab and store the heights of the first column, to apply the heights to the corresponding image in the other column. Right now I can only get it to either get the first height or all of … | |
Hi! Need to refresh only div for cetrain time without loading any external content into that div.. Can you help me please?? | |
I am making chat application but i am confuse where i put setInterval().bellow function working well. function text_input(id,img) { $("#chat_box").keydown(function (e){ if(e.keyCode == 13){ e.preventDefault(); var textval = $("#chat_box").val().replace(/\n/g,'<br />'); $("#chat_box").val(''); jQuery.ajax({ type: "POST", url: "chat_input_insert.php?action=save", //sql querys data: "textval="+textval+"&id="+id }); jQuery.ajax({ type: "POST", url: "chat_input_insert.php?action=display", //sql querys data: "textval="+textval+"&id="+id+"&img="+img, … | |
hi i have been following a tutorial on how to build a image viewer using javascript for a web page i am building for my shop. i have not been able to get it to work and i have looked at the comments at the bottom and it seems to … | |
| Hi all. I went through 10 pages and couldn't find anything like this, although I would have thought I would. I'm simply trying to get the difference between two times. Here's my code, any thoughts on how I can fix this would be appreciated. <html> <title>timesheet</title> <head> <script> function addhours() … |
Hi I have a question with my code. I implemented drop down list populated from my oracle DB. So my question is, I need to populate the rest of the data into my <input type="number" min="currCutting" max="currQty" /> tag that pulled from the database according to the Head_mark selected from … | |
I am trying to load different data which are all in one JSON data from a drop down menu to a div area on the web page (eg if one clicks PC on the menu then the items related to PC in the json file will load and if Wii … | |
I have this script which is calling 10 divs indavidually from an external file. HTML: <a id="load1" href="#" data-id="1" class="load"> <img> </a> <a id="load2" href="#" data-id="2" class="load"> <img> </a> Javascript: $(".load").click(function () { $("#projects").html(""); $("#loading").show(); $("#projects").load("projects.html #"+$(this).data('id'), function () { $("#loading").hide() }) }) If load1 is clicked, it loads div1 … | |
Hi Folks, I need help with my code. Basically I am building an inventory progress web so that it pulls the value from the dropbox, and with onChange, getting the corresponding value from the DB, Update the value and reinsert the new value to the DB using submit button. One … | |
Is it possible to trigger the action of a form with a submit button that's outside the form tags? If so, how should this example be rescripted to make the input tag work outside the form tags? <html> <body> <form name="input" action="html_form_action.asp" method="get"> First name: <input type="text" name="FirstName" value="Mickey" /><br … | |
Hi I am working on dynamic add row. In that if a value is enter in ptype box it should disable the releated textbox filed based on the value. i written code but its not working can any please help me to solve this issue **html Page** <form id='students' method='post' … | |
Hello, I have a complex form and a 'Print' button which should print only the contents of a specific DIV. I am using the following function (i found on another forum): [CODE] function PrintContent() { var DocumentContainer = document.getElementById('divName'); var WindowObject = window.open('', 'PrintWindow', 'width=750,height=650,top=50,left=50,toolbars=no,scrollbars=yes,status=no,resizable=yes'); WindowObject.document.writeln(DocumentContainer.innerHTML); WindowObject.document.close(); WindowObject.focus(); WindowObject.print(); WindowObject.close(); … | |
how to set char limit in prompt box using javascript? | |
My Problem is How can i get(for display) image in "Chat.php" **e.g** i have get id. $new_id = $_POST['id'] Image path src got perfect My Jquery ajax function his as under function requestChat(name,id) { var img_src = $('#el').attr('src'); //path got perfect jQuery.ajax({ type: "POST", url: "chat.php", data: "name="+name+"&id="+id+"&img_src="+img_src, success: function(html) … | |
My email vaildation is working correctly now. But, I would like to alter the message color from black to red by styling it somehow. I have attempted such things as: { message = "Please, enter a valid email"; message.style.color == 'red'; writeMessage(message); return false; } The insertion being: message.style.color == … | |
Hello, i just coded for login script now i want to add "sha1" to my code due to security reason but it's showing an invalid login error i don't know the reason but when i use this withouht "sha1" it's working fine but i want to secure password into database … | |
hello my lovely friends of daniweb commuty. i have i jquery code of login popup basicaly it work when we click on a link to call it. but i want to excute it if a field is empty for it, i have add a code before `$('a.login-window').click(function()` and that code … | |
Hello. I am finally figuring out some basic validation. My main interest at this point is validating email. The script I got online contains the following, but does not check for "com", etc: if (email.indexOf("@") == -1 || email.indexOf(".") == -1) This works but does **not** check for "com". It … | |
I want to change content of a DIV which is in the TD (Table Tag); every div has unique ID viz. picked_cJN_031599, picked_cJN_031596; every div is prefixed with picked_cJN_ *and a unique ID came from database; I want to change the value of any div just by passing ID and … | |
I have a code in php that is being echoed in html: $tblAccounts .= "<td width=\"100\"><input title=\"$objRow->AccountCode\" name=\"chkAcctField[$objRow->AccountCode]\" id=\"chkAcctField[$objRow->Description]\" value=\"chkAcctField[$objRow->AccountCode]\" type=\"checkbox\" $strIsChecked>" . ucwords($objRow->Description) . "</td>"; now may problem is this... I don't know how will I get the value of the checkboxes clicked by the user.... when the names … | |
Need Help for. I have one texarea which i have write keyword then press **Enter key** result with <BR> generate. $("#chat_box").keydown(function (e){ if(e.keyCode == 13){ var textval = $("#chat_box").val(); alert(textval+' you pressed enter ^_^'); } }); ENTER : Hello, test OUTPUT: Hello, test (That not correct) Enter Key works perfectly. … | |
I know jQuery is recommended to write to the DOM, I want to understand how to write to the DOM in Javascript, considering how many programs use Javascript as there language, never know what I want to or need to develope for (*maybe a smart phone app in the future*) … | |
I have an element (a nav bar) on my website that has fixed positioning. How can I make it be fixed only up to a certain point? The url: http://www.peresidences.com/index.php I want the nav bar to be fixed positioning only until it reaches under the picture, and then it should … | |
**Problem** I need an jax pagination in YII, The problems are * its not showing the required results for the first time. ie. it is showing the complete result * When clicked on more, it again shows the complete result below that section as it is **What Needed** * i … | |
I'm new in jQuery charts, can anyone help me please? Below there is a static chart that I must populate with dynamic data. I have create the JSON file with but I don't know how to call these data. Thanks in advance. <div class="top-stats-panel"> <h4 class="widget-h">Daily Sales</h4> <div class="bar-stats"> <ul … | |
I have build simple chat box. One Text box -> Enter msg One button -> Submit One Textarea -> show message which enter in "Text Box" How could i do using jquery + ajax.? Give me suggestion. Thank you | |
I am making a cms for a booking app and the admin will be able to see the number of bookings at any moment. How can I do it so that the above updates continuously with ajax...like facebook newsfeed for example. So far the only ajax I have made is … | |
I am making a game for my computing class and the objective of the game is for the player to move around the grid and collect all of the passengers in the game and deliver them to the base before they run out of power. I have managed almost everything … | |
I am making a form which contain two input suggestion fields, 2 datepicker and three select fields. I want to make my form ajax based and show result in div when any field is changed. Just like farecompare.com I almost created a form but form start loading when i click … |
The End.