45 users online (1 members and 44 guests)  


  Results 1 to 7 of 7

Related

  1. Side by side html tables    Forum: HTML Forum
    Replies: 7
  2. Replies: 2
  3. Replies: 3
  4. tables appear side by side?    Forum: HTML Forum
    Replies: 1
  5. Replies: 25
  1. #1
    bufhal's Avatar
    Junior Member

    Status
    Offline
    Join Date
    Apr 2006
    Posts
    32

    PHP / MYSQL Side Menu

    Hello to all -excellent forum!
    Hope to get an answer and/or suggestion or two. I want to give you the whole picture so you know exactly what we are trying to do.
    Our website uses two "MyGosu" menus:
    http://gosu.pl/dhtml/mygosumenu.html
    We are using both DropDownMenuX versions and for our vertical menu:
    http://www.attotech.com/expraid.html
    we are going to change our menu values for each product page. We want to incorporate a MySQL DB so all product information (press releases, tech PDF's, drivers, software updates, certs) can be stored for easy updates for all the perspective pages.
    Can someone please offer a step by step on how to do this and/or point me to a completed system or tutorial?
    Thank you in advance. I appreciate any help and suggestions.

  2. #2
    bufhal's Avatar
    Junior Member

    Status
    Offline
    Join Date
    Apr 2006
    Posts
    32

    Re: PHP/MYSQL Side Menu

    anyone? Or is this question to vague?

  3. #3
    roders's Avatar
    New User

    Status
    Offline
    Join Date
    Mar 2006
    Posts
    3

    Re: PHP?MYSQL Side Menu

    You have to use a mysql query. Which will read from your database for the data that you want ipresent in this Dropdown list.

  4. #4
    DeadMeatGF's Avatar
    Moderator

    Status
    Offline
    Join Date
    Sep 2005
    Posts
    381

    Re: PHP?MYSQL Side Menu

    It's very difficult to reply to this without knowing what data you have, how it's stored, and what criteria you're going to use to build the menu from.

  5. #5
    bufhal's Avatar
    Junior Member

    Status
    Offline
    Join Date
    Apr 2006
    Posts
    32

    Re: PHP?MYSQL Side Menu

    Hi thanks for the replies.
    To show some of the data, I supplied the link above. This information is now stored both as local web files and on a server. We want to keep the menu we have now but if you notice, when you click on any of the menu items, you are taken to a "generic" page with all the information for many products.
    Our goal is to have the menu retrive items from a mysql db that is only for the product and page a user is on. For instance, when visiting the page for the link above, when you click tech sheets, you would go directly to the tech sheet for EXPRESS RAID. etc, etc.
    I assume this can be accomplished with a one table db, the columns would be "tech sheets", drivers, certs, etc.Please let me know if I am on the right tarck or please provide any feedback or ideas...Your time and input is greatly appreciated!

    Thanks all..

  6. #6
    DeadMeatGF's Avatar
    Moderator

    Status
    Offline
    Join Date
    Sep 2005
    Posts
    381

    Re: PHP?MYSQL Side Menu

    You may need to restructure the products section of the site, but the basic plan, off the top of my head, would be to firstly have the links stored in a separate table using the product ID as the key, then pass the product id to the webpage (either with a session variable, eg. $_SESSION['prod_id']) or in the URL (eg. http://www.attotech.com/info.php?pid=123456) then query the database as you build the page, so you'd build the page header/menu bar etc., then query the database for the links: (not real code!)
    Code:
    $result=mysql_query("SELECT * FROM links WHERE pid = $pid");
    $links = mysql_fetch_array($result);
    <a href="$links['techsheet']>Technical Data</a>
    <a href="$links['Drivers']>Drivers</a>
    if ($links['updates'] != "") {
        <a href="$links['updates']>Software Updates</a>
    }
    .... etc.
    The code would need converting to real, workable code and would also need to include your formatting etc.
    It is expandable to include multiple products, if you improve the structure and build the html before outputting it.
    I hope that's about right, I'm sure someone will correct me if not!

  7. #7
    bufhal's Avatar
    Junior Member

    Status
    Offline
    Join Date
    Apr 2006
    Posts
    32

    Re: PHP?MYSQL Side Menu

    Thanks DeadMeat and all.



Tags for this Thread