I need to serialize all inputs from a form into a JSON string.
With the help of this post, I can successfully create a valid string as below:
{"input01":"value01","input02":"value02","input03":"value03"}
However, when I try to use the string to POST data using jQuery's Ajax function, it seems to add backslashes to the string, resultin...
Hello,
I created a html/javascript website running on an Apache Webserver on Mac OS X. This website consumes a .NET Webservice with JSON via XmlHttpRequest. This Webservice is running on a Windows Vista machine.
The website is accessible with this url: http://macintosh.companyname.local/~username/Sitename/index.html.
When I open the we...
I'm developing a grid with excel-like functionality using the telerik controls. For example users can click on a cell and the cell turns into an input control for editing. Users can tab to move onto the next cell or use arrow keys for up/down to get the cell above or below. I've found the standard telerik grid is good but I've had to ext...
It is the demo application web site:
http://www.freerichtexteditor.com/index.php?inc=demo/index
The rich text editor can insert image on it, just like a word document,
but the traditional web html form can't add an image on the html form.
How this rich text editor work? why it can insert an actually image on the
html form instead of p...
Hi,
i load an external page with
$('#myContainer').load('myfile.html');
in myfile.html theres an
<script type="text/javascript" src="otherscript.js"></script>
Some users report that the otherscript.js is not loaded... i've tested a all common browsers (firefox, ie 6/7, safari, opera etc.) - i cant figure out why this wont work.....
Hello,
I have a text box function as below
<input type="text" onkeypress="return onEnter(event,this);"
onBlur="return chkForDBCS(this);"/>
function chkForDBCS() check if a DBCS(mainly for japanese char) is entered in the text and throws an alert message and clears the text box.
function onEnter() submits the form.
When i have t...
Hi, i'm trying to find a clicked word in an onclick event handler.
somediv.onclick = function(event) {
var w = getClickedWord(event);
alert(w)
}
getClickedWord() uses range.moveToPoint for msie and event.rangeParent/offset for gecko, but Webkit seems to support neither. Any pointers?
...
Hello,
I'm working on a web application that needs to frequently poll the server database and check for any available data to the client.
Ideally, I would need to be able get a javascript function callback in the server, in order to be able to call the javascript function back whenever any new data is available on the database, instead...
This is the regular expression I use to match phone numbers like:
00 00 00 00 00
00 00 0 00 00 00 00
+00 0 00 00 00 00
(\d{2}\s+\d{2}\s+\d{2}\s+\d{2}\s+\d{2})\s+(\d{2}\s+\d{2}\s+\d\s+\d{2}\s+\d{2}\s+\d{2}\s+\d{2})\s+(+\d{2}\s+\d\s+\d{2}\s+\d{2}\s+\d{2}\s+\d{2})
I have tried to include it into my javascript but It's not really working...
A project I'm working on requires the use of jQuery on customers' Web pages. Customers will insert a chunk of code that we'll supply which includes a few <script> elements that build a widget in a <script>-created <iframe>. If they aren't already using the latest version of jQuery, this will also include (most likely) a <script> for Goog...
(i posted this on the extjs forum too but recon SO is probably busier)
HI
I'm passing down the following json to a direct store:
{
"type": "rpc",
"tid": 2,
"action": "DirectReportDesigner",
"method": "GetReports",
"result": {
"total": 1,
"data": [{
"id": 1,
"FullTypeName": null,
"title": "test",
...
How do I count the number of rows in a jqGrid?
To clarify, there is not much data involved so the grid is pulling all of its data back from the server in a single query, instead of using pagination.
...
Hi,
I'm disabling groups of radio buttons when a user clicks a checkbox, just using raw javascript and the disabled property.
My function is trivial:
function toggleEnabled(elementId) {
e = document.getElementById(elementId)
e.disabled = !e.disabled;
}
and it is called with the onClick event like onClick="toggleEnabled('radio_di...
hi i have a page having text box. in that i should not allow user to go to next page unless he enters some NUMBER. it should number but not text and should not be empty , any help pls?
...
I want to persist some data between web requests using JavaScript. I would use Google Gears but I can't install Gears on each client machine or expect it to be installed. I found this SO Question but I don't like the idea of storing data in that method. Any suggestions will be welcomed. Thanks!
Edit:
Ideally I want to store "as muc...
On Chris Coyer's site he uses a nice little search box. I am curious to know how you get the text in the search box to disappear and reappear when you click out of the box.
Thanks to a helpful person on this forum I use the following to have the text disappear when I click in the box:
<input type="text" value="Search" onfocus="if (this...
I am trying to find a nice way to implement a text slider (examples: News feed or testimonials) with the AJAX control toolkit and/or JQuery that does the following:
"Slide" (or fade) every few seconds to the next block of text
The text blocks cannot be static, as there can be hundreds/thousands of them. Most likely will need to call a...
I have selected a control using the following variable
var txt = $("#text1");
Now when I have to handle events on the textbox, do I have to reference it as $(txt) or txt will do
$(txt).keydown(function() {})
or
txt.keydown(function(){})
What is the advantage. Please explain it taking the variable txt as the context.
...
I want to create a simple graph as this screeshot :
:
the nodes must be clickablea nd they must have various forms. the arcs must have various colours and arrows!
I found this javascript library :Raphael
but I can't write into the nodes.
Can anybody help me to find a library, javascript or flash, that create a sample graph as the scr...
Hi,
I try to redirect my page for a logged in user with a certain amount of inactivity to a different page without killing the session.
I would like to substract the time I spent on the first page from the session, put the user on the new page, and then log the user out after his session (rest of the session time) times out and redirect...