3,446 Topics
![]() | |
I was wondering how I make this actually work, without the ternary operator it works perfectly fine. Is it even possible to use a ternary operator in this type of situation? $("#link").html("website" + $("#search").val() + "" + t.games.check==true ? "?games=true" : "?games=false"); Also I will need to do multiple ternary … | |
Hello guys, i've being searching for how is it possible to get value of a form element i.e selection tag that was injected by jquery be access on submitting the form. All the form element value where posted except for the selection element that was injected with jquery. how can … | |
I am a beginner at Jquery, and am trying to implement easy slider onto a website. I have the slider on the page, but nowhere near the correct location. I think the issue is stemming from the fact there are two CSS files, and the screen.css file (which is tied … | |
The code below simply shows and hides a div (content) when you click on the heading (heading). <script type="text/javascript"> jQuery(document).ready(function() { jQuery(".content").hide(); //toggle the componenet with class msg_body jQuery(".heading").click(function() { jQuery(this).next(".content").slideToggle(0); }); }); </script> Demo - http://www.designgala.com/demos/collapse-expand-jquery.html By default, the content is always hidden - Is there any way to … | |
I have a file with the name foo.htm inside a folder abc. I am invoking the below script from another html page known as query.html in the folder abc. $.ajax({ url: '/foo.htm', method: 'GET', complete: function(a,b){ alert('complete-2'); }, success: function(a){ alert('good-2'); }, error: function(a,b){ alert('problem-2'); }, }); However, I am … | |
On index.php, change the functionality of your update button's click event so that: 1. when the user clicks on update button it "changes comment text to a textbox with the same value". This requires you to write a javascript to first hide your <div id="comment_1">the first comment</div> and then dynamically … ![]() | |
hi Guys...i have two jquery functions.first one is showing data in grid and we can also update data in grid.. 2nd one is filtering data like if we want to see data of 'farhad' so it will bring data according to 'farhad'; i want to merge both functions in one … | |
I have a question of dynamic elements in php loaded through mysql. The PHP code is as follow <?php $query = "SELECT * FROM `fee_table` WHERE fee_class_id = 6 "; $result = mysql_query($query) or die(mysql_error()); // Print out the contents of the entry echo "<table width='400'>"; echo "<th width='10' scope='col'>Qty</th>"; … | |
Hello everyone. I am building an Android app using Dreamweaver with the Jquery Framework and I am having trouble viewing source code of a given URL using javascript. I want the user to be able to type a url into a textfield, and then hit a button and have it … | |
![]() | I'm doing a registration page. it require the name, password, email, gender, nationality, date of birth and other things. I did the registration and it was good. but I need to add the validation and this is what I could do so far, so please if you could help me … ![]() |
i am facing another issue. i want to delete row via ajax and fadeout. i have write below code. this is successfully deleted the row but do not fadeout. var parent = $(this).parent().parent(); $.ajax({ type: "POST", url: "delete_order.php", data: "id="+id, success: function(){ row.find("td").fadeOut(1000, function(){ $(this).parent().remove();}); } }); return false; | |
Hi there, am I doing something wrong with the if-statement? it either doesn't evaluate the conditions I've got in there or throw an error. $('button').click(function(){ var button = $($(this)).text(); console.log(button); // this logs the value of button as night or day depending on the button I click if(button == 'day'){ … | |
Following code shows images before uploading them. It works well in chrome but it is not worknig in IE 6+. Please help with cross browser working of 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>Untitled Document</title> <link class="jsbin" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1/themes/base/jquery-ui.css" rel="stylesheet" … | |
so i have two files index.php and footer.php. and i want to add a jquery script to my index.php. so i did this and it works fine: index.php <html> <body> <script type = "text/javascript" src = "JQUERY/jquery.js"></script> <?php include("include/footer.php"); ?> footer.php <script type = "text/javascript" src = "JQUERY/jquery.js"></script> </body> </html> … | |
Hi there, I wonder if anybody can help me with this. I a a bit confused as to what $(this) and what e.target.nodeName represent in jquery. I had a look at this http://api.jquery.com/event.target/ but I am still not entirely sure, I hope somebody can clarify this. I run a little … | |
hi (1) e.x: arr1 ["aa.wav","bb.flv","cc.mp3"]; arr2 ["http://www.page.com/q.html","http://www.afaq.com/vb/showthread.php?t=77","http://www.daniweb.com/web-development/javascript-dhtml-ajax"]; if x[i] == any element (arr2) >>> do <iframe......> how to check if x[i] matches any element in arr2 ? (2) what is the best way to learn "javascript, ajax, dhtml, jquery" in the net ? thanks | |
I got a great response from this site. now my final thing is show gif loading image while getting data in Ajax.. my code is : function vote(id) { var result = new Array(); document.getElementById('sub-cat').innerHTML = ajax_image; result = $.ajax({ type: "POST", url: "ajax.php", data: "id="+id, async: false }).responseText.split("^"); document.getElementById('sub-cat').innerHTML … | |
html file <div id = "right_login"> <form id='login' action='login.php' method='POST' name=''> <h1>Log in to your account!</h1> <?php //print errors if(array_key_exists('log_error', $_SESSION) && !empty($_SESSION['log_error'])) { $log_error_r = $_SESSION['log_error']; echo "<span style='background-color:#D00000;'> $log_error_r <br/></span>"; unset($_SESSION['log_error']); } ?> <div> <label>Username:</label> <input type="text" name="username" id="login_username" class="login_field" value="" /> </div> <div> <label>Password</label> <input type="password" name="password" … | |
I am working on an ecommerce website for Glasses. Where I want to put a feature to try the glasses on your face or on some sample faces. The perfect example for this is one this site http://www.glasses2you.co.uk/prescription-glasses/gender/mens-glasses See the **Try in Mirror** option on this website. I can see … | |
Hi everybody. I'm building an site that will load a bunch of overlays into Google Maps. The overlays are static and already in JSON format to be loaded with AJAX. This all works fine, ajax request, json parse, adding overlay. But the json files are quite big, the largest has … | |
I am trying to include a datepicker from jQuery UI in my wordpress admin area (specifically in a custom meta box). I have it working, and it seems as though it is finding the stylesheet well enough, but it still looks a little 'off'. I know there must be something … | |
so iam trying to add a image slider in to my site. website where iam downloading this slider is: http://www.agilecarousel.com/ slider that iam download is called "Flavor 1". <html> <head> <link rel='stylesheet' type='text/css' href='agile_carousel.css' /> </head> <div class='slideshow' id='flavor_1'></div> .... //at end of html file //jquery verson file <script type … | |
My wordpress site has a custom built plugin that enables people to compare SIM only deals. The problem is that, on the front end, the deals table takes about 60 seconds load in IE8. It is ten times faster in firefox (about 6 seconds). The guy that built the plugin … ![]() | |
Hi all, I'm working on a little project that gives you synonyms for your sentence that uses Twitter Bootstrap. Everything is working all right, but I can't seem to change elements within the Popover! What's odd, however, is that when I used jQuery.length on the desired element, it told me … | |
can we make a pop up window using css and html? iam making a ecommerce website and when user buys a item. a window should pop up. and on pop up window it should give information about ur cart. here is a example i saw on a website. --------------------------------------------- the … | |
index.html <html> <body> <head> <!--[if IE]><script src="lib/excanvas.js"></script><![endif]--> <!--<script src="libs/prototype-1.6.0.2.js"></script> --> <!-- <script src="//ajax.googleapis.com/ajax/libs/prototype/1.7.1.0/prototype.js"></script> --> <style type="text/css"> canvas { border: 1px solid green; } </style> <script type="text/javascript" src="libs/jquery-1.7.1.min.js"></script> <!-- box2djs --> <script src="libs/Box2dWeb-2.1.a.3.min.js"></script> <!-- <script src="libs/box2d.js"></script> --> <script src='js/box2dutils.js'></script> <script src='js/game.js'></script> </head> <canvas id="game" width="600" height="400"></canvas> </body> </html> game.js http://pastebin.com/VAJE2tiB box2dutils.js … | |
I can't select elements within my popover for the Bootstrap framework. I've tried: $("#button").popover({content:"<span id="test">Test</span>", html:true, placement:"bottom"}); And tried selecting the inner span with: $("#test").html("foo"); This doesn't seem to work. Help! | |
HI, Am trying for onload page content from backend(perl) using Ajax .When Tried with simple CGIHTTPServer then, the pages is getting load as required . But as same page i moved to Apache Server , the content are not getting load .Am not getting any error also..:( how to debug … | |
hello everyone..i just wanna ask how i can increment the score after each answer given by the user and at last displaying result after questions finish. i want to store the result in database here's my code which is working fine with checking questions and displaying result and then next … | |
Hello everyone! I need help. How do I stop a typing text, how to hide/show a class/id, and load a content everytime a button is press. The problem in my code is it doesn't hide the website, everytime I click the button it always reload the content. Then when I … | |
Hi Admin..!! i want source code in php+ajax for a form, in such a way that, suppose i have a form in php, with 10 different fields, when the user fills that form, the fields next to gender should automaically change, like the remaining fields must be different for Male … | |
I wrote this script for my validation page.I used javascript and jquery mixed it all up. For some reason when I submit the gender validation doesnt work right, it keeps asking to validate but every other condition works. What I've pasted below is just the gender condition and the "if … | |
Hi there, I'm currently working on a site using [Big Cartel](http://bigcartel.com/) - an e-commerce online CMS. This means I'm limited to using their own proprietary language for grabbing data content (no PHP support etc...). I'm also using the [Supersized](http://www.buildinternet.com/project/supersized/) jQuery plugin to try and present present data to the user. … | |
Hy, i am a new here. this is my first post.check this website http://www.abswheels.se/ below slider there is an 3 colunms Marke(Main category) , Modell (Sub Category) and Motor(Sub Category). You can see the default selected menu below slider. When you select other main category than sub category and 2nd … | |
hello, what is that? everytime it works, but this time it does not $(function() { //jquery doc ready world = createWorld(); // box2DWorld ctx = $('#game').getContext('2d'); // 2 var canvasElm = $('#game'); return; canvasWidth = parseInt(canvasElm.width); canvasHeight = parseInt(canvasElm.height); initGame(); // 3 step(); // 4 // 5 window.addEventListener('keydown',handleKeyDown,true); window.addEventListener('keyup',handleKeyUp,true); }); … | |
Hello I am having an issue assigning a variable to a select box selection so that i can feed the variable back into future queries. Please see code below: <select name="room" id="msg-room"> <?php $query = mysql_query("SELECT * FROM rooms ORDER BY ROOM asc"); while($data = mysql_fetch_assoc($query)) { ?> <option value="<?php … ![]() | |
A)is used for 1) Inheritance in js(JavaScript)? Is this the ONLY way of Inheritance in js? derivedObj.prototype = new BaseObj(); or 2)adding properties/methods to an object, that added to Contractor of this obj? in this case old objects that already instantiated will have as null this property? B)prototype property used … | |
I can't seem to hide my paragraph the way i wanted it to be. I checked my code a lot of times and it seems correct. I don't know why it's not running. <!DOCTYPE html> <html lang="en"> <html> <head> <script type="text/javascript" src="jquery/jquery.js"></script> <script type="text/javascript" src="jquery/toggle.js"></script> </head> <body> <input type="button" value="hide" … | |
need help finding whats wrong syntax error in line 265 <?php function pay_upline( $refered, $level, $oamount ) { global $Db1; global $username; global $settings; global $today_date; $return = 0; $sql = query( "SELECT user.membership, memberships.downline_earns FROM user JOIN memberships ON memberships.id=user.membership WHERE user.username='{$refered}' and type='1'" ); if ( 0 < … ![]() | |
The code below seems to work great in Google Chrome, it hides a question in a div unless the question before it is answered. However, it doesn't seem to work at all in I.E 8. Can someone give me a solution on how to make it work in both browswers … | |
Hey guys! Remember jackbauer24? I'm the same guy, but for some reason can't log into my account. So this is my new account. Anyways, here is my code:- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html> <head> <!-- Bootstrap and jQuery UI CSS Libraries are included here --> <link … | |
file where I am getting error: http://pastebin.com/7Pk45vUf this error is thorwn at line: var tV = b2Math.AddVV(poly.m_position, b2Math.b2MulMV(poly.m_R, poly.GetVertices()[0])); I am starting to break the mouse, I cannot understand why it does not have this method. I am working by tutorial http://net.tutsplus.com/tutorials/html-css-techniques/build-your-first-game-with-html5/ but it is with old box2d versio and … | |
Hi , I am creating an website where I want to create worldwide partner . I got a reference site http://www.ogilvy.com/Offices.aspx which is developed in asp.net and flash but I want the same effect in php,jquery/javascript/ajax which is very urgent to do. Thanks in advance Subrata | |
For example > look at the code below <div class="s1 s2 s3"> //content goes here </div> This class is added dynamically, so i like to know how the find the second class (say for example : **"s2**"). and do some action.. | |
Hi I run into something peculiar. I have an html file linking to a local file jquery-1.4.4.js. Now, everything works ok in every browser but when I test the page in IE7 and 8 it fires the following error: SCRIPT87: Invalid argument. jquery-1.4.4.js, line 18 character 20135 and everything falls … | |
I have code which displayed a person's info in a table(fields:name, surname, address, etc.) and one of the inputs is a checkbox. The code is as follows: $("#table").append('<tr class="trow'+j+'">'+ '<td class="ids" id="z'+i+'">'+totrecs+'</td>'+ '<td>'+member[i].jdate+'</td>'+ '<td class="users" '<td id="contact'+i+'">'+member[i].fname+' '+member[i].lname+'</td>'+ '<td id="myaddress'+i+'">'+member[i].address1+' '+member[i].town+'</td>'+ '<td><input type="checkbox" name="whome" id="showMe'+i+'"'+ 'class="boxes" onclick="getMe('+i+')" /></td></tr>'); totrecs++; j++; … | |
Hi People, got a small issue. I have 3 select boxes, I mean dropdown list country dropdown list... then a state and then a town... I'm fetching data from database and loading it in the first dropdown list (country) On change of country, states get loaded and on change of … | |
Ok, this is not a question where I am having issues, but seeking an advise from you on JQuery plugin development. We have to agree, there are many JQuery plugins in different categories such as image gallery, form validations, effects and so on. I was about to create a basic … | |
The above pattern is supposed to be used as a workaround to avoid form resubmission, I.E If some data is entered into a form on page A, posted to page B and validated + saved on page B. Then if the page is refreshed, the browser will show an error … ![]() | |
I wrote a very simple validating script and I can't see what am I missing it just won't run at all <title>Untitled Document</title> <script src="http://code.jquery.com/jquery-latest.js"></script> <SCRIPT type "text/JavaScript"> (function checkform(){ var user = document.getElementById('user').value; if (user.lenght<5) { $("#username_error").html("Please enter a Username"); return false; } else {return true} }) (function checkuser(){ … |
The End.