I'm trying to work with XML DOM for the first time as I need to grab a value from a SOAP request. I've been following this: [URL], which says modern browsers won't parse xml files from another server for security reasons. How would I got about doing this then? I've been using the price of crude oil as an example [URL] and want code portable enough to put on something like Tumblr, so I don't think I can actually save the file locally first.
- two websites, one on domain1 and the other on domain2 - domain1 opens a new window which is a javascript app from domain2 - domain1 needs to communicate with the javascript app on domain2
The problem occurs in that last step. Browsers don't allow script access across domains for security reasons, rightly so. Nonetheless, I still need to communicate with the application. I can reload the window passing the necessary commands through the url, but this is slow because the whole javascript app must reload.
Anyone have any ideas about a way around this limitation that would be semi-efficient, at least more efficient than reloading the app? Signing the script isn't an option for cost reasons. I have control over both sites, so I can do anything that needs to be done.
I am wanting to make an ajax call across domains. Im attempting to call an external api with json data and (hopefully) receive a response. It's a mapquest api to obtain driving routes.Is there a mechanism in jQuery that will allow me to make a cross-domain ajax call?
I am working on this web site with some of the pages at a different domain name. It is actually one web site, but some of the pages are at a different domain name (different root, too) although the IP address is the same.
Basically, there is one main window, and a pop-up window. They need to "talk" to each other - mainly access properties to see what page they are on.
As, the web site is on two domain names, there is a security problem when the pop-up window tries to read properties in the main window, or vice versa.
Is there anyway to share information between the two? Or is it hopeless?
function validateEmail(strValue) { var objRegExp = /(^[a-z]([a-z_.]*)@([a-z_.]*)([.][a-z]{3})$)|(^[a-z]([a-z_.]*)@([a-z_.]*)(.[a-z]{3})(.[a-z]{2})*$)/i; return objRegExp.test(strValue); }
what should i add to reject email addresses from hotmail.com and yahoo.com?
With Google Analytics, you have to create a new profile for each domain, and post different code on each domain.
I'd like a traffic stats script (or website) where you can just add the same code for any domain, and that domain will be automatically tracked, even if it's a new domain. So if I have 100 domains and then add the same code to the 101st domain, it will track that domain fine.
Doesn't matter if the script needs to be hosted on your own server, or if it's 3rd party like Google Analytics. It can be commercial too if it's got an unlimited domain license. Anyone know of something like this?
I have a site that uses 2 domains to forward to the IP no. (a .org.uk and .co.uk). The site uses the Google Map API for a map on the site, however the API key is locked to the individual domain (I do have two keys for both the domains). I found the following Javascript which is supposed to switch the key depending on the domain that is accessing the page.
i have an ajax script that requests data from a database. Some of the fields contain html. I would like to know the easiest way to parse an xml file that looks like such:
<response> <poster>Poster name here</poster> <title>Title goes here, may contain a link</title> <text>html content here</text> </response>
i can't seem to figure out an easy way of parsing all the contents between a tag, what is the easiest way? I'm trying to fix a script that doesnt work when the text area contains html and i can't get it to work.
My problem is that i need an algorithm parse parse HTML. For an HTML page, my script has to parse all tags to get all forms values, even if there is frame, iframe, ... How can i do such a script ?
The code works OK in Firefox and Google Chrome, but it fails in Konqueror (khtml) or IE 8.0: the resulting array is empty although the xml read by Ajax call is OK. I tried also with "$("tagname", xml).each()" - same result.
I am trying to split an IP address into it's 4 octets using a RegExp and assigning the result to an array but it is not working. Here is my function so far:
<script type="text/javascript"> function lastoctet(ipaddress){ var ipoctets = new Array();
I have a project coming up this summer that will include having to run a quiz like application from several machines disconnected from the internet.
I was hoping to be able to have all of the quiz data in an XML file and the actual quiz page as html/js. The machines will be using IE5/Mac.
Unfortunately, I won't be able to get a hold of a machine for testing until very close to the deadline, so I need to know what technologies will and wont work for the browser. What kind of compatibility issues (if any) should I be weary of?
Hi, I'm fairly new to AJAX, but I've been able to retrieve HTML and plain-text documents without any trouble. However, I haven't figured out how to retrieve it in XML format. Basically, here's the script that's supposed to retrieve and parse the data when you pass it the url of the page generating the XML data:
i'm having problems with my json scripts. When I retrieve data that contains new lines it causes an error from firebug. I've used a couple of replace like
.replace("", ""), .replace(//g, "") but it still didn't work.
I'm trying to use it to load in an XML file and output some data. I followed a tutorial on it but my XML file isn't loading.[code]Now my thinking is that when the document loads, it alerts me that the jQuery is running, and it does this. I had hoped that after closing that alert, another one would show saying that the XML file has loaded - This would ensure that the function 'parseXML' has been called, but it does not return an alert or populate my#xml_addressbook div.My index page is at the root, and both my XML file and the javascript file are in a folder, as shown below.[code]
I'm building an application with a c#.net server and a good bit of jquery on the front end. I'm having trouble getting/parsing data from c#. In the C#, I am doing a db call to pull the information for all users, and putting it into xml format:
string xml = "<?xml version='1.0' encoding='utf-8' ?>"; xml += "<Users>"; while (res.Read()) {
[Code].....
When I run the application, I'm getting the 'in AjaxSucceeded [object XMLDocument]' alert, but I cannot get inside of the 'each' loop.
The following example works great in Firefox, and Chrome but fails miserably in IE (6,7,8). I'm running JQuery 1.3.2 if it makes a difference: $('resp',"<root><resp>value</resp></root>").text(); That evaluates to "value" in everything except IE.
DOM Parsing XML file (am new to using DOM and parsing files) and I am practicing with example files I found online (W3C). I am trying to use DOM to parse and XML file and then display the info retrieved from the XML file in HTML using Javascript. The files are working well and validate, but nothing is displayed when I open the file up in a browser only the style sheet background color I am using. There are 3 JS functions, one loads the XML, the second gets the info and the third displays it. Here is the code, minus the Style sheet I have been trying to figure this out.
HTML Code Code: <?xml version = "1.0" encoding = "utf-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "[URL]"> <head> <title>Bookstore</title> .....
I am currently working on displaying KML-values of ElementTags within my KML File. I already integrated the KML file as an overlay to my Google Map. But how am I able to parse the GGeoXml-object or how am I able to parse external [URL].. instead of just "polygons.kml") XML-files?
At the moment my code for loading the geoxml file looks like this: