[Phpmyadmin-devel] Naming convention standard for methods

Chanaka Dharmarathna pe.chanaka.ck at gmail.com
Sat May 12 14:28:13 CEST 2012

On Sat, May 12, 2012 at 4:58 PM, Marc Delisle <marc at infomarc.info> wrote:

> Le 2012-05-12 00:51, Chanaka Dharmarathna a écrit :
> > Hi All,
> >
> > While I'm refactoring some files relating to display query results
> > (currently display_tbl.lib.php, common.lib.php), I can method names are
> > used regardless of the inside functionality.
> >
> > Ex :- "PMA_displayHtmlRadio" in common.lib.php method return a string of
> > HTML content.
> It does not return anything.
> > But the name tells the function displays HTML itself.
> This is exactly what this function is doing.
> --
> Marc Delisle
> http://infomarc.info
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Phpmyadmin-devel mailing list
> Phpmyadmin-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/phpmyadmin-devel

Hi Marc,

It was a mistake by me. Due to I have push some of modifications to my
repository, I thought they were returning string.
However still there are some functions need to modify. ( PMA_buttonOrImage
should be PMA_displayButtonOrImage as you pointed)

But what I actually need to suggest is, instead of render them inside
functions, render them in files like sql.php
Above function can be PMA_getButtonOrImage and if it need to render
somewhere we can just do "echo PMA_getButtonOrImage"
So that function only contains some logics (manipulations, calculations
etc) and it gives a separate layer for PMA.

I did some modifications in my repository [0].
I'm stuck with these things, because when I merge PMA to my repository,
there were lots of conflicts in files.
Please guide me to do the right thing.

[0] :

Regards !

Chanaka Indrajith
Bsc.Computer Engineering Undergraduate
Faculty of Engineering
University of Peradeniya
Sri Lanka
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.phpmyadmin.net/pipermail/developers/attachments/20120512/b7966613/attachment.html>

More information about the Developers mailing list