Results 1 to 7 of 7

  1. Post
    #1

    CSS Grid Woes

    Any Grid experts out there?

    Click image for larger version. 

Name:	row1.png 
Views:	42 
Size:	249.5 KB 
ID:	226645

    That piece of white space up the top is driving me mad and I can't get rid of it. For some reason Grid is adding an extra row at the top with the fixed row height (and grid gap) attached.

    Happens across multiple pages, but not all of them (so it's not something inherent within innerContainer). You can see in the image it goes straight from innerContainer to listAnItemZeroHeader but there's just this empty row with nothing in it.

    Here's the weird thing, if I delete all function calls, it goes away. None of them echo.

    And the weirder thing, if I leave the functions but delete absolutely everything in dev tools except for innerContainer and the first header div (depending on what page it is), it's bloody well still there.

    The pages where it doesn't show don't seem to differ in any way (plenty of function calls).

    Googling doesn't return anything helpful (at least with my search terms).

    Anyone seen anything like this? Or have any sort of an explanation what could be causing it?

    Another page utilising the same layout but no issue:
    Click image for larger version. 

Name:	rowgone.png 
Views:	17 
Size:	83.0 KB 
ID:	226646

  2. Post
    #2
    Double checked, the pages that work fine don't call PHP functions at the beginning of the content include.

    So it's purely "if I call a PHP function, it adds space" albeit the functions don't echo anything.

  3. Post
    #3
    Ugh, it's now fixed but I don't know why.

    I had my PDO connection in an include rather than as a function. Which was then required within a function to build queries. Moved it to a function and that somehow fixed it.

    I theorise there was a hidden error being dumped on the page but error reporting wouldn't display it.

  4. Post
    #4
    If it helps I use bulma.io for all my grid needs and it's never let me down.

  5. Post
    #5
    Privoxy wrote:
    If it helps I use bulma.io for all my grid needs and it's never let me down.
    Sweet, I'll check it out. I've been pretty anti-plugin for this dealio until this point. A lot of it is I'm relearning everything but also an attempt to keep it fast and secure. And it really is both of those.

    Pretty much everything is scratch written except for a couple exceptions (functions and classes I can put in where I can read through them all) and TCPDF which I haven't really touched yet.

    Also it turned out not to be a Grid/CSS error and was a PHP error, but I still don't know why.

    It's for the best, though, I was including the PDO so I could be lazy and write SQL straight on the page. Bringing it into its own function and passing everything through my query function secures the SQL connection as there's now only one path to it.

  6. Post
    #6
    Privoxy wrote:
    If it helps I use bulma.io for all my grid needs and it's never let me down.
    TIL. This looks awesome, wonder if it'd be good to use instead of angular material in an angular web app

  7. Post
    #7
    Stasis wrote:
    TIL. This looks awesome, wonder if it'd be good to use instead of angular material in an angular web app
    I actually use both. Bulma for the general layout and angular material for all the components etc. Is a nice workflow.