hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : Hosting Software and Control Panels : Parse error problem
Reply

Hosting Software and Control Panels Software used in the web hosting industry. Topics include control panels, add-on software, setup scripts, etc.
Forum Jump

Parse error problem

Reply Post New Thread In Hosting Software and Control Panels Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 11-08-2000, 02:22 AM
akashik akashik is offline
ex-Aussie
 
Join Date: Aug 2000
Location: Tacoma, Washington
Posts: 9,576
Post


Hi,

I'm getting an error with the following script at line 49. It says I'm having a parsing error. If anyone can check this out a little and see if it's an error in the script it would be greatly appreciated. Failing that any ideas about a script that may be causing the error that's connected to this one (there's quite a few in the whole thing *lol*)

Greg Moore




<?include "connect.php3"; ?>
<?include "authorize-access.php3" ; ?>
<?include "verify-parameters.php3" ; ?>
<?

/* To modifiy the flag of the notebook, you must own it */
if ($visitor_id != $user_id) {

$error_message = "You do not have permission to modify the access flag of the notebook owned by $user_name. <br>If you are $user_name, please go back to <a href=\"$system_url\">the initial page</a> and login again.\n" ;
include "error-page.php3" ;
exit ;
}

$sql = "update notebooks set is_public='$is_public' where notebook_id=$notebook_id" ;
if ( ($result=mysql_db_query($database,$sql)) == 0) {
include "db-error.php3" ;
exit ;
}
echo "
<html>
<head>
<title>Modify flag</title>
</head>
<body bgcolor=#ffffff text=#000000>

<font size=+2>Access Flag Modified</font>" ;

include "show-nav.php3" ;

echo "<HR>" ;

if ($is_public == 't') {
$notebook_URL = $system_url . "entries.php3?notebook_id=$notebook_id" ;
echo "The notebook is now accessible by all users. If you want to point people to this notebook, you can distribute the URL <blockquote><a href=\"$notebook_URL\">$notebook_URL</a></blockquote><p>" ;
} else {
echo "The notebook will not be public." ;
}

echo "

<br>Go to <a href=\"notebooks.php3?user_id=$user_id\">your notebooks page</a> to continue working.

" ;

include "bottom.php3" ;

/* Header("Location: notebooks.php3?user_id=$user_id") ; */
exit ;
}
?>

__________________
Former Webhost... now, just a guy.

Reply With Quote


Sponsored Links
  #2  
Old 11-08-2000, 02:46 AM
Travis Travis is offline
Web Hosting Guru
 
Join Date: Oct 2000
Posts: 337
At first glance, it looks like you need to remove the curly brace (}) right before the final PHP closing tag.

Reply With Quote
  #3  
Old 11-08-2000, 03:23 AM
akashik akashik is offline
ex-Aussie
 
Join Date: Aug 2000
Location: Tacoma, Washington
Posts: 9,576
Thanks,

Umm, do you mean the curly tag pointed out below?


} else {
echo "The notebook will not be public." ;
} <-----THIS ONE? -------

echo "

Greg Moore

__________________
Former Webhost... now, just a guy.

Reply With Quote
Sponsored Links
  #4  
Old 11-08-2000, 03:46 AM
kunal kunal is offline
Web Hosting Master
 
Join Date: Aug 2000
Posts: 2,750
Use this

<?
include ('connect.php3');
include ('authorize-access.php3');
include ('verify-parameters.php3');


/* To modifiy the flag of the notebook, you must own it */
if ($visitor_id != $user_id) {

$error_message = "You do not have permission to modify the access flag of the notebook owned by $user_name. <br>If you are $user_name, please go back to <a href=\"$system_url\">the initial page</a> and login again.\n" ;
include "error-page.php3" ;
exit ;
}

$sql = "update notebooks set is_public='$is_public' where notebook_id=$notebook_id" ;
if ( ($result=mysql_db_query($database,$sql)) == 0) {
include "db-error.php3" ;
exit ;
}
echo "
<html>
<head>
<title>Modify flag</title>
</head>
<body bgcolor=#ffffff text=#000000>

<font size=+2>Access Flag Modified</font>" ;

include "show-nav.php3" ;

echo "<HR>" ;

if ($is_public == 't') {
$notebook_URL = $system_url . "entries.php3?notebook_id=".$notebook_id;
echo "The notebook is now accessible by all users. If you want to point people to this notebook, you can distribute the URL <blockquote><a href=\"$notebook_URL\">$notebook_URL</a></blockquote><p>" ;
} else {
echo "The notebook will not be public." ;
}

echo "

<br>Go to <a href=\"notebooks.php3?user_id=$user_id\">your notebooks page</a> to continue working.

" ;

include "bottom.php3" ;

/* Header("Location: notebooks.php3?user_id=".$user_id) ; */
exit ;
?>

__________________
The Php Support Desk
http://www.phpsupportdesk.com
Custom programming - kunal @ e-phoria.com
http://www.pingzine.com - Ping!Zine. the FREE, FRESH and EXCITING Web Hosting Magazine...

Reply With Quote
  #5  
Old 11-08-2000, 03:49 AM
Travis Travis is offline
Web Hosting Guru
 
Join Date: Oct 2000
Posts: 337
Yep, Kunal's got it.... the very last curly brace after the commented-out "Header" call.


Reply With Quote
  #6  
Old 11-08-2000, 03:55 AM
kunal kunal is offline
Web Hosting Master
 
Join Date: Aug 2000
Posts: 2,750
Yup. Also, he waa using the <? ?> tag too many times. Just made a lil change there to.

__________________
The Php Support Desk
http://www.phpsupportdesk.com
Custom programming - kunal @ e-phoria.com
http://www.pingzine.com - Ping!Zine. the FREE, FRESH and EXCITING Web Hosting Magazine...

Reply With Quote
  #7  
Old 11-08-2000, 03:58 AM
Travis Travis is offline
Web Hosting Guru
 
Join Date: Oct 2000
Posts: 337
Yeah, while that doesn't hurt anything, it makes it a little weird to read.

Reply With Quote
  #8  
Old 11-08-2000, 04:03 AM
kunal kunal is offline
Web Hosting Master
 
Join Date: Aug 2000
Posts: 2,750
It just calls the PHP engine many more times and shuts it down many more times. I dun like tiring the poor guy out

__________________
The Php Support Desk
http://www.phpsupportdesk.com
Custom programming - kunal @ e-phoria.com
http://www.pingzine.com - Ping!Zine. the FREE, FRESH and EXCITING Web Hosting Magazine...

Reply With Quote
  #9  
Old 11-08-2000, 06:20 AM
akashik akashik is offline
ex-Aussie
 
Join Date: Aug 2000
Location: Tacoma, Washington
Posts: 9,576
Kunal,

you're a scholar and a gentleman. I changed that script and it's running fine now.

Thanks.

Greg Moore

__________________
Former Webhost... now, just a guy.

Reply With Quote
  #10  
Old 11-08-2000, 06:30 AM
kunal kunal is offline
Web Hosting Master
 
Join Date: Aug 2000
Posts: 2,750
lol.. thanx

If you need any more help, drop me email or icq message

__________________
The Php Support Desk
http://www.phpsupportdesk.com
Custom programming - kunal @ e-phoria.com
http://www.pingzine.com - Ping!Zine. the FREE, FRESH and EXCITING Web Hosting Magazine...

Reply With Quote
Reply

Related posts from TheWhir.com
Title Type Date Posted
Facebook's Recently Acquired Mobile App Platform Parse Launches Web Hosting for Developers Web Hosting News 2013-05-08 10:49:17
WordPress Host WP Engine Launches Checkpoint Restore Tool Web Hosting News 2012-01-30 12:33:23
Thousands of Sites Mislabeled Phishers After OpenDNS Blocks Google Hosted Scripts Web Hosting News 2012-01-06 15:37:40
Web Host 1&1 Experiences Server Outage Web Hosting News 2011-09-26 17:29:11
Web Hosts Remain Online During San Diego Blackout Web Hosting News 2011-09-12 15:55:50


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?