Re: parse error, unexpected T_CLASS
| From: | Dasmeet Singh | Date: | Tue, 19 Apr 2005 20:05:27 +0000 |
| Subject: | Re: parse error, unexpected T_CLASS | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-213413@lists.php.net to get a copy of this message | ||
Marek Kilimajer wrote:
Dasmeet Singh wrote:BTW.. pls suggest some good editor.. I use notepad currently.. - Free Website Promotion - A Complete Guide http://hostwindow.info/web-hosting/9/free-website-promotion/1/Jay Blanchard wrote:[snip] echo ("<div class=pmini> <h1> $row[1] </h1> <p> Location- $row[4] <br> Property Type- $ptype<br>Min Price- $row[9] </div>"); it gives an error.. Parse error: parse error, unexpected T_CLASS in /home/real/public_html/functions.php on line 162 Any idea..why? Probably any stupid mistake .. :( [/snip] Takes the parentheses out. echo "<div class=pmini> <h1> $row[1] </h1> <p> Location- $row[4] <br> Property Type- $ptype<br>Min Price- $row[9] </div>"; From http://www.php.net/echo "echo() is not actually a function (itis alanguage construct) so you are not required to use parentheses withit.In fact, if you want to pass more than one parameter to echo, you must not enclose the parameters within parentheses."Removed the ()..still the same error :(.. am copying complete function..if its because of something else... function showProperty($filter, $by, $value) { if($filter==true) {----------------------------------------------------------------^ missing double quote. Get some decent editor with syntax highlighting Thanks.. That was really silly..$query="SELECT * FROM} else {PropertyWHERE ".$by." = '".$value."' ORDER BY DateAdded DESC";$query="SELECT * FROMPropertyORDER BY DateAdded DESC;