#334 (in 2.5.3) Multiple column display

Next_minor_version
fixed
1
2013-06-11
2003-06-10
No

The ability to specify the number of columns in the table
display.

Since I run my monitor at 1600 x 1200 and have 160+
tables, it is much more efficient for me to have multiple
columns in the table display, see attachment. I currently
have 5 table row columns. The other request I put in
requesting short labels for the actions is also helpful
since the page is wide.

Sample code is below.

---------------------------
db_details_structure.php
---------------------------
if (!$cfg['num_table_columns'])
$cfg['num_table_columns'] = 1;
$num = ceil($num_tables / $cfg['num_table_columns'])
+1;
if($num_tables > $num)
if(($row_count % ($num)) == 0) {
$bgcolor = $cfg['BgcolorTwo'];
$row_count = 1;
print "</tr></table></td><td
valign=top>";
print_header_rows();
}

---------------------------
config.inc.php
---------------------------
$cfg['num_table_columns'] = 5;
// number of table columns to display

Discussion

  • Source Omnimedia

    Multiple table columns

     
  • Source Omnimedia

    Logged In: YES
    user_id=446485

    If this is adopted, would be helpful to also re-initialize the row
    colors to $cfg[['BgcolorOne'] at the top of each column so
    the colors to randomly match or mis-match.

    One way to do this is set the color before the while loop and
    don't use the $i variable to alternate colors. Example below.

    --------------------------
    db_details_structure.php
    --------------------------

    $bgcolor = $cfg['BgcolorOne'];
    while (list($keyname, $sts_data) = each($tables)) {
    ...
    // $bgcolor = ($i++ % 2) ? $cfg['BgcolorOne'] : $cfg
    ['BgcolorTwo'];
    if ($bgcolor == $cfg['BgcolorOne'])
    $bgcolor = $cfg['BgcolorTwo'];
    else
    $bgcolor = $cfg['BgcolorOne'];
    ...
    }

     
  • Garvin Hicking

    Garvin Hicking - 2003-07-23

    Logged In: YES
    user_id=473563

    You already seem to have some good PHP understanding.

    How about you taking the latest CVS snapshot and try to
    integrate your change and post it here as a patch for us to
    implement?

    I'd love to see that!

    Regards,
    Garvin.

     
  • Source Omnimedia

    Logged In: YES
    user_id=446485

    Will do.

     
  • Source Omnimedia

    Logged In: YES
    user_id=446485

    Here's the modified config.inc.php3 file. I couldn't test it with
    a pre.3.23.03 db. Let me know any problems you have.

    config.inc.php3:
    -- Added $cfg['num_table_columns'] variable.

     
  • Source Omnimedia

    Logged In: YES
    user_id=446485

    Here's the modified db_details_structure.php3 file. I couldn't
    test it with a pre.3.23.03 db. Let me know any problems you
    have.

    -- Added new top-level table/tr/td around current table tag.
    -- Added new column code which duplicates the column
    headers. I recommend the column headers display become a
    function to prevent having two copies of the header code.
    -- New variable $num_columns.
    -- Added end table tag.

     
  • Garvin Hicking

    Garvin Hicking - 2003-07-24
    • assigned_to: nobody --> garvinhicking
     
  • Garvin Hicking

    Garvin Hicking - 2003-07-24

    Logged In: YES
    user_id=473563

    Kawika,

    thanks for doing the work. I will check the code as soon as
    possible and try to implement it into CVS -- if there are no
    other objections, I would like to see the screen-optimized
    workin in PMA. :-)

    Regards,
    Garvin.

     
  • Garvin Hicking

    Garvin Hicking - 2003-07-24

    Logged In: YES
    user_id=473563

    I just put the stuff, in a modified form into CVS. I also
    plugged in some images for RFE #752065.

    I pretty much like it, I'll wait what the others say about
    the buttons. We could use them for the table properties page
    too. At first the buttons are taken from Typo3
    (opensource...) but we should look into doing them on our
    own. *g*

     
  • Garvin Hicking

    Garvin Hicking - 2003-07-28
    • priority: 5 --> 1
    • summary: Multiple column display --> (in 2.5.3) Multiple column display
    • status: open --> open-fixed
     
  • Michal Čihař

    Michal Čihař - 2003-09-09
    • status: open-fixed --> closed-fixed
     
  • Michal Čihař

    Michal Čihař - 2013-06-11
    • Status: closed-fixed --> fixed