javascript

Web Service Call in JavaScript Causing White Screen of Death (WSOD) in Browser

Here's the specs: ASP.NET 3.5 using ASP.NET AJAX AJAX Control Toolkit jQuery 1.3.2 web services IIS6 on Windows Server 2003 SP1 SP1 SQLServer 2005 SP3 Site is SSL Infragistics Web Components 2009 Vol. 2 (using non-Aikido controls), UltraWebGrid and Tree control are main ones used. Here's the problem: I'm getting the White Screen of D...

Pass function value to Jquery function call back

I'm writing a script that loads different content based on the previously clicked links. (For an Android app). I'm having problems getting data to pass to my call back function. function load_current_div(id, refer){ $('#current-div').hide(function(){ $('#current-div').html(''); $('#current-div').load('content/'+id+'....

Iframe src set dynamically through JavaScript is being executed twice on Internet Explorer

Hello Everyone, I am encountering a very annoying problem with IE. Basically I need to set the source of an IFrame using JavaScript, however the source document is being executed twice not once during each call. The simplified HTML code is pasted below (I simplified it so that readers can understand it quickly. The source is being set...

JQuery html function on a td

Hello all, I am trying to place some html within a td that has an id but this doesn't seem to work. Can JQuery not put html in a td by using its id as a selector?? I do this: $('#total_match').html("<b>Test</b>"); Here is the td: <td id="total_match"></td> No errors occur and nothing appears in the TD - I view the source to confi...

Adding XOR function to bigint library

Hi, I'm using this Big Integer library for Javascript: http://www.leemon.com/crypto/BigInt.js and I need to be able to XOR two bigInts together and sadly the library doesn't include such a function. The library is relatively simple so I don't think it's a huge task, just confusing. I've been trying to hack one together but not having m...

grabing data from ajax request, is it possible?

When i need to get a content from a site, i use file_get_content() function, but now i need to grab a data, which loads after ajax request. so i can't mention the exactly url address. are there any algoritms to do such things? Thanks. ...

Javascript syntax with () - function scope

Possible Duplicate: JavaScript scope and closure I am not very familiar with the Javascript syntax bellow. Can anyone shade light about the sense of this block? For what purpose? (function foo() { alert('bar'); })(); Thanks in advance. ...

Php referrer works or not?

I need to know the referring server for a page on my site. Is there any safe method to check where the user "came" to the page FROM? I tried uploading this to my server, but this wont output anything at all when I write the adress to the file in the browsers adress bar: <?php echo $_SERVER['HTTP_REFERER']; ?> I need to check thi...

ASP .NET 4.0 How do I Redirect/Override the default CDN path for ScriptManager when EnableCDN=true

I am using the EnableCdn=true in my ScriptManager so that WebResource.axd and ScriptResource.axd are overridden with static links to JS libraries at the MS CDN service as follows: <asp:ScriptManager ID="ScriptManager1" runat="server" EnableCdn="true" /> How do I override the CDN URLs or service so that I can retrieve the scripts over...

Re-Databind on RadCombobox with ajax??

So I've been moving a lot of stuff into a webservice because it makes the whole thing make more sense to me personally. Also makes AJAX easier for me. Right now the user will say they want to save a new contact somewhere then, through the webservice, they are added to a database and that call returns the new primary key so that I can c...

Stop an input field in a form from being submitted

I'm writing some javascript (a greasemonkey/userscript) that will insert some input fields into a form on a website. The thing is, I don't want those input fields to affect the form in any way, I don't want them to be submitted when the form is submitted, I only want my javascript to have access to their values. Is there some way I cou...

Compare http_referer value

My http_referer says this: http://www.domain.com/search/?etcetcetcetc... I need to compare my http_referer to look for this: http://www.domain.com/search And if the first part of the referer is this, then do some code... Ex: if($_SERVER['HTTP_REFERER']=='http://www.domain.com/search'){ do stuff... But first ...

activate a css webkit transition using javascript onclick

I have an img that I would like to be able to click on and have my .image_click:active { -webkit-transition-duration: 500ms; -webkit-transform: scale(1.5); } stay scaled! I realize that css alone can't do this, as I achieve the transition when I click, but lose it when I release the mouse button. Is Javascript the solution for thi...

JQuery Validation Plugin not working when used on page that includes another page via AJAX

We have a long page that contains a bunch of different form elements. One part of the form is called remotely via AJAX and is populated in an empty div. This is the part which JQuery Validation plugin is not working correctly on. We have class="required" on the elements on this page, but they do not show up as required. I'm guessing it...

Looping and pausing after loading ajax content in Javascript JQuery

I have what I though was a simple problem to solve (never is!) I'm trying to loop through a list of URL's in a javascript array I have made, load the first one, wait X seconds, then load the second, and continue until I start again. I got the array and looping working, trouble is, however I try and implement a "wait" using setInterval or...

jQuery $(document).ready and svg-web window.onsvgload

jQuery of course requires everything to be inside $(document).ready = function() {}; similarly, svg-web requires: window.onsvgload = function() {}; Is there a correct, elegant way to combine these that doesn't introduce any problems? ...

jquery-ui accordion: adding rows without destroying and recreating?

I have a jquery accordion which I want to add rows to. I can accomplish this by calling .accordion("destroy"), adding the needed <h3></h3><div>... bit and then calling .accordion() again, but this destroys the state and closes any dividers which are open. Is it possible to add rows to the accordion without destroy and recreating it? ...

Using Cappuccino JS framework with PHP backend

I have php based application currently written using CI. I want to integrate Cappuccino JS framework at my UI layer. Does anyone know how can one go about doing that? ...

How do i fix this JS scope in GM_xmlhttpRequest

When i run this code alert 2 shows 6 different href links. alert 3 shows the last href 6 times. How do i make it use the same object (linkdom aka thelink) as alert 2. NOTE: This is in a greasemonkey script { var linkdom = thelink; alert('2' + linkdom.getAttribute("href")); GM_xmlhttpRequest({ met...

Ajax effect on console.log output

Let's look at the output of console.log. A click on the button changes the name if we use the function changeName(). But if we use the function changeNameAjax() (where response.name = 'Ford Prefect'), one click on the button doesn't change the name, only a second click does. Why? <!DOCTYPE html> <head> <script type='text/javascript'...