I use jQuery to make an AJAX POST request to my server, which can return HTTP response with status 302. Then JavaScript just sends GET request to this URL, while I'd like to redirect user to URL in this response. Is this possible?
...
I need to able to pass a reference to a function with a given set of parameters.
Here is an example of passing a reference without parameters:
var f = function () {
//Some logic here...
};
var fr = f; //Here I am passing a reference to function 'f', without parameters
fr(); //the 'f' function is invoked, without parameters
Now w...
Hi, I bet I've got elementary question, but I couldn't solve it for two nights.
I've got 1 "ul" element and I just want it to move any amount of pixels every e.g. 2 sec to the left. I want him to move like this step by step and then come back to the original position and start moving again.
I've been stucked, my script only moves it to ...
I am trying to develop a slideshow with a pause between slides. So I'm trying to use the setTimeout statement as shown below. This is written to swap 2.jpg for 1.jpg with a pause of 10 seconds on clicking the button. But it does now work. Can anyone help me. Thanks.
<html>
<head>
<script type="text/javascript">
var t;
function swap(newI...
I'm trying to follow a simple example of AJAX-enabled WCF Service like:
http://www.pluralsight.com/community/blogs/fritz/archive/2008/01/31/50121.aspx
I'm getting the JavaScript errors Type not defined and Sys not defined.
Does this mean there is an issue with one of these .axd things? or something else?
How do I troubleshoot what is wr...
Beyond offering an API for my website, I'd like to offer users the ability to write simple scripts that would run on my servers . The scripts would have access to objects owned by the user and be able to manipulate, modify, and otherwise process their data.
I'd like to be able to limit resources taken by these scripts at a fine level (e...
I'm using couchdbx v. 0.8.1 and datamapper 0.9.8. I've written a few simple views, copied some from other examples. If I query the views with a browser they return id's. If I query them using datamapper in ruby I get no id's. I've googled for days, been on IRC and looked through the couch and datamapper google groups. I've tried downgrad...
The question, in brief:
In MVC, how do you distinguish between a checkbox click (or a selectbox or listbox change) from a human meaning "Controller, modify the model", and a checkbox click (or a selectbox or listbox change) from the Controller meaning "I'm updating the view because the model has changed"?
The example:
I have a JS ap...
I'm using Apache.
I'm auto gzipping my HTML & CSS files on the fly using the following directive in my .htaccess file.
# Enable ETag
FileETag MTime Size
# Set expiration header
ExpiresActive on
ExpiresDefault "access plus 1 year"
ExpiresByType image/gif A2592000
ExpiresByType image/png A2592000
ExpiresByType image/jpeg A2592000
Expir...
Is it alright to expect that the user using the back end will have Javascript enabled?
I guess the answer I'll get is 'it depends on your target users'. I am developing a system for fun that will hopefully be used by other people. I would like to hear from other people developing back end systems, and what did they decide to do and why?...
I really don't understand what the problem is with those people who ask you not to use JavaScript on your site.
I went through all sorts of trouble trying to remove a couple of JavaScript scripts I used on one of my sites to appease a couple of "complainers". A month later, after a relentless attack by spam bots, I decided I better a...
Possible Duplicate:
Disabling Back button on the browser
Hi Guys,
I need to disable the backbutton of browser window.When I click on backbutton,I need to show one message using alert or other means.Any one can help me
...
I am aware that Javascript WYSIWYG editors use the inbuilt editor mode of the browser to function, but that comes up with various problems and issues.
Can an editor be built from scratch in JS, something like what Buzzword people have done with flash/flex? I came across this blog post recently and I am just wondering if this can be buil...
I am familiar with inserting text nodes after or before a given reference node. But, I would like to know how to insert a tag between text in a given node. For example,
Before insertion: <p>Lorem dolor</p>
After insertion: <p>Lorem <span>ipsum</span> dolor</p>
The span node must be inserted after N characters (I don't need user's cur...
Pls share any known good examples of ExtJS framework with asp.net
...
I am trying to format some bad html to output into a pop window. The html is stored in a field in a mysql database.
I have been performing json_encode and htmlspecialchars on the row in the php like so:
$html = htmlentities(json_encode($row2['ARTICLE_DESC']));
and calling my makewindows function, which simply takes the html as a para...
Hi,
I'm looking for a Web UI toolkit for a Rails-based application. I have an experience with YUI but not in a Rails context. I have many questions I wish you could help me to answer.
Do you use a web UI toolkit like YUI, ExtJS or JxLib within your Rails application ?
Which UI toolkit is the most Rails-friendly ? Since most are not ba...
Hi,
I was wondering if anyone has any preference for referencing images/ css or javascript files in their sites?
The reason I ask is if a client wants to host the site we've writen under a virtual directory, the site usually has to have it's file references changed - even down to url (...image path) in CSS files because we usually deve...
How to make this work in Opera? I found this piece of code for Opera, but it doesn't work for me:
function AddToFavorites(title, url) {
if (window.sidebar) { // Mozilla Firefox Bookmark
window.sidebar.addPanel(title, url,"");
return false;
}
else if( window.external ) { // IE Favorite
window.external.AddFavorite( url, title)...
Hi All,
I have the following code:
<script type="text/javascript">
function SubmitForm()
{
form1.submit();
}
function ShowResponse()
{
}
</script>
.
.
.
<div>
<a href="#" onclick="SubmitForm();">Click</a>
</div>
I want to capture the html response of form1.submit? How...