[Phpmyadmin-devel] GSoC - AJAXify the Interface for phpMyAdmin

Michal Čihař michal at cihar.com
Thu Mar 25 23:52:27 CET 2010


Hi

Dne Sun, 21 Mar 2010 02:31:03 +0530
Ninad Pundalik <ninadsp16289 at gmail.com> napsal(a):

> After reading through the GSoC Ideas wiki page[0] and the discussion
> on the feature request[1] of adding AJAX functionality to phpMyAdmin,
> I could think up of a possible implementation as follows, other than
> the one already outlined very briefly on the discussion page (of
> starting out with the Query page, implementing the common jQuery and
> PHP functions and then replicating the process for the other action
> pages) :
> 
> 1. Implement this as an add-on in the initial phase.  Replicate all
> the PHP files which operate on the database in a folder, '/ajax/'
> making them AJAX endpoints.

No duplication please. Reuse code as much as possible and if not
possible factor out functionality you need to separate module.

> 2. Modify the PHP code in each of the endpoints, so that we can output
> the content in XML, JSON or plain HTML (whichever is decided to be
> used).

Most likely HTML because of theming which should be done in PHP and not
in JavaScript.

> 3. On each action page, add some PHP code, which checks for a
> cookie/database setting and confirms that the client supports
> JavaScript.  In the if block, add jQuery/MooTools code which will
> manipulate the necessary links and forms on the page, carry out the
> actual AJAX calls, and also implement callback functions, which will
> handle the responses from the AJAX endpoints.

There is no need for extra detection - JS enabled => jQuery works => it
can hook onto links.

-- 
	Michal Čihař | http://cihar.com | http://blog.cihar.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.phpmyadmin.net/pipermail/developers/attachments/20100325/dd2bdf61/attachment.sig>


More information about the Developers mailing list