Results 1 to 6 of 6
  1. #1
    Join Date
    Apr 2006
    Posts
    157

    Unanswered: How Can I Generate Multi-Column Lists... properly

    hey guys, I just can't seem to find a fix for this anywhere

    so I cooked up my own:

    what I have is a 2D array with multiple columns that i have to display in the list
    eg 3 columns

    I was able to extract the strlen() of the longest field for each column
    and basically what I did was add spaces to the shorter fields so that all would have equal no. of characters
    and then developed new array with second column =
    concatenated column 2 and 3 of original array...

    anyway, the real problem is that &nbsp just doesn't graphically align the characters as well as I anticipated.
    I tried to use ( & # 0 9 ; ) for tab, but it didn't work...

    it's almost a dead-end... trying to align these concatenated columns.

    is there a code block for this anywhere?
    any clues, anyone?
    Only quitters quit!

  2. #2
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    consider using a fixed pitch / monospaced font like courier/leter gothic etc.
    consider using a table
    consider creating an image using the graphics interface library or possibly write to a PDF
    you may be able to get a CSS style that works OK.. but from my experience unless you started off with CSS it could be a pig to apply
    I'd rather be riding on the Tiger 800 or the Norton

  3. #3
    Join Date
    Mar 2007
    Location
    636f6d7075746572
    Posts
    770
    As healdem suggested, just use an html table... it is after all, a visual representation of a 2D matrix isn't it

  4. #4
    Join Date
    Apr 2006
    Posts
    157
    this almost amounts to suggesting a different approach... but the ms access listbox format is, as i see it the best interface for this...

    i did find a site : EasyListBox.com that demonstrated it, however I can't figure it out completely, looks like they're using javascript/something that they're selling to facilitate the multicolumn list...

    it does suggest that it is possible though...

    i will try the monospaced approach anyway... but i'm not giving up on this


    thanks guys,

    it means a lot that I can get other people's input on the things I'm doing
    Only quitters quit!

  5. #5
    Join Date
    Apr 2006
    Posts
    157
    yup, monospace works like a charm... in fact i'm using courier... works like a charm


    thanks a bunch, this will have to do for now...
    Only quitters quit!

  6. #6
    Join Date
    Mar 2007
    Location
    636f6d7075746572
    Posts
    770
    Heh, nice one. If you take a quick sqwizz at this forum you may note that you can use the [ CODE ] tags to put code, which retains the spaces you were trying to use. Might be worth a little dig around vbulletin source code to find the relevant parts.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •