jquery

Is there a way to globally intercept events when jquery is used?

I have a site which has jquery included in the header. the application makes heavy use of jquery. now, that site uses ajax and shows up different message boxes when the user does something (it's a third party product used). I want to modify these boxes, but I need a piece of code to take action as soon as the DOM gets manipulated by ajax...

How to get notified about DOM changes with javascript?

I have a third party javascript app on my site that uses a lot jquery and ajax. Is there a way to get the element in the DOM, in which an manipulation has occured by javascript or ajax or jquery? I need to intercept these dom changes and inspect these in order to replace some strings (localization purpose). ...

Unbind jquery plugins

Hello, I'm sure this is simple but I'm banging my head! I'm using the excellent jQuery plugin editable (http://www.appelsiini.net/projects/jeditable). Users can create a form on the fly, and click to edit the title, the body of the text, whatnot. Every time the user creates a new question, I rebind the plugin like so: $('.edit').edita...

Carrying out a jquery command based on conditional css style?

I want to carry out two different functions based on the height of a div. How would I write out a conditional that checks the style before deciding? ...

jquery cannot use ajax response as context in IE

Hi there, thank you for taking the time to read my question. I have significantly rephrased my question after some new findings. My problem is that in my ajax callback, when I set the context of my query to be the returned html of my ajax call, it cannot find any elements. Some findings: The problem never occurs in Firefox The pro...

ajax posting data & sign problem

i want to pass & sign in text via ajax to php file i use encodeURIComponent() like that url: "add_process.php", data: "title="+ encodeURIComponent(title) +"& stages="+ values1, success: function(html){ but when i execute this, all data after & sign is truncated and don't save in database. Thanks ...

forcing a jQuery ready block to run after all other ready blocks

Is it possible to have one jQuery ready block executed after all others have done so. I have this in my master page ... <script type="text/javascript"> $(document).ready(function() { $("input[type='text']:enabled:first", document.forms[0]).focus().select(); }); </script> and this in one of my other pages ... <scr...

jHtmlArea returning empty string

I'm using jHtmlArea (http://jhtmlarea.codeplex.com/) WYSIWYG editor in one of my current projects. I have managed to integrate it in my forms in few seconds but the problem is that after submitting the form, the textareas changed to jHtmlArea editors return an empty string. I confirmed this with: var_dump($_POST); Does anybody have a...

clear type bug when animating something with transparent background

I,m making text slider using jquery (text scrols using transitions provided by easing jquery plugin). The parent DIV has some image as a background. Everything works fine in every browser, but not in IE 6,7,8. Strange distortions occur in IE when text and the IMG's are being animated. I learned recently that is fault of IE clear-type f...

Is Jquery broken? Why does Jquery Load fn not work in IE?

Jquery seems to have difficulty in IE (6,7,8) loading using the load() function when there are url's with parameters (example: getdata.php?id=2444) I am having this problem, but it seems this question is common and has never been resolved: see http://stackoverflow.com/questions/1174945/jquery-load-in-ie8-postget-not-working http://sta...

jQuery DatePicker and JQuery Modal Popups Issue in MVC

I have a situation where I have a form with: a view popup1 (with popup1.js) popup2 (with popup2.js) I have set the input boxes to have a class of either popup1Date or popup2Date in case the issue was coming from having them all set to the same date class. The isuse occurs if I go into popup1 - close - then into popup2 - select a da...

Run Function on every change in an input element: JQuery

Hello all, I have a form called "wizard". Everytime any input element is changed, I want a Javascript function to run and calculate something. I have the following: // update hidden field "channels" in wizard based on servers/cores $('form#wizard select[name=servers], form#wizard select[name=cores]').change(function() { var channels =...

Prevent .php file from being loaded outside jQuery request page

I have a page that is loaded within another page using jQuery. What I wanted to know is if it is possible to somehow block direct access to that page that gets loaded within another page. ...

How to intercept all jquery ajax events?

I have an big JavaScript application with a lot of ajax in there (third-party script). Now I need to intercept all ajax events, i.e. when a message from server comes back with transport text or message, i want this text / message to do replacements. problem: i tried with this, but it never reacts on any ajax event. It's from the jquery ...

catch variable in ajax success function to stop submit form

Hello, I have a problem within this code. I want to choose whether I will submit the form or not based on the outcome off the ajaxcall. If I hardcode it with return false; It stops going to the paypal site. That's why I want it to depend on a variable set in the ajax succes function. It is probably lost in the callback, so that's wh...

Why does $.change() fire on a submit button?

I have a $.change() event, but when a submit button is pressed, the change event fires again. It is only supposed to fire once when a text is inputted into a input text box. $('input:submit', top.document).bind('click', function (e) { alert("submitting") }); $('input').change(function (e) { alert("fire"); }); ...

jQuery Uploadify plugin with HTTPS

jQuery Uploadify plugin uses flash swf to upload files. I have implemented it on a HTTP website but now I want to do the same on HTTPS. It works fine on IE but breaks in FF by returning IO error. It must be flash security issue. Is there any work around to get the flash working over SSL. Any ideas or suggestions are welcomed. ...

JavaScript Whitespace Syntax Error

Why does this cause a syntax error for the return statement: var FOO = (function($) { return { init: function() { } } })(jQuery); Whereas this doesn't: var FOO = (function($) { return { init: function() { } } })(jQuery); Why is there a difference? ...

how can i translate this into ruby nokogiri ?

$("br",top.document).parent().contents().each(function() { textx = this.textContent.replace(/\s+/g, '') if ( this.nodeType == 3 && textx.length ) { $(this).wrap('<div id="uniqja__' + numero + '"></div>') } }) ...

Make image link with the same href using jQuery

Hi, Im trying to make my img link to this same image. Unfortunately it is not working. <img src="someimage.jpg" width="120" height="120" /> and this is what im trying to acheave: <a href="someimage.jpg"> <img src="images/6208606.jpg" width="120" height="120" /> </a> but this don't seems to be working var ImgScr = $('.gallery ...