Alert icon
We're changing our privacy policy. This stuff matters.  Learn more  Dismiss

Dynamic Grid Output Programming Tutorial Using PHP + MySQL Array Data

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
9,325
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Dec 13, 2010

When accessing database or any dynamic array of information you can apply this method to produce a grid layout instead of a traditional linear layout. You can use tables, divs, or simple line breaks as a stagger mechanism.

Script Source: http://www.developphp.com/view_lesson.php?v=396

  • likes, 0 dislikes

Link to this comment:

Share to:

Video Responses

see all

All Comments (20)

Sign In or Sign Up now to post a comment!
  • @TheJustinmkeith seems like you would have to use pagination

  • So I'm newb at all this but I was wondering how I can make a dynamic grid that is limited on how many rows that are created but will auto generate selectable pages that the end user can click to see more content for my online store.

    example:

    page 1

    a b c

    d e f

    g h i

    page 2

    j k l

    m n o

    p q r and so on.

  • Where do you close the table rows?

  • Thnx Adam. Its been so useful. How can we make it with the images from our database and how to display them randomly everytime we refresh the page. If u can make another tutorial it will be awesome. 

  • wat about if we wanted it this way:

    a d g

    b e h

    c f i

    please help.

  • How bout some pagination for this? Will it work with your previous pagination tut?

  • Cool tut.

    Nice vid Adam, keep up the good work :D

  • @lucas199400 if you have it in a specific format (eg, always comma or semi-colon separated (;) then you can use explode() function in the form: explode(";",$string);

    where ; is our separator (can be any character, try to make it obscure so that you don't get unexpected results (can be a string)) and $string is the haystack which we are looking in.

    Practical use:

    $name = "AlexSPLITBowers";

    $split = explode("SPLIT",$name);

    echo $split[0] . " " . $split[1];

  • I would of never though of this, thnx adam

Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more