Forum: JavaScript / DHTML / AJAX Sep 21st, 2009 |
| Replies: 5 Views: 2,609 Something like this should work:
/**
* Return html numeric entities encoded string
*/
String.prototype.toHtmlEntities = function() {
return this.replace(/[^a-z0-9\.\-\_\s\t]/ig, function(c)... |
Forum: JavaScript / DHTML / AJAX Sep 18th, 2009 |
| Replies: 1 Views: 509 You can create or display and HTML Element, that has the message.
Example of creating one:
var msg = documement.createElement('div');
msg.innerHTML = 'Your message';
Then attach that div... |
Forum: JavaScript / DHTML / AJAX Mar 25th, 2009 |
| Replies: 6 Views: 1,145 newDiv.innerHTML = '<input type="file" name="' + divIDName + '" size="57"> <a href="#" onclick="removeAdditionalFile(this.parentNode, this.count)">Remove</a>';
this.count would refer to the... |
Forum: JavaScript / DHTML / AJAX Mar 21st, 2009 |
| Replies: 5 Views: 988 Take a look at the window.location object:
https://developer.mozilla.org/en/DOM/window.location |
Forum: JavaScript / DHTML / AJAX Nov 21st, 2008 |
| Replies: 1 Views: 1,774 You'll need to know a bit of JavaScript.
Basically, on each type of a few characters into the search input, you send the search to the server, and load the results.
eg: HTML
<input... |
Forum: JavaScript / DHTML / AJAX Jun 6th, 2008 |
| Replies: 3 Views: 14,322 Thanks for spotting that.
I didn't mention in my post, but the javascript should be executed after the DOM is loaded. This is normally implied if you're familiar with DOM scripting but it I can... |
Forum: JavaScript / DHTML / AJAX Mar 21st, 2008 |
| Replies: 14 Views: 4,405 Did you remove the SWFObject code? Looks like the site is loading in IE6.
What may be happening with the SWFObject is what I mentioned before, the DOM is being manipulated before it has... |
Forum: JavaScript / DHTML / AJAX Jan 31st, 2008 |
| Replies: 3 Views: 3,153 You can have JavaScript save cookies. This is done immediately, so page reloads are not needed.
Example JS:
/**
* Set a cookie
* @param string cookie name
* @param string cookie value
*... |
Forum: JavaScript / DHTML / AJAX Jul 1st, 2007 |
| Replies: 1 Views: 10,570 Your can write some JavaScript variables into the JavaScript code embedded in the HTML Document:
Assume you have a db table called config with the columns: name, value.
<script>
var configs... |