PHP Classes

AJAX Edit In Place: Edit and save a paragraph of text in an HTML page

Recommend this page to a friend!
     
  Info   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStarStar 66%Total: 15,090 All time: 58 This week: 73Down
Version License Categories
ajaxeditinplace 1.0Free for non-comm...HTML, AJAX
Description 

Author

This class can be used to edit and save a paragraph of text in an HTML page.

It associates the necessary Javascript event handling code to turn a given paragraph in an HTML page into editable text when the user clicks on it.

When the user finishes editing the generated Javascript submit the paragraph text to the Web server using AJAX request so it can be saved.

Innovation Award
PHP Programming Innovation award winner
January 2006
Winner


Prize: One downloadable copy of Roadsend PHP Compiler
The dynamic HTML capabilities that have been added to most browsers made it possible to alter parts of HTML documents without reloading the current page.

The AJAX technology made it possible to make the browser communicate with a server without reloading the current page.

This class combines the dynamic HTML and AJAX capabilities to provide a way to edit and save an area of a page.

Manuel Lemos
Picture of Er. Rochak Chauhan
  Performance   Level  
Name: Er. Rochak Chauhan is available for providing paid consulting. Contact Er. Rochak Chauhan .
Classes: 54 packages by
Country: India India
Age: 45
All time rank: 21 in India India
Week rank: 187 Down15 in India India Down
Innovation award
Innovation award
Nominee: 15x

Winner: 4x

Details

#1)Files to be edited: editplace.js example.php edit.php #2) The variable "url", declared in the top of "editplace.js" file, defines the server side file, which is called after the save button is pressed #3) Make sure you include "prototype.js", "editinplace.js" on the top if the HTML file #4) Add onLoad= "init()" in BODY tag. #5) I have used text file to read and store the text, but you can also use XML or Database to do the same.

  Files folder image Files (9)  
File Role Description
Plain text file AjaxEditInPlace.inc.php Class Main Class file
Accessible without login Plain text file edit.php Aux. Server side file to save changes
Accessible without login Plain text file editinplace.css Data Stylesheet file
Accessible without login Plain text file editinplace.js Data Javascript File
Accessible without login Plain text file example.php Example Example file
Accessible without login Plain text file prototype.js Data Javascript Library for AJAX
Accessible without login Plain text file README.txt Doc. Read me file
Accessible without login Plain text file text.txt Data File to read/store text
Accessible without login Plain text file text2.txt Example Exampel file

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:15,090
This week:0
All time:58
This week:73Down
User Ratings User Comments (3)
 All time
Utility:86%StarStarStarStarStar
Consistency:80%StarStarStarStarStar
Documentation:74%StarStarStarStar
Examples:80%StarStarStarStarStar
Tests:-
Videos:-
Overall:66%StarStarStarStar
Rank:480
 
quite useful.
15 years ago (vadivel)
77%StarStarStarStar
Sir this is excellent class
15 years ago (yahoosir)
40%StarStarStar
Good :)
15 years ago (Farrukh)
77%StarStarStarStar