Search Results

Showing results 1 to 40 of 199
Search took 0.02 seconds.
Search: Posts Made By: ShawnCplus ; Forum: JavaScript / DHTML / AJAX and child forums
Forum: JavaScript / DHTML / AJAX 4 Days Ago
Replies: 4
Views: 255
Posted By ShawnCplus
I meant the Javascript code that is handling the response FROM the servlet. Not the Java code that is providing the response.
Forum: JavaScript / DHTML / AJAX 4 Days Ago
Replies: 4
Views: 255
Posted By ShawnCplus
Post the code that handles the response from the servlet.
Forum: JavaScript / DHTML / AJAX 5 Days Ago
Replies: 3
Views: 270
Posted By ShawnCplus
I think I understand what you were trying to say:

var ids = [];
$('#rightList > li').each(function(el) {
ids.push(el.id);
});
Forum: JavaScript / DHTML / AJAX 5 Days Ago
Replies: 3
Views: 292
Posted By ShawnCplus
You forgot the echo
vart pt = <?php echo json_encode($prt); ?>
Forum: JavaScript / DHTML / AJAX 8 Days Ago
Replies: 6
Views: 266
Posted By ShawnCplus
jQuery is actually one of the simplest Javascript libraries around. It's important to know at least a one be it jQuery or Prototype or Mootools, etc. The reason those libraries exist is to save you...
Forum: JavaScript / DHTML / AJAX 8 Days Ago
Replies: 6
Views: 266
Posted By ShawnCplus
Well that only applied to the document.querySelector part. jQuery supports pretty much every modern browser. http://jquery.com
Forum: JavaScript / DHTML / AJAX 8 Days Ago
Replies: 6
Views: 266
Posted By ShawnCplus
in Firefox you can use the built-in document.querySelector and document.querySelectorAll which use CSS selectors to find DOM elements. Similarly using the jQuery library you can do things like
...
Forum: JavaScript / DHTML / AJAX 8 Days Ago
Replies: 4
Views: 302
Posted By ShawnCplus
Just remove the surrounding click event ie.,

$(".run").click(function(){ ... });
Forum: JavaScript / DHTML / AJAX 8 Days Ago
Replies: 1
Views: 237
Posted By ShawnCplus
var bd = new Date();
if ((bd.getDay() > 0 && bd.getDay() < 6) && (bd.getHours() >= 8 && bd.getHours() <= 17)) {
//show
} else {
// hide
}
Forum: JavaScript / DHTML / AJAX 11 Days Ago
Replies: 1
Views: 287
Posted By ShawnCplus
Your image is being cached because it's the same URL. Add a random URL parameter to prevent it from being cached.

document.getElementById('captchaImage').src="captcha.php?_rnd=" + Math.random();
Forum: JavaScript / DHTML / AJAX 12 Days Ago
Replies: 1
Views: 317
Posted By ShawnCplus
You could give http://labjs.com/ a shot.
Forum: JavaScript / DHTML / AJAX Nov 3rd, 2009
Replies: 1
Views: 421
Posted By ShawnCplus
Inside the function basicAjaxSwitch you are defining a variable basicAjaxSwitch so it's being overwritten. Just use a different variable name inside the function.
Forum: JavaScript / DHTML / AJAX Oct 23rd, 2009
Replies: 1
Views: 582
Posted By ShawnCplus
A) Use code tags
B) This is a PHP problem not Javascript
C)

<?xml version="1.0" encoding="UTF-8"?> // <---- this is your problem because of the <?
If you're in PHP you have to echo the <?xml...
Forum: JavaScript / DHTML / AJAX Oct 22nd, 2009
Replies: 2
Views: 348
Posted By ShawnCplus
Show us your code otherwise we're just guessing
Forum: JavaScript / DHTML / AJAX Oct 14th, 2009
Replies: 3
Views: 563
Posted By ShawnCplus
You can do something like this

<form action="delete.php or whatever" onsubmit="return confirm('Are you sure?');">
That will pop open a box that says "Are you sure?" with yes and no buttons, if...
Forum: JavaScript / DHTML / AJAX Oct 13th, 2009
Replies: 2
Views: 666
Posted By ShawnCplus
You can't. Simple as that :) Even if you did disable it with javascript all the user would have to do is disable javascript and hit printscreen.
Forum: JavaScript / DHTML / AJAX Oct 12th, 2009
Replies: 2
Views: 385
Posted By ShawnCplus
It's the same for pretty much every browser.
document.getElementById('someidhere');
Forum: JavaScript / DHTML / AJAX Oct 12th, 2009
Replies: 5
Views: 492
Posted By ShawnCplus
It should be noted, however, that you can hack around it by not using an array but using an object like so

for ( i in ['key1', 'key2'])
alert(i); // 1, and 2 respectively

// BUT

for ( i...
Forum: JavaScript / DHTML / AJAX Oct 11th, 2009
Replies: 5
Views: 492
Posted By ShawnCplus
No you can't. i in your scenario is the key for each value so the only way to get the actual value would to do ['val1', 'val2', 'val3'][i] which would defeat the purpose :)
Forum: JavaScript / DHTML / AJAX Oct 9th, 2009
Replies: 1
Views: 480
Posted By ShawnCplus
You can't, the alert dialog uses the system's (or more accurately, the browser's) theme. If you want to change the way alerts look you will have to create your own modal dialogs.
Forum: JavaScript / DHTML / AJAX Oct 7th, 2009
Replies: 4
Views: 418
Posted By ShawnCplus
This isn't exactly what has to be done but it's a start. Take a look at w3schools.com for more javascript tutorials on opening windows

<script type="text/javascript">
var popupSomeWindow =...
Forum: JavaScript / DHTML / AJAX Oct 7th, 2009
Replies: 4
Views: 418
Posted By ShawnCplus
You could have the click be on an <a> tag with a target="_blank" which will open a new window. But if they have javascript enabled you can bind events to it with onlclick to open a popup and return...
Forum: JavaScript / DHTML / AJAX Oct 6th, 2009
Replies: 1
Views: 269
Posted By ShawnCplus
If you use a Connection: keep-alive header then the browser would never know when the AJAX call is finished and you've never get data back. AJAX calls are fairly inexpensive unless you're sending...
Forum: JavaScript / DHTML / AJAX Oct 6th, 2009
Replies: 1
Views: 223
Posted By ShawnCplus
You have to make an AJAX call to a server-side language which executes the command-line utility. Javascript can't access your server's filesystem directly.
Forum: JavaScript / DHTML / AJAX Oct 5th, 2009
Replies: 3
Views: 498
Posted By ShawnCplus
Well an HTML page is laid out like a tree.
/*
HEAD
|
BODY
\
DIV <-- SPAN's parent node
\
SPAN
/ \
Forum: JavaScript / DHTML / AJAX Oct 5th, 2009
Replies: 1
Views: 217
Posted By ShawnCplus
You should still make your checks for length before this but this will check for numbers like 1111111 and 999999


var phone_number = "9999999";
if (!/^(\d)\1{6}$/.test(phone_number)) {
...
Forum: JavaScript / DHTML / AJAX Oct 4th, 2009
Replies: 3
Views: 446
Posted By ShawnCplus
You have C = document.frmOne.txtThirdNumber.value *1 in your function so if that field doesn't exist and you try to perform an action on it ( *1 in this case) the function will die.
Forum: JavaScript / DHTML / AJAX Oct 4th, 2009
Replies: 7
Views: 413
Posted By ShawnCplus
Thinks you can do to try and help yourself:

Search the Daniweb forums for the 8000 other posts asking what AJAX is
Google for "AJAX"
Google for "AJAX tutorial"
Forum: JavaScript / DHTML / AJAX Oct 4th, 2009
Replies: 7
Views: 413
Posted By ShawnCplus
Neither of those links are bad, read them.
Forum: JavaScript / DHTML / AJAX Oct 2nd, 2009
Replies: 6
Views: 690
Posted By ShawnCplus
What language are you using the for backend? (PHP, ASP, whatever)
Forum: JavaScript / DHTML / AJAX Oct 2nd, 2009
Replies: 9
Views: 595
Posted By ShawnCplus
The poster marks the thread solved though admins probably have the ability it's not really their job to do so.
Forum: JavaScript / DHTML / AJAX Oct 2nd, 2009
Replies: 2
Views: 495
Posted By ShawnCplus
It does save newlines, but my guess is that on output you're not using nl2br. The browser ignores newlines when rendering text unless it is in a <pre>, <code> or tag with white-space:pre applied. So...
Forum: JavaScript / DHTML / AJAX Sep 28th, 2009
Replies: 2
Views: 337
Posted By ShawnCplus
You would setup a server-side script (using PHP or ASP or whatever your language is) that uses cURL or whatever your language uses to make and output the response. Then your AJAX call just points to...
Forum: JavaScript / DHTML / AJAX Sep 25th, 2009
Replies: 12
Views: 355
Posted By ShawnCplus
They're called regular expressions and they're the best thing since sliced bread. http://www.regular-expressions.info/
Forum: JavaScript / DHTML / AJAX Sep 25th, 2009
Replies: 12
Views: 355
Posted By ShawnCplus
var somestring = "Hello!@World, I have ^Spe_cial[ Chars";
if (!/^\w+$/.test(somestring)) {
alert('Bad Username');
} else {
alert('Good Username');
}
Forum: JavaScript / DHTML / AJAX Sep 25th, 2009
Replies: 12
Views: 355
Posted By ShawnCplus
w3schools.com is your friend
Forum: JavaScript / DHTML / AJAX Sep 25th, 2009
Replies: 12
Views: 355
Posted By ShawnCplus
A) Use <script type="text/javascript>, not <Script language="JavaScript">, it's old and the language attribute is deprecated
B) Your code doesn't actually do anything since it's never called (or at...
Forum: JavaScript / DHTML / AJAX Sep 25th, 2009
Replies: 6
Views: 511
Posted By ShawnCplus
You can get it done with just CSS

#some_id {
position: fixed;
}
Forum: JavaScript / DHTML / AJAX Sep 22nd, 2009
Replies: 11
Views: 993
Posted By ShawnCplus
It isn't a Netbeans project but it is a JSP AJAX primer (found by searching AJAX JSP on google...) http://www.ics.uci.edu/~cs122b/projects/project5/AJAX-JSPExample.html

It should also be noted...
Forum: JavaScript / DHTML / AJAX Sep 22nd, 2009
Replies: 11
Views: 993
Posted By ShawnCplus
Sure, it COULD be done with AJAX but there is absolutely no reason to. The term/acronym AJAX describes making a request to the server then receiving and parsing XML. There is absolutely, positively...
Showing results 1 to 40 of 199

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC