I've created a pagination script that takes a long block of text and breaks it into pages. First the text is loaded into a div with the id #page. Then the script measures the height of #page and calculates how many pages it should be broken into to fit into the div with class .detailsholder.
The div .detailsholder is cleared out, and th...
How can i assign the below code to a number?
Integer.toHexString( myHexValue );
...
I'd like to show some visual progress to a user during an ajax request. E.g when he clicks a 'process' button which makes an AJAX request to a server-side script, he will see a 'loading...' message and a graphic, but I also want to show him some progress of how much processing is done. E.g 5/10 processed, 6/10 processed... and so on.
Is...
Hi anyone see why my alert won't work?
<script type="text/javascript">
function SubmitForm(method)
{
var login = document.form.login.value;
var password = document.form.password.value;
$.post("backend.php", {
login: login,
password: password,
method: method},
function(data){
...
I have built Web sites with Python/Django and desktop applications with Objective-C/Cocoa so programming is not something that I need to learn. For someone in my situation, what is the best way (specific books or Web sites) to learn PHP and Javascript?
...
I'm working in DotNetNuke but this doesn't really seem to be strictly a DNN problem.
I am using a DNN provided method in my module called FormatEmail which uses document.write to write out an email like like so:
<script language="text/javascript">
<!--
document.write(String.fromCharCode(60,97,32,104,114,101,102,61,34,109,97,105,108...
Imagine you have a bunch of components and subcomponents in your web application. You want to keep track of how all the custom events you added behave. Are there established ways to diagram or document these behaviors?
Here are some things the documentation should show:
The actual nesting of relevant DOM elements of the various compon...
What is the best cross-browser way to detect the scrollTop of the browser window? I prefer not to use any pre-built code libraries because this is a very simple script, and I don't need all of that deadweight.
...
Imagine I have a web application with nice components coded up with your favorite Javascript library. I make heavy use of custom events to reduce the dependencies between these components so you can easily place them in multiple contexts, repeat them on the page, and/or nest them as I see fit.
This is a lovely picture, but debugging can...
For Gecko there's Mozilla Developer Center
For IE there's MSDN.
For webkit there's...Apple Developer Connection?
There are a couple of JavaScript related documents on ADC, but nothing as comprehensive as MDC or MSDN. There's no reference. There's no way to look up methods of arrays or strings for webkit, or anything is there? So what...
I'm playing firebug with Google Calendar. I happens to find that some XHR request has response like below:
while(1);[['us','bW9yZ2FuLmNoZW5nbW9AZ21haWwuY29t 20090320/20090904 63378122163']]
It looks like a JSON with prefix dead-loop javascript statements.
I'm not sure why Google Calendar has such kind of XHR response. Is there any kn...
Not sure if this belongs in community wiki...
Can somebody give some general guidelines on how to successfully build an ASP.NET site that isn't dependent on JavaScript? My understanding is that I should build a functional site initially without JavaScript, and use it to enhance the user experience. That is easier said than done... how...
Here's the situation: I would like to iterate through a table with input controls, collect up the values and then submit them to an ASP.Net PageMethod to save the data to the database. I have the collection all figured out, but am getting an error that the string can't be converted to a Dictionary.
So I end up with something like this b...
I'm building an application using ASP.Net MVC, and I want/need it to work with and without javascript enabled. The first stumbling point for me is this: When the user clicks on the register link, if they don't have javascript enabled they should be sent to a registration page that has master page stuff around it... but if they do have ja...
I am completely new to javascript and jquery. My programing knowledge is... nonexistent, I just started some days ago with some simple tasks like replacing a css class or toggling a div. So I want to apologize if I'm treading on someones toes by asking newbie-questions in here. But I hope that someone can help my and solve my problem.
I...
HI,
I need to write multiple statements inside a conditional operator.
What will be the equivalent of this if condition with conditional operator
var name;
var age;
var passed;
if ( arg == "first" )
{
name = "John";
age = "25";
passed = false;
}
else
{
name = "Peter";
age = "29";
passed = true;
}
...
I started to test my web site on google chrome and 'cannot call method 'join' of null' appears when doing this:
var sChoices = oQuestion.aChoiceRand.join("");
In IE and FF works well. What I'm trying to do with this code is to join all the 'aChoiceRand' array elements in a string without any separators. How can I solve this?
...
I tried out the online JS Minifier but it cuts out conditional comments like:
var u = navigator.userAgent;var e=/*@cc_on!@*/false;
BECOMES
var u=navigator.userAgent;var e=false;
This would affect the operation of the code, so instead of manually adding the stripped out comments manually, I'm looking for ...
I can't understand this code. If this is a RegExp, can it be done in a simpler way? Or is this already widely compatible? (with IE6 and newer browsers)
var u = navigator.userAgent;
// Webkit - Safari
if(/webkit/i.test(u)){
// Gecko - Firefox, Opera
}else if((/mozilla/i.test(u)&&!/(compati)/.test(u)) || (/opera/i.test(u))){
}
...
I have a web document that contains a div element.
That div element contains an svg child element (which itself contains SVG primitives: text, path, etc.).
Ultimately, I would like to export that svg element into a proper, self-contained SVG document. (I can then run that SVG document through imagemagick and make publication-quality fi...