Page 1 of 1

PHP 4.3.2 error

Posted: Wed Jul 09, 2003 10:57 am
by stonerifik
before my computer crashed i was running PHP 4.3.1 on my Apache Server... but now im using a diffrent computer same OS 98 and only diffrence is PHP 4.3.2

usually when im linking to something on the main directory from a subdirectory such as
127.0.0.1/downloads/index.php
would have a link to
127.0.0.1/index.php

i did this with $_SERVER['DOCUMENT_ROOT']./index.php
and this method worked wonderfuly on 4.3.1... but now that im using
4.3.2.. it seems to be not working and i get this error

Parse error: parse error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in c:\apache group\apache\htdocs\everything.php on line 14

and this is my source for line 14

Code: Select all

<a href=$_SERVER&#1111;'DOCUMENT_ROOT']./devious.php?id=main>News & Updates</a>
can any one offer me an explaination :( ???

Posted: Wed Jul 09, 2003 11:49 am
by m3rajk
is hat in an html block? a php block? and echo statement? what?
that line is too little to help.but it could be the news[SPACE]&[SPACE]updates

like i said, it's obscure to help you.

i know you want it printed but now how you're trying to print it.


ofcourse it could be that you're using microsoft for an os....

i like LAMP myself...

Posted: Thu Jul 10, 2003 1:44 pm
by stonerifik
im using Windows98
and uh sorry... that line is in my $left_menu variable
and anyways i got it working, i set the $_SERVER[DOCUMENT_ROOT] as its on variable and just added the new variable in place of the $_Server command and it works fine now