Ajax - move boxes plus snap to grid

Posted on 2007-11-18
Last Modified: 2013-12-13
I want to create a page that i can create a grid system to divide the page into seprate areas.

I dont mind which ajax framework is used but i will be using PHP and MYSQL to save the poistion into a DB.

Is there any examples of this using ajax that anyone can point me at.
Question by:willa666
  • 2
LVL 34

Accepted Solution

Beverley Portlock earned 250 total points
ID: 20307658
SAJAX is quite simple and has examples

All you have to is define the initial javascript function and a callback function to process the result.
	function multiply($x, $y) {
		return $x * $y;
	// $sajax_debug_mode = 1;
	function do_multiply_cb(z) {
		document.getElementById("z").value = z;
	function do_multiply() {
		// get the folder name
		var x, y;
		x = document.getElementById("x").value;
		y = document.getElementById("y").value;
		x_multiply(x, y, do_multiply_cb);
	<input type="text" name="x" id="x" value="2" size="3">
	<input type="text" name="y" id="y" value="3" size="3">
	<input type="text" name="z" id="z" value="" size="3">
	<input type="button" name="check" value="Calculate"
		onclick="do_multiply(); return false;">

Open in new window

LVL 36

Assisted Solution

by:Loganathan Natarajan
Loganathan Natarajan earned 250 total points
ID: 20310152
LVL 36

Expert Comment

by:Loganathan Natarajan
ID: 20349800
did you try anything further?

Expert Comment

ID: 20943726
Forced accept.

Community Support Moderator

Featured Post

Active Directory Webinar

We all know we need to protect and secure our privileges, but where to start? Join Experts Exchange and ManageEngine on Tuesday, April 11, 2017 10:00 AM PDT to learn how to track and secure privileged users in Active Directory.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Ahax pagination 9 33
Html Newline 7 21
on window close, not beforeunload 6 20
Visual Studio npm 1 12
Things That Drive Us Nuts Have you noticed the use of the reCaptcha feature at EE and other web sites?  It wants you to read and retype something that looks like this.Insanity!  It's not EE's fault - that's just the way reCaptcha works.  But it is …
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question