PHP 4.3.2 error

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
stonerifik
Forum Newbie
Posts: 23
Joined: Thu May 22, 2003 7:45 pm
Location: united states
Contact:

PHP 4.3.2 error

Post 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 :( ???
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post 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...
stonerifik
Forum Newbie
Posts: 23
Joined: Thu May 22, 2003 7:45 pm
Location: united states
Contact:

Post 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
Post Reply