jquery

JQuery Sortable Effects

I have 9 boxes (div) on a page. I am able to move them to different positions, in a grid like fashion. So the basic sortable functionality is fine =) But I have a couple of questions: What if my boxes vary in width? Which they can do, if one changes the width (1/3, 2/3 and 3/3). Can I still have one 2/3 box and a 1/3 box on the same ...

How can I provide a 1 minute preview of a live flash video stream using Javascript?

I have a site that is streaming live videos, and I want to offer a one minute free preview to users before they pay for a stream. I am using JW Player - I was thinking of triggering a timer when the play button is clicked, and then removing a div containing the player once the timer is finished. I am already using jQuery on this page. ...

HTML Form. Add/Remove Form *Sections* (not single fields) on drop-down selection.

I'm creating a quote form where a user will select a service (logo, print, website etc.) via a drop-down and click add. A div of predetermined form values related to their choice will appear below in order for me to gain more detail on what they're looking for. Once they make a choice, and customize it's options, they can add additional ...

Help me understand this jquery code?

Its quite a lot... // DEFINE DEFAULT VARIABLES var _target=null, _dragx=null, _dragy=null, _rotate=null, _resort=null; var _dragging=false, _sizing=false, _animate=false; var _rotating=0, _width=0, _height=0, _left=0, _top=0, _xspeed=0, _yspeed=0; var _zindex=1000; jQuery.fn.touch = function(settings) { // DEFINE DEFAULT TOUCH SET...

How can I fade out a user notification rendered by HtmlHelper on page load?

I am using a HtmlHelper to display an update to a user as follows: In webpage: <%=Html.CourseUpdateNotification() %> In my controller: public ActionResult UpdateOnceOnlyCourseRecord(some parameters) { //validation code etc... //Save to database etc... TempData["CourseUpdateNotification"] = "Success"; return Redirect...

How to have multiple instances of a jQuery effect.

First, the disclaimer- I'm JUST starting out with jQuery. I apologize for my ineptness. :) My issue is that I'm attempting to use a jQuery rollover effect on a bunch of separate elements on a page. Right now, when I mouse over one, they all do the effect at once because they have the same class name, and jQuery is selecting all of them...

jquery - Can I retrieve (event, xhr, options) from .ajaxStart or .ajaxStop?

Hello all, Based on http://api.jquery.com/ajaxComplete/ .ajaxComplete( handler(event, XMLHttpRequest, ajaxOptions) ) .ajaxStart( handler(event) ) To my knowledge and experiements, the XMLHttpRequest and ajaxOptions parameters for the handler of .ajaxStart or .ajaxStop are null. I would like to retrieve the ajaxOptions inform...

How to display category link layout question?

I was wondering how would I be able to display my categories in steps 2 - 4 when I click a link so that all the parent and sub categories are displayed like in steps 2 - 4? All my parent and sub categoris should take me to another page. I genereate all my links using PHP. I use PHP, CSS, xHTML and JQuery. Step 1 Arts & Humanities A...

Placing fb:comments in an fb:dialog

I have a Facebook comment button a user can click on to comment on some content. My intention is for the button to open an fb:dialog that contains fb:comments markup so they can leave a comment. Below is my attempt: <fb:dialog id="comments_home"> <fb:dialog-title>Home Comments</fb:dialog-title> <fb:dialog-content> <div>...

Javascript runtime error in ASP.net MVC

Hi, I created a new ASP .net mvc 2 web application with that default template provided in VS 2008. I wanted to check the document.ready to see on how it fires. So in Site.Master I included the jQuery Scripts in the following way: " <script src="<%=Page.ResolveClientUrl("~/Scripts/JQuery/jquery-1.3.2-vsdoc.js")%>" type="text/javascr...

IE png with jquery and css question

function fadehomepage() { //Set opacity to 0 $('#showcase_home > div > a').css({'opacity':'0'}); $('#showcase_home > div').hover( function () { var selected_div = $(this).attr("class") + "_hover"; $(this).find('.' + selected_div).stop().fadeTo(...

Pasting to contentEditable Div inserts other HTML automatically.

I'm using a div with the contentEditable attribute to meet my need as a simple, cross-browser solution to expanding text-fields, but I've encountered an interesting problem. Here's the div : <div id="expanderInput" class="inputDiv" contentEditable></div> Here's where I grab it in jquery : var forwardsTo = $expanderInput.html(); I...

Only run code when variable is not equal to null

I'm having a problem. I have this code: setInterval(function() { $.ajax({ url: url, success: function(data, count){ var obj = jQuery.parseJSON(data); var content = obj.results[0].content; }}) }, 2000) Now this code is running every 2 seconds and making an ajax call. I keep getting the error that obj is null on ...

Trouble with syntax of adding setTimeout to existing jQuery script

I want to add a setTimeout to the following code so that there's a short pause before the fadeOut effect executes. $(document).ready(function() { $('#menu li').hover( function() { $('ul', this).slideDown(50); }, function() { $('ul', this).fadeOut(100); } ); }); This is...

Delay load of data for 2 seconds in jQuery ajax

I'm loading the search results via jQuery ajax in a div container. I would like the results to be shown to the user after a 2 second delay or after the user has entered at least 3 letters/characters in the textbox to search. How would I do this? jQuery code: $(".bsearch").keydown(function() { //create post data var postData = { ...

jquery / WordPress: apply infinite scroll effect to new content loaded via AJAX

So I am trying to use jQuery infinite-scroll plugin in combination with some custom jQuery that loads a new loop from a different PHP file with AJAX. The infinite-scroll works on the initial page content, but I can't get it to work with the newly loaded content. Here's how the AJAX logic works: click on a category Get category ID which...

freetextbox spellchecking not working in IE

I have an .aspx page and am using the FTB:FreeTextBox control. Seems to be working fine except in conjunction with the jQuery spellchecker. In IE the spell checking is not working in the textbox. Is there something specific that its looking for to get it to work in IE? ...

select specific text on page and remove it

Is is possible to select specific text string on the page directly without a id, class, etc... I have this text string "ERROR: AffiliateID invalid" that I would like to remove from the page. Is it possible? ...

Adding onclick handler using jQuery attr method does not work in IE

Following code works fine in Firefox. In IE(8.0) button "2" does not work. $('<button type="button" onclick="alert(1)">1</button>').appendTo($('body')); $('<button type="button" >2</button>').attr('onclick','alert(2)').appendTo($('body')); Question: what am I doing wrong? ...

Using jquery, how can I select all the DIVs in my document with ID names containing specific text?

Using jquery, how can I select all the DIVs in my document with ID names containing specific text? I want to select all the elements that contain 'parent', the problem is the string parent might be in the middle of the string. I've been trying to use: var allcontent_collection = $('div[id^=.*parent.*]') It is not working. Should it ...