Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

php configuration problem

Status
Not open for further replies.

dakoz

Programmer
Feb 2, 2002
74
0
0
ok...

i have this script which runs on a server which operates php v4.1.1 at this location is working perfectly:


and the same one running on another server which operates php v4.3.1 doesnt work at.


my hosting provider says that something must be changed in the configuration of the second one but they dont know what it is!!

Any suggestions?


the source code of the script above is :

<!-- STARTGRABBING !-->
<HTML><head></head>
<SCRIPT language=JavaScript src=&quot;../js/rightclick.js&quot;></SCRIPT>
<BODY>

<TABLE><TR><TD align=left><IMG SRC='../images/charts.jpg' width='188' height='55'></TD><TD align=right><IMG SRC='../images/counter.gif'><FONT SIZE='3' face='Arial'><B> ( <FONT SIZE='2' face='Arial'> ( <FONT SIZE='1' face='Arial'> ( Weekly Updated Chart ) <FONT SIZE='2' face='Arial'> ) <FONT SIZE='3' face='Arial'> ) </B></FONT><IMG SRC='../images/counter.gif'></TD></TR></TABLE>

<HR><BR>


<TABLE>
<?php

$GrabURL = &quot; //- Complete URL Of The Page Your Grabbing From!
$GrabStart = &quot; <table border=0 cellpadding=2 cellspacing=0 width=435>&quot;; //- HTML Code To Start Grab. Must Be A Unique Bit Of Code!
$GrabEnd = &quot; <td width=2><img src=\&quot;../images/dot.gif\&quot; width=2 height=1 alt=\&quot;\&quot; border=\&quot;0\&quot;></td>&quot;; //- HTML Code To End Grab. Must Be A Unique Bit Of Code!
#############################
## Do Not Edit Below Here ##
## Do Not Edit Below Here ##
#############################

$OpenFile = fopen(&quot;$GrabURL&quot;, &quot;r&quot;)or die(&quot;Error&quot;); //- DO NOT CHANGE
$RetrieveFile = fread($OpenFile, 200000); //- Reduce This To Save Memory
$GrabData = eregi(&quot;$GrabStart(.*)$GrabEnd&quot;, $RetrieveFile, $DataPrint);
$DataPrint[1] = str_replace(&quot;..&quot;, &quot;.&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!
$DataPrint[1] = str_replace(&quot; Song code: <b>&quot;, &quot;&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!
$DataPrint[1] = str_replace(&quot;<td width=235>&quot;, &quot;<td align=left width=235 bgcolor='#DFDFDF' align=right background='./images/back3.gif'><font face=arial size=2><b>&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!
$DataPrint[1] = str_replace(&quot;#ffffcc&quot;, &quot;#DBE1E9&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!
$DataPrint[1] = str_replace(&quot;#006699&quot;, &quot;#DADADA\&quot; background='./images/back.gif'&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!
$DataPrint[1] = str_replace(&quot;<span class=hypenumber>&quot;, &quot;<span class=hypenumber><font face=arial size=1>&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!
$DataPrint[1] = str_replace(&quot;<td colspan=2>&quot;, &quot;<td bordercolor='#000000' bgcolor='#ECF0FF' colspan=2><i><font face=arial size=3>&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!
$DataPrint[1] = str_replace(&quot; </span>&quot;, &quot;</I></span><font face=arial size=1>&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!
$DataPrint[1] = str_replace(&quot;<td width=150 valign=middle align=right>&quot;, &quot;<td align=center width=150 valign=middle align=right background='./images/back2.gif'><font face=arial size=1><b>&quot;, $DataPrint[1]); //- Un-Comment This Line for &quot;Replace&quot; purposes!


fclose($OpenFile); //- DO NOT CHANGE
?>
<font face=arial size=2><CENTER><TABLE width=90% border=0 cellpadding=0 cellspacing=0><TR>

<?
echo $DataPrint[1]; //- DO NOT CHANGE
?>
</TR>
</TABLE></CENTER>
<!-- ENDSTARTGRABBING !-->
<?
phpinfo();
?>




here is the view
 
I tested it on 4.2.1 and it didn't work until I removed the leading spaces from your unique start and end code

You may also want to change the end code to </body>

 
this didnt work also... :(

any other ideas?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top