Not understanding this problem that should be easy!

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
kevlarcat
Forum Newbie
Posts: 2
Joined: Tue Feb 23, 2010 4:39 am

Not understanding this problem that should be easy!

Post by kevlarcat »

Hey all, so I have been handed a problem from a website that is not mine but they are on vacation and asked me to try to fix it for them. I have gone through it and I can't figure out what is wrong. I am getting the error "Parse error: syntax error, unexpected '{'". I deleted the "{" and got a different error. So now I know that the problem as suspected is that I am missing the closing "{". Problem is I cant seem to figure out where it should go. Can somebody help me out?

This is the line that has the error:
<?phpif(isset($_GET['done'])) { echo '<div align="center" style="color:red;font-weight:bold">
pbs
Forum Contributor
Posts: 230
Joined: Fri Nov 07, 2008 5:31 am
Location: Nashik, India
Contact:

Re: Not understanding this problem that should be easy!

Post by pbs »

Try this

Code: Select all

 
<?php 
    if (isset($_GET['done'])) { echo '<div align="center" style="color:red;font-weight:bold">'; } 
?>
 
kevlarcat
Forum Newbie
Posts: 2
Joined: Tue Feb 23, 2010 4:39 am

Re: Not understanding this problem that should be easy!

Post by kevlarcat »

That fixed it! Thanks so much I realize now I was missing more than just the "}", and that's why I couldn't get it fixed! Thanks this makes me very happy, I can go to sleep now. (3 AM here...)
Post Reply