What is the best way to include data in an HTML page? The data is not human-readable and will be processed by a script once the page has loaded. The options I can think of are:
Using class and title attributes on hidden/empty <div> or <span> elements within the page
JSON in a <script> element at the bottom of the page
Load the data via...
Is there a way to use XMLHttpRequest in combination with other domains?
I would like to parse some xml from Google without having to use a server so it is minimalistically complex to run.
var req = getXmlHttpRequestObject();
...
req.open('GET', 'http://www.google.de/ig/api?weather=Braunschweig', true);
req.setRequestHeader("Con...
From what I understand, due to the "same origin policy" enforcement in current browsers, it's impossible to obtain data from an XmlHttpRequest sent to a different domain than the Javascript's original domain.
I have close to zero experience regarding this matter, so I'm confused about web services being unusable from Javascript.
Does it...
Hi
I have a status message box (div box) positioned at the bottom of a web page using position: fixed; and bottom: 0;. Its height is initially 11px.
I want to allow users to double click it when there are more status messages than what can fit within the default hight, make it grow. If they double click it again or move the mouse away ...
How do you manipulate text inside of a textarea as the user types in it?
...
I have an onclick handler for an <a> element (actually, it's a jQuery-created handler, but that's not important). It looks like this:
function handleOnClick() {
if(confirm("Are you sure?")) {
return handleOnClickConfirmed();
}
return false;
}
From this function, the this object is accessable as the <a> element cli...
My requirement is just to display a set of values retrieved from database on a spread. I am using jquery.
...
How to load javascript files using google.load instead of directly using tag in freemarker template language?
...
Hello,
I have a php page that displays rows from a mysql db as a table. One of the fields contains HTML markup, and I would like to amke this row clickable and the html would open in a new popup window. What is the best way to do it, and is there a way to do it without writing the html to a file?
edit: this php page is actually part o...
Is it possible to stop visual studio from debugging external javascript? We have a window which displays external webpage. If the page contains bad javascript then my entire session comes to a halt and breaks. Hitting continue won't move past the problem.
It's really irritating and tedious, is there an equivalent setting to "just debug ...
I'm having trouble with the Dojo documentation (as usual).
On their TabContainer API, they list the second argument as an object called "params", but they never say what you can actually put in this params object. Can I specify the width? The height? Do I specify the id's of the divs I want to be the tabs inside the container?
There's ...
I really don't know how to describe it, but if you understood it and you have an experiend on that field, may be you can help me with something 'Open Source' and 'Ready-made'.
I want to create something like a box 'or widget', where you can change it content by hitting some buttons on the upper of the box. (Hey the box is on a web page ...
I am writing an iframe based facebook app. Now I want to use the same html page to render the normal website as well as the canvas page within facebook. I want to know if I can determine whether the page has been loaded inside the iframe or directly in the browser?
...
Hi All,
I am looking to make a web control where I can register client startup scripts inline with my aspx because I hate registering in the codebehind!
An example of what I have so far:
<Ben:StartupScript runat="server">
var form = document.getElementById("<% =form1.ClientID %>");
</Ben:StartupScript>
Currently, I am overriding th...
A remote site is supplying a data structure in a js file.
I can include this file in my page to access the data and display it in my page.
<head>
<script type="text/javascript" src="http://www.example.co.uk/includes/js/data.js"></script>
</head>
Does anyone know how I use PHP to take this data and store in it a database?...
I was looking into GWT. It seems nice, but our software have the must work without JS requirement. Is it possible?
...
I'm writing a global error handling "module" for one of my applications.
One of the features I want to have is to be able to easily wrap a function with a Try{} Catch{} block, so that all calls to that function will automatically have the error handling code that'll call my global logging method. (To avoid polluting the code everywhere ...
Right now I'm trying to add a button to a webpage that when pressed will start playing a .wav file by dynamically adding an embed tag to the DOM. The text switches to "Stop" while the sound plays, and I'd like to be able to switch it back automatically to "Play" once the file has finished playing.
How would I be able to execute some Jav...
OK,
Here is my problem, I have a master page with a HEAD section that contains my JS includes. I have one JS include
<script src="Includes/js/browser.js" language="javascript" type="text/javascript"></script>
In my page i consume it like this:
<body>
<form id="form1" runat="server">
<div>
....
<script type="text/javascript">regist...
I have a row of buttons, which all create a pdf file which I want to open in a new tab.
This way the button page stays on top, and the pdf's open to get printed. To prevent clicking a button twice I disable the button, like this (I use python):
<input type='submit' value='Factureren' name='submitbutton' id='%s'
onclick="javascript:docum...