I am using local storage to store user entries and am displaying the entries on another page. I need a way to sort them based on the most recent date and time of edit. Is there a way to do this with HTML5. If not, what's the easiest/most effective way to do so?
Thanks for the inputs.
...
I have a chunk of data coming from an ajax call. I need to split this chunk up into smaller chunks of a predefined amount, not by a delimiter character, but by an amount. 2k is what I would like. I am trying to come up with a snippet that would bit shift divide the data, and place each chunk including the remaining data into arrays. So i...
I need to implement on my php page map. I have container <div id="map"></div> which is inside other div, and I put this code inside <head> tag but it doesn't show at all. Can anybody help me?
<script type="text/javascript" src="javascript/jquery-1.4.3.js"></script>
<script type="text/javascript" src="http://maps.google.com/maps/api/js?s...
Can anyone tell me why, even when my alert shows that my regular expression strings match, the if statement is not triggered? I have sample code below. Thanks in advance.
$(document).ready(function () {
$('div#primaryNavigation').find('a').each(function () {
var pattern = /my-link1|my-link2|my-link3|my-link4/;
var my...
My company uses IE8 as the default browser and by default compatibility mode is set for all intranet sites. I'm building an intranet site that works when compatibility mode is turned off. I'm using reset.css and several opensource javascript programs, e.g. datatables.
What I'd like to do is force compatibility mode off for my site. ...
I need to remove everything after the last '/'.
Source: /uploads/images/image1.jpg
Result: /uploads/images/
How do I do this with regular expression?
I've tried different solutions, but it's not working. I get NULL as a result.
...
Hi, I was wondering what is the best way to detect when a page has finished loading where the page in question is in a different tab or window. And where page to be loaded could be any page on the web and is not under my control.
I am using Firefox only and I dont mind if the solution requires a firefox extension or greasemonkey script...
I'm trying to passing an arguments (array) for update, but seems CouchDB unable to parse them correctly.
curl -X PUT http://localhost:5984/mydb/_design/timeline/_update/hello/container-1?tags\\[\\]=1\&tags\\[\\]=2
in CouchDB:
"updates": {
"hello": "function(doc,request){if(!doc){doc={_id:request.id};}for(i in request.que...
Is there some offset I should be accounting for when I upload an image in this manner? If i simple send the file, I can write it back out as a valid JPG but if I write the data submitted via readAsBinaryString, the file is approximately 50% larger and corrupt.
Any thoughts?
here's the javascript:
var file = e.dataTransfer.files[0];
...
Hi,
I have a question that is somewhat similar to this one (which was never answered):
http://stackoverflow.com/questions/989328/gwt-mark-of-the-web-motw
I have an Online Help package built using javascript/HTML. Other teams in my company make use of this package in their apps, swapping in the content they need. One team in particular...
Hi there,
Im facing a problem with jquery in the Internet Explorer 7 and 8:
Im Trying to add a option tag to a existing select:
var s = document.getElementById("category");
s.options.add(select_option);
But IE just says: “Object doesn't support this property or method” and points to the s.options.add(select_option); line...
Anybody...
(HTML) Let's say I have within fixed-width containers. Some of these headings will be longer than one line. I would like isolate these lines and do separate things to each line. Is there a way, with JavaScript, to calculate where the heading has broken to the next line and to for example put a span around each line?
...
How to get the id of the div on which the mouse is currently pointing?
...
Is there a way to passing one to many parameters from html to jQuery?
The requirement is when a link on the page is clicked, toggle some text for this link, and hide text for other link(s), so I have the following jQuery:
$(link1).click(function(){
$(hide1).hide(300, function(){
$(hide2.hide(300, function(){
$(t...
Possible Duplicate:
why results varies upon placement of curly braces in javascript code
We have company policies that dictate that in PHP opening curly braces should be on their own lines for readability and so that they can line-up with the closing brace; thus:
if (true)
{
...
}
but in JS they should be kept on the s...
our middle tier needs to do something to prevent </script> from appearing verbatim in javascript string. for example, in all browsers, the HTML parser in its first pass will ignore the javascript context, see the first close-script, then see garbage then see a second close-script. See: using-script-in-a-javascript-literal
<HTML>
<BODY>
...
I often want to have a ModalPopupExtender , but I want to control it from the code behind. In this particular case, I want to make my ModalPopupExtender come up when I click an "edit" button on a GridView row or when I click a "New Item" button on my page. For this reason it makes more sense to control the ModalPopupExtender from the cod...
I'm trying to figure out how to make use of the "pinch" touch effect with Sencha Touch. Do you know of any examples that help with the first steps?
The documentation seems to be rather silent about it.
Specifically I'm looking for a common task as a starter:
I want to zoom it - and - zoom out of an image in JPEG format. Do you know if...
Hi,
I've searched around for this a lot and can't find a specific example of what I'm trying to do. Basically I want to get the value of a textbox, by the name of the text box (not id). Then I want to remove ALL spaces, not just leading or trailing, but spaces in the text too. For example for this html code:
<INPUT style="TEXT-ALIGN: r...
Hypothetical: I find a page with a button ('#bigButton'), that when clicked causes a llama ('img#theLlama') to show() using jQuery.
So, somewhere (say, Line 76) in buttons.js:
$('#bigButton').click(function(){
$('img#theLlama').show();
})
Now, let's say I have a big HTML page with a whole bunch of .js files included. I can click on...