<br><br><div class="gmail_quote">On Wed, May 16, 2012 at 6:15 PM, Marc Delisle <span dir="ltr"><<a href="mailto:marc@infomarc.info" target="_blank">marc@infomarc.info</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

Le 2012-05-16 08:37, Thilina Buddika Abeyrathna a écrit :<br>
<div><div class="h5">> On Mon, May 14, 2012 at 10:23 PM, Thilina Buddika Abeyrathna <<br>
> <a href="mailto:thilinaabeyrathna@gmail.com">thilinaabeyrathna@gmail.com</a>> wrote:<br>
><br>
>><br>
>><br>
>> On Mon, May 14, 2012 at 10:09 PM, Marc Delisle <<a href="mailto:marc@infomarc.info">marc@infomarc.info</a>> wrote:<br>
>><br>
>>> Le 2012-05-14 08:50, Thilina Buddika Abeyrathna a écrit :<br>
>>>> Hi Marc,<br>
>>>> There are HTML code block from line 438 in the tbl_change.php<br>
>>> file(after my<br>
>>>> last commit [0]).  It doesn't mix with much PHP tags. It is somewhat<br>
>>>> readable.<br>
>>>> Do I need to implement several functions to render this HTML block. Can<br>
>>> you<br>
>>>> give me a suggestion..<br>
>>>><br>
>>>> [0] -<br>
>>>><br>
>>> <a href="https://github.com/thilinaa/phpmyadmin/commit/9d6c38daf6a98d915a34391bddb987b116be98c0" target="_blank">https://github.com/thilinaa/phpmyadmin/commit/9d6c38daf6a98d915a34391bddb987b116be98c0</a><br>


>>><br>
>>> Hi Thilina,<br>
>>> The code generating the actions_panel fieldset would benefit from being<br>
>>> refactored into one or more functions. The reason is that it's difficult<br>
>>> to understand quickly such a long code block.<br>
>>><br>
>>> It could become<br>
>>> $html_output = PMA_getActionsPanel(...);<br>
>>><br>
>>> Thank you for your reply Marc. I'll do like this<br>
>><br>
>><br>
>>> -----------<br>
>>><br>
>>> By the way, did you consider using a class? Have a look at<br>
>>> libraries/Partition.class.php. Then, the calling script uses this syntax:<br>
>>><br>
>>> $partition_names = PMA_Partition::getPartitionNames($db, $table);<br>
>>><br>
>>> The benefit is that you don't have to bother about function name clashing.<br>
>>><br>
>>> Thanks Marc. I'll look at that.<br>
>><br>
><br>
> Hi Marc,<br>
> Now tbl_change.php script is somewhat readable and maintainable. Still<br>
> there is a long if condition in this script. but it is not a very complex<br>
> control statement . So do I need to implement a function to separate that<br>
> if condition too.<br>
<br>
</div></div>Ok. Don't forget this bug, when following this scenario:<br>
<br>
1. Browse a table<br>
2. Click the checkbox for two rows<br>
3. At the botton, click the With selected...change link</blockquote><div><br></div><div>Ok Marc. </div></div><br clear="all"><div><br></div>-- <br><font face="georgia, serif">Regards.</font><br><br><font face="'trebuchet ms', sans-serif" size="4">Thilina Buddika Abeyrathna,</font><br>

<font face="georgia, serif">Department of Computer Engineering,</font><br><font face="georgia, serif">Faculty Of Engineering,</font><br><font face="georgia, serif">University of Peradeniya,</font><div><font face="georgia, serif">Sri Lanka.<br>

<br></font></div><br>