I have a somewhat odd situation. I understand the premise of the live() and bind() functions, yet in a situation where i believe i dont need them, i seemingly do. I will explain.
I made an autosuggest in jquery. I included autosuggest.js at the top of my page. I then have an input field.
The basis of the JS works around:
$(".autosugg...
Hi
I'm using facebook open graph, new api, and i can do this:
<fb:login-button show-faces="true" max-rows="9" perms="email" autologoutlink="true" onlogin="window.location = 'http://www.example.com/facebook/facebook_test/'"></fb:login-button>
but when i read the doc if i need more options in http://developers.facebook.com/do...
I always have noticed this, including in versions before as well. About half way through jQuery's compressed version you'll see some regex:
[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^
The error appears to be at ['"]
I'm sure it's not really a syntax error, but all my code editors recognize it as one, which makes development a pain ...
I am about to spend a lot of time solving a problem, and I wonder if there is an existing recipe for this. It's a browser-based application (JavaScript and Dojo Toolkit) that is a client of a RESTful Web Service.
It uses Comet to automatically update the display. There is a callback function that processes every message received. [Bo...
Toying around with the WebKit browser in the new Kindle 3G, I noticed that window.screen.width and window.screen.height don't reflect the actual screen dimensions. The physical screen (or rather, paper) dimensions are 800 x 600. I get:
800 x 506 in landscape mode
600 x 706 in portrait mode
But interestingly, both Chrome and Safari (w...
I hate to admit it but I'm stuck trying to figure out how to do this.
e.g. pretending you have the following structure:
<div>
...
<div>
<ul>
<li>
<a href="..."><img class="foo"/></a><!-- "previous" -->
</li>
<li>
<a href="..."><img class="bar"/></a>
</li>
<li>
<a href="...">...
Traditionally we have always used xml in the response which is parsed by a Javascript method to execute post processes. I came up with a new, simpler implementation which uses a hidden input set by a requestAttribute and executed in an ajax callback.
JSP:
<%
String jsPostProcess = (String)request.getAttribute("jsPostProcess");
...
I have written some javascript whereas if you click on some divs those expand with some data.
it takes a few seconds to populate the divs.
So to avoid users getting frustrated I have done the following:
if user clicks on div then add animated gif (moving bar,...) on div
when data is ready event is triggered and animated gif is remov...
Hi I have a table with a div in it the table has 2 columns and both are 50%
In most browsers I can use offsetWidth to get the width of the article.
But in Safari the width is less or more than what it should be.
Any help would be greatly appriciated.
Regards
Richard
...
Hello.
I have a button on which I wish to validate a specific ValidationGroup in ASP.NET. This button is not a server control, but a standard a tag with an onclick event on.
I have multiple validation groups on this page, so by calling Page_ClientValidate() is not enough, as the other validators will kick in as well.
If your answer r...
Creating a document fragment using plain Javascript is dead simple: var docFragment = document.createDocumentFragment();.
However, in GWT, this does not appear to be available, though there is a DocumentFragment interface in package com.google.gwt.xml.client that does not appear to be applicable. Does anyone know of a way, either using ...
Im struggling with multiple complex statements in javaScript and wondered if anyone could point me in the right direction.
function findFlights()
{
var yourDestination = readTheDestination();
var yourAirline = readTheAirline();
var yourFare = readTheFare();
if (yourDestination == 'Choose your destination')
...
I have this code for replacing selected text: (it putts "1" and "2" before and after selected text):
var content=$("#text").html();
if (window.getSelection) {
// not IE case
var selObj = window.getSelection();
var selRange = selObj.getRangeAt(0);
content2 = content.substring(0,selRange.startOffset) + "1" + content.substring(selRan...
Hi,
I have a JSON tree that contains nodes and children - the format is:
jsonObject =
{
id:nodeid_1,
children: [
{
id:nodeid_2,
children:[]
},
{
id:nodeid_3,
children:[
{
id:nodeid_4,
children:[]
},
{
id:nodeid_5,
children:[]
}
}
}
I don't know the depth of this tre...
Hello Everyone,
I am new to javascript/jquery .
I have a small question.
I have some thing like the following in the java script file.
<button id="button1" onclick=click() />
<button id="button2" onclick=click() />
<button id="button3" onclick=click() />
so the click function looks like the follwoing
click(id){
/do some thing
}
s...
I want to use DynamicObject class under Jint and I have built a sample to do it. First assert is correctly passes but fails at second assert.
Is there any way to do it or do you know any other javascript engine that makes it possible ?
public void Jtest()
{
Jint.JintEngine engine = new JintEngine();
dynamic subject = new MyDyn...
I need to be able to print text into a form field from an <'a'> link.
Basically I have a list of job postings on one page, and an 'apply' link for each one. What then will happen is it'll bring up a form with the "Job Chosen" field already filled out with the "Job Title" from the previous page.
Something like
<a href="applyform.php?su...
What jQuery UI widgets are there, except from the official ones?
I know
Accordion
Autocomplete
Button
Datepicker
Dialog
Progressbar
Slider
Tabs
...
Hi friends,
How do i ensure that my textarea value should always contain the word "india" in javascript?
Actually i want to validate the textarea so that the user should always the word "india" in that.
Please help me.
Thanks in advance.
...
http://www.baelkopat.com/GECCo/goingGreenTest.html what I have so far.What I need to learn is to show the additional text when user mouseOver the link. i.e. when user mouseOver on "Activity Guide(PDF)" the "Download and print...." shows up...
I have pretty good experience with actionscrip not that very new to javascript... I was wonde wh...