PHP script to output MySQL results to sequential html files

Discussion in 'PHP' started by Takshaka, Nov 18, 2005.

  1. #1
    I'm trying to create PHP code to output the results of a MySQL query to several sequential html files.

    For example from a table with fields including "ID" and "Title" I would like to select rows where "ID" =x and output the first 20 results to Title1.html, the next 20 to Title2.html etc for all results. Ideally the script should be able to create a new Titlex.html page as neccessary.

    Can anyone suggest how this should be done or point to any resources which cover this.

    My knowledge of PHP / MySQL is pretty limited.
     
    Takshaka, Nov 18, 2005 IP
  2. HN Will

    HN Will Guest

    Messages:
    111
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #2
    One idea would be to include a counter within your while ($row = mysql_fetch_array($result)) to move through sequential fopened html files in which to dump your content....
     
    HN Will, Nov 19, 2005 IP