Re: [PHP] adding code and beginning and end without includes

2006-03-16 Thread Claudio Corlatti

search in google
php +prepend +htaccess

http://www.codingforums.com/showthread.php?t=78287

bye bye

Claudio

blackwater dev wrote:

Is there a way to intercept and add code at the beginning and end of every
http request - WITHOUT having to put an include at the top and bottom of
every page?

This is something we need to be app specific so don't really want to do it
globally like chanse the php.ini or something.

Thanks!

  


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Parse Error

2006-02-21 Thread Claudio Corlatti

Hi,
you need to finish every line with ;
$host=localhost ;
$user=ray ;
$password=* ;

Bye


Ray Cantwell wrote:

Hi all,
I am a noob and super confused right now. I have some really simple 
code and i am getting an error that reads:
*Parse error*: syntax error, unexpected T_VARIABLE in 
*/var/www/mysql_up.php* on line


here is the code:

html
headtitleTest MySQL/title/head
body
!-- mysql_up.php --
?php
$host=localhost ;
$user=ray ;
$password=* ;

mysql_connect($host,$user,$password) ;
$sql=show status;
$result = mysql_query($sql);
if ($result == 0)
  echo bError  . mysql_errno() . : 
. mysql_error() . /b;
else
{
?
!-- Table That Displays the results --
table border=1
 trtdbVariable_name/b/tdtdbValue/b
 /td/tr
 ?php
   for ($i = 0; $i  mysql_num_rows($result); $i++) {
 echo TR;
 $row_array = mysql_fetch_row($result);
 for ($j = 0; $j  mysql_num_fields(result); $j++)
 {/
   echo TD . $row_array[$j] . /td;
 }
 echo /tr;
  }
?
/table
?php } ?
/body/html

I am really confused because i cannot see any obvious errors.
any help would be appreciated.

Ray.