Jump to content

Parse error: syntax error, unexpected T_OBJECT_OPERATOR


andy6867

Recommended Posts

<style type="text/css">
<!--
body {
   background-color: #EAEFF4;
}
-->
</style><?php

include("config.php");
include("header.php");

echo "<table border='0' style='border:2px solid #AFB1B1' cellspacing='0' cellpadding='2'>";
echo "  <tr bgcolor='#747272'>";
echo "    <td colspan='2' background='images/dbluecell.gif'>";
echo "      <p align='center'>";
echo "      <font face='Verdana, Arial, Helvetica' size='2' color='#FFFFFF'>";
echo "        <b>Recently Added Albums</b>";
echo "      </font>";
echo "    </td>";
echo "  </tr>";

$select = $db->select()
   ->distinct(true);
   ->from('songlist', array('album', 'artist', 'date_added', 'picture', 'albumyear', 'cnt' => 'Count(*)'))
   ->where('songtype = ?', 'S')
   ->group(array('picture', 'album'))
   ->having('cnt > 1')
   ->order('date_added DESC')
   ->limit(20,0);

$count = 1;

$rows = $db->fetchAll($select);

foreach($rows as $row)
{
   $count++;

   if(($count % 2)== 0)
   {
      echo "<tr align='center'>";
      echo "    <td>";
      echo "        <img align=left src='../pictures/" . rawurlencode($row["picture"]) ."', width='200' height='200'>";
      echo "        <p align='left'>";
      echo "        <font face=Verdana color=#FFFFFF size=1><b>ALBUM: </b><a href='./playlist.php?name=Playlist&?letter=". $letter . "&artist=" . rawurlencode($row["artist"]) . "&album=" . rawurlencode($row["album"]) . "'>" . $row["album"] . "</a><font><br>";
      echo "        <font face=Verdana color=#FFFFFF size=1><b>ARTIST: <i><a href='./playlist.php?name=Playlist&?letter=". $letter . "&artist=" . rawurlencode($row["artist"]) . "'>" . $row["artist"] . "</a></i></font><br>";
      echo "        <font face=Verdana color=#FFFFFF size=1><b>RELEASED: </b></font><font face=Verdana color=red size=1><b>".$row["albumyear"]."</b></font><font face=Verdana color=#FFFFFF size=1><b>   ADDED: </b></font><font face=Verdana color=red size=1><b>".substr($row["date_added"],5,2)."/".substr($row["date_added"],8,2)." </b></font>";
      echo "        </p>";
      echo "    </td>";
   }
   else       
   {
      echo "    <td>";
      echo "        <img align=left src='../pictures/" . rawurlencode($row["picture"]) ."', width='200' height='200'>";
      echo "        <p align='left'>";
      echo "        <font face=Verdana color=#FFFFFF size=1><b>ALBUM: </b><a href='./playlist.php?name=Playlist&?letter=". $letter . "&artist=" . rawurlencode($row["artist"]) . "&album=" . rawurlencode($row["album"]) . "'>" . $row["album"] . "</a><font><br>";
      echo "        <font face=Verdana color=#FFFFFF size=1><b>ARTIST: <i><a href='./playlist.php?name=Playlist&?letter=". $letter . "&artist=" . rawurlencode($row["artist"]) . "'>" . $row["artist"] . "</a></i></font><br>";
      echo "        <font face=Verdana color=#FFFFFF size=1><b>RELEASED: </b></font><font face=Verdana color=red size=1><b>".$row["albumyear"]."</b></font><font face=Verdana color=#FFFFFF size=1><b>   ADDED: </b></font><font face=Verdana color=red size=1><b>".substr($row["date_added"],5,2)."/".substr($row["date_added"],8,2)." </b></font>";
      echo "        </p>";
      echo "    </td>";
      echo "</tr>";
   }
}
echo "</table>";
?>

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.