hey guys,
I have a photo gallery page hosted on a CMS (Squarespace) which has some of it's own scripts which load the thumbnails asynchronously.
The actual large images however are not preloaded, so I decided to add my own script into the mix to just make the browser load those larger images into the cache in the background, like this:...
More of a general question here.
At the moment a lot of the projects I work on utilize server-side views to render the user interface, and spruce it up with some JavaScript here and there. That is all fine and dandy for smaller projects, but lately it seems like the .js files are growing rather large in size, and the stacks upon stacks ...
Is it possible to use JavaScript to get the actual size (width and height in pixels) of a CSS referenced background image?
...
Hi
I want to sort by
Month Day Year Hour Minute PM/AM (MM/dd/yyyy h mm tt)
I want to change this what does dd/mm/yy
However I am not sure how to do this
jQuery.fn.dataTableExt.oSort['uk_date-asc'] = function(a,b) {
var ukDatea = a.split('/');
var ukDateb = b.split('/');
var x = (ukDatea[2] + ukDatea[1] + ukDatea[0]) * ...
<html><body><script>
var matches = /(\w+)(\s*(\w+))?/.exec("aaa");
alert(matches.length);
alert(typeof(matches[3]));
</script></body><html>
I'm really new to regular expressions, so this may be a very easy question.
The regular expression above /(\w+)(\s*(\w+))?/ matches patterns like "aaa", "123", "my_var" or "aaa bbb", "123 456", "m...
I want to take size in bytes of image in page at the first load page, and then create a loading bar and show it loading similar preloader of flash. But I don't know if jQuery can take size in bytes of image or not.
...
The application I am working on has pages of setup data with lots of textboxes; each page having a save button. I have defined most of the pages as a *.ui.xml file and used the GWT 2.0 UI binding.
I would like to add a save button which is disabled onload and is only enabled after a user modifies the data into one of the textboxes.
I ...
I have the following markup:
<div id="items">
<div class="item">
<div class="item_box" id="id_1">
<div class="one" id="one"></div>
</div>
</div>
<div class="item">
<div class="item_box" id="id_2">
<div class="one" id="two"></div>
</div>
</div>
<div class="item">
<div class="item_bo...
anyone can help me....how to validate javascript date for this problem:
user select the start date and end date will be chosen to be more than 90 day from the start date.user can send form if end date below 90day...
from date code :
<input name="fromDate" type="text" id="fromDate" size="10" maxlength="10" onChange="">
<a href="#" name=...
I would like to be able to click a link in Website A that will autofill a username and password into Website B.
Can anybody provide me some ideas how to do this with JavaScript or PHP?
Many thanks!
...
I have an image, onclick on wich i make some ajax requests.
i need to pass a variable from $_GET[] to my onclick function, so i deside to do the following
<img id="img1" class="<?=$_GET['value']"?> />
and jquery
$("#img1").click(function()
{
how can i get the class value here???
});
Thanks
...
I want to compare if the chosen image equal to the desired image..
Here's the initial code but is not working
function mouseOut(txt){
var imgClick, imgOrig; imgClick = 'images/'+txt+'_onclick.png'; imgOrig ='images/'+txt+'.png';
if(document.getElementById(txt).src == imgClick){return false;}
else {document.getElementById(txt).src = im...
First the environment: the client is a mobile Safari on iPhone, the server consists of a Tomcat 5.5 fronted by IIS.
I have a piece of javascript code that sends a single parameter to the server and gets back some response:
var url = "/abc/ABCServlet";
var paramsString = "name=SomeName"
xmlhttpobj = getXmlHttpObject(); //Browser specifi...
I'm trying to get a rectangle partly transparent where the left part is opaque while the right part is more transparent if you go into that direction.
This works in Firefox, Chrome but not in Internet Explorer 7 or IE8. In IE all rectangles are displayed with the same transparent gradient.
function drawTest(y, pct) {
var recttest =...
Can anyone tell the jquery code for automatic refreshing of a page.
...
Hello everyone, i am currently working on a website and I need to make a chat application for it (as seen on some other questions i posted, haha)
Anyway, the gist is that I now have my website (on localhost for the time being), and my chat application. Now i need to make a button which, on click, will open the chat webpage in a pop-up w...
I have a Sketching app done in all HTML5 and Javascript, and I was wondering how I would create an Undo Button, so you could undo the last thing you drew. Any idea? Thanks!
...
<form method="post" name="test" id="test">
<input type="hidden" name="listname" value="qpaustin" />
<select name="customCity" id="customCity" onchange="javascript:onChangeHiddenValue(this.value);">
<option value="qpneworleans" >qpneworleans</option>
<option selected="selected" id="listSelectionActiveOption" value="qpnewyork" >qpnewyork<...
hi guys,
I am using color box, its really fun, but i am really stucked out by a problem that:
my form is opening in colorbox
i am using jquery for validation in that form
for which i am including validate.js in that page
the problem is that i am not able to see the js file, when i open the page in window it is ok but when that page is o...
I am looking to create an Eraser for a drawing app in Canvas, and I have this code
canvas.clearRect(x, y, width, height);
How would i implement it?
...