Jump to content

Search the Community

Showing results for tags 'mysql php group by array'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 1 result

  1. I have some videos I upload to server for online viewing. Sometimes they are too long and I have to cut them into pieces. I am a beginner in this and I'm a little lost. the idea is this: I have these table in MySQL: and this is my php code I have so far: $sql="SELECT * FROM table_name WHERE type = 'tutorials' and type2='word' and video_id='01' ORDER BY server ASC,format ASC,resolution ASC"; $result = mysql_query($sql); <table> while($row = mysql_fetch_array($result)) { echo "<tr>"; switch ($row['server']) { case "youtube": echo '<td><a href="'; echo $row['short_link'].'"><image youtube/></a></td>'; break; case "vimeo": echo '<td><a href="'; echo $row['short_link'].'"><image vimeo/></a></td>'; break; case "dailymotion": echo '<td><a href="'; echo $row['short_link'].'"><image dailymotion/></a></td>'; break; default: echo '<td><a href="'; echo $row['short_link'].'"></a></td>'; } echo "<td>" . $row['server'] . "</td>"; echo "<td>" . $row['format'] . "</td>"; echo "<td>" . $row['resolution'] . "</td>"; echo "<td>" . $row['size'] . "</td>"; echo "<td>" . $row['user'] . "</td>"; echo "</tr>"; } echo "</table>"; but I need that if the server has parts, put all in a div and appears like this: sometimes the video has more parts, I searched for "group by" but I don't know how to integrate it. How I can do that or What do I need search in google to find examples?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.