I was writing a "pluginable" function when I noticed the following behavior (tested in FF 3.5.9 with Firebug 1.5.3).
$.fn.computerMove = function () {
var board = $(this);
var emptySquares = board.find('div.clickable');
var randPosition = Math.floor(Math.random() * emptySquares.length);
emptySquares.each(function (inde...
I'm working on a contact form for my church website.
The church has an email already registered (it's POP3) and the hosting company says their mail server is mymail.brinkster.com .
With all that information, how can you send the form using mail()? The server won't show PHP errors. The current code looks like this:
$headers = 'MIME...
I'm searching for a "suck less" WYSIWYG in-browser X?HTML editor that generates good HTML code.
(no <font>, <foo style="...">, <p></p><span></span><p><span> </span><span><span>blah</span></<span></p> and so on -- <b> and <i> etc is ok).
Should be easy-to-use as it is going to be used by people that do not know what HTML is.
Any s...
When the "Select All" check box is used, it also sends that check box and it's value to the server. How do I remove or omit it from the node list before sending it to the server using jQuery?
Thank You.
...
Hi folks,
I need to redirect a user to an external site though a POST request.
The only option I figured out is to do it submit a form through JavaScript.
Any ideas?
...
Lots of times we have to download files from the net. In IE we get to see the ugly download progress bar. In firefox we get to see a pop-up window opening etc.
However, I have never seen this being over ridden in any manner.
Until recently on the site
> *thesixtyone DOT com*
If we get to download a song free and click on the ok link...
Most session are based on cookies,like php/jsp
But as for mobile devices,there are quite a few that doesn't support cookies.
How to generate a unique indentify for each user in the same corporation that uses the same IP address?
...
I believe this is happening because whenever I perform an ajax request (upon which the loading.gif is set to display:block) the animation does not start at the same position. The starting point feels random which led me to think the animation still goes on behind the scenes in IE. In Firefox the animation starts from "scratch" all the ti...
Hi,
I have a web page that displays dynamic data which changes every 2 seconds. Data is selected from various data sources including Oracle. Currently, the page reloads every 10 seconds and runs a PHP script which retrieves the data and displays the page. I have other pages that gives a different view on the same data. This means the sa...
Hello,
Suppose I have this:
$('ul.child').slideUp('slow');
What would be the regex to find 'ul.child' and 'slow' (including quotes) in the above expression.
...
Hello,
I can't get my dojo working. I've tried everything.
Here is the code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/dojo/1.4/dojo/dojo.xd.js">
dojo.addOnLoad(functio...
Wondering why we need to share spring beans in case if there are no static data inside?
...
SELECT
*
FROM
company c
INNER JOIN
city ci ON ci.city_id = c.city_id
INNER JOIN
state s ON s.state_id = c.state_id
WHERE
MATCH (
c.name, ci.name, c.zipcode, s.name
)
AGAINST (
'los angeles'
)
...
Hello,
I have the following script that changes my image on a timer:
var da = setInterval( function() {
var current_image = document.getElementById('node_picture').src;
var image_index = current_image.substring(48,49);
image_index++;
if (image_index > 4) {
image_index = 1;
}
document.getElementById('n...
I'm wondering if there are any good non-native form inputs for web development? I am currently using the built in <input> controls. They work just fine, but for my application they are too big (especially on OS X). I am wondering if there are any libraries that I can drop in as replacements.
I am especially interested in ones that:
Ar...
I am trying to create a help panel for an application I am working on. The help file as already been created using html technology and I would like it to be rendered in a pane and shown. All the code I have seen shows how to render a site e.g. "http://google.com". I want to render a file from my pc e.g. "file://c:\tutorial.html"
This is...
I have the following piece of Javascript code on my web-page
var central_image = document.createElement("img")
central_image.setAttribute("src", imgs[curr_image_no - 1]);
central_image.setAttribute("name", "jpeg");
document.getElementById("photo").appendChild(central_image);
central_image.onload = getDimensions(); //function that alert...
Is it bad practice to concatenate objects when used in this context:
$this->template->head .= new View('custom_javascript')
This is the way i normally add extra css/js stuff to specific pages. I use an MVC structure where my basic html template has a $head variable which I set in my main Website_controller. I have used this approach f...
Hi everyone,
I have a strange jquery problem with multiple event handlers. What I'm trying to achieve is this:
User selects some text on the page
If the selection is not empty - show a context menu
If user clicks somewhere else - the context menu should disappear
I'm having troubles with the above i.e. sometimes the context menu a...
I have a number of images on a page contained within a single sprite image, these images must be contained within the single sprite due to other requirements of the site.
Whilst this is working fine in most browsers I have an issue on Opera Mini where it is not rendering the sprite at all and just displaying the whole image.
Is there a...