RE: [PHP] Site Moved From PHP4 to PHP5 Server - header, location no longer working

2010-01-07 Thread Vernon Webb
That's the odd thing, there is nothing being indicated in the error logs the 
server just hangs and I have to restart apache in order to get the site back 
up. First I thought it might be the server so I move over to a different 
server, but I still have the same issue. What I feel is really odd is the fact 
that it worked in a previous version of php, so waht's changed?
 
~V



From: Ashley Sheridan [mailto:a...@ashleysheridan.co.uk]
Sent: Thu 1/7/2010 7:52 AM
To: James McLean
Cc: Vernon Webb; php-general@lists.php.net
Subject: Re: [PHP] Site Moved From PHP4 to PHP5 Server - header, location no 
longer working


On Thu, 2010-01-07 at 16:50 +1030, James McLean wrote: 

On Thu, Jan 7, 2010 at 1:35 PM, Vernon Webb ver...@comp-wiz.com wrote:
 I move a number of sites from one server to another and one the one 
server we had php4 and now we have php5 and since then my server seems to hang 
every time there is a header, location redirect. Anyone have any ideas on how 
to resolve this? Is there something I can easily change in the php.ini file 
that will resolve this issue?

Off the top of my head it sounds like something is being output before
the header, which causes an error. If you also have error display
turned off, you will likely just see a white screen with no useful
information.

Make sure none of your includes have trailing whitespace or are trying
to print out information before the header itself.

Best bet is to turn on errors and log them, then you will see where
the output started if infact that is your issue.

Cheers



Don't turn on errors if this machine is public, as it could potentially give 
out more information to people than you want. First, look at the error logs for 
PHP, which record all the errors you've had with the site, whether you have 
them displayed or not.


Thanks,
Ash
http://www.ashleysheridan.co.uk http://www.ashleysheridan.co.uk/ 




-- 
This message has been scanned for viruses and 
dangerous content by comp-wiz.com http://comp-wiz.com/ , and is 
believed to be clean. 


RE: [PHP] Site Moved From PHP4 to PHP5 Server - header, location no longer working

2010-01-07 Thread Vernon Webb
Didn't know there were php logs, I thought they would be included in the Apache 
logs, where do I find the php logs?
 
~V



From: Ashley Sheridan [mailto:a...@ashleysheridan.co.uk]
Sent: Thu 1/7/2010 8:42 AM
To: Vernon Webb
Cc: php-general@lists.php.net
Subject: RE: [PHP] Site Moved From PHP4 to PHP5 Server - header, location no 
longer working


On Thu, 2010-01-07 at 08:40 -0500, Vernon Webb wrote: 

That's the odd thing, there is nothing being indicated in the error 
logs the server just hangs and I have to restart apache in order to get the 
site back up. First I thought it might be the server so I move over to a 
different server, but I still have the same issue. What I feel is really odd is 
the fact that it worked in a previous version of php, so waht's changed?
 
~V



From: Ashley Sheridan [mailto:a...@ashleysheridan.co.uk]
Sent: Thu 1/7/2010 7:52 AM
To: James McLean
Cc: Vernon Webb; php-general@lists.php.net
Subject: Re: [PHP] Site Moved From PHP4 to PHP5 Server - header, 
location no longer working


On Thu, 2010-01-07 at 16:50 +1030, James McLean wrote: 

On Thu, Jan 7, 2010 at 1:35 PM, Vernon Webb 
ver...@comp-wiz.com wrote:
 I move a number of sites from one server to another and one 
the one server we had php4 and now we have php5 and since then my server seems 
to hang every time there is a header, location redirect. Anyone have any ideas 
on how to resolve this? Is there something I can easily change in the php.ini 
file that will resolve this issue?

Off the top of my head it sounds like something is being output 
before
the header, which causes an error. If you also have error 
display
turned off, you will likely just see a white screen with no 
useful
information.

Make sure none of your includes have trailing whitespace or are 
trying
to print out information before the header itself.

Best bet is to turn on errors and log them, then you will see 
where
the output started if infact that is your issue.

Cheers



Don't turn on errors if this machine is public, as it could potentially 
give out more information to people than you want. First, look at the error 
logs for PHP, which record all the errors you've had with the site, whether you 
have them displayed or not.


Thanks,
Ash
http://www.ashleysheridan.co.uk http://www.ashleysheridan.co.uk/  
http://www.ashleysheridan.co.uk/ 






Have you checked both the PHP and Apache error logs? Things like invalid 
commands in an .htaccess file can cause server crashes.


Thanks,
Ash
http://www.ashleysheridan.co.uk http://www.ashleysheridan.co.uk/ 




-- 
This message has been scanned for viruses and 
dangerous content by comp-wiz.com http://comp-wiz.com/ , and is 
believed to be clean. 


RE: [PHP] Site Moved From PHP4 to PHP5 Server - header, location no longer working

2010-01-07 Thread Vernon Webb
It's the oddest thing. I've found the logs but there is no error at all, the 
server just hangs and the only way to get it back is to restart Apache.
 



From: Ashley Sheridan [mailto:a...@ashleysheridan.co.uk]
Sent: Thu 1/7/2010 9:04 AM
To: Vernon Webb
Cc: php-general@lists.php.net
Subject: RE: [PHP] Site Moved From PHP4 to PHP5 Server - header, location no 
longer working


On Thu, 2010-01-07 at 08:57 -0500, Vernon Webb wrote: 

Didn't know there were php logs, I thought they would be included in 
the Apache logs, where do I find the php logs?
 
~V



From: Ashley Sheridan [mailto:a...@ashleysheridan.co.uk]
Sent: Thu 1/7/2010 8:42 AM
To: Vernon Webb
Cc: php-general@lists.php.net
Subject: RE: [PHP] Site Moved From PHP4 to PHP5 Server - header, 
location no longer working


On Thu, 2010-01-07 at 08:40 -0500, Vernon Webb wrote: 

That's the odd thing, there is nothing being indicated in the 
error logs the server just hangs and I have to restart apache in order to get 
the site back up. First I thought it might be the server so I move over to a 
different server, but I still have the same issue. What I feel is really odd is 
the fact that it worked in a previous version of php, so waht's changed?
 
~V



From: Ashley Sheridan [mailto:a...@ashleysheridan.co.uk]
Sent: Thu 1/7/2010 7:52 AM
To: James McLean
Cc: Vernon Webb; php-general@lists.php.net
Subject: Re: [PHP] Site Moved From PHP4 to PHP5 Server - 
header, location no longer working


On Thu, 2010-01-07 at 16:50 +1030, James McLean wrote: 

On Thu, Jan 7, 2010 at 1:35 PM, Vernon Webb 
ver...@comp-wiz.com wrote:
 I move a number of sites from one server to another 
and one the one server we had php4 and now we have php5 and since then my 
server seems to hang every time there is a header, location redirect. Anyone 
have any ideas on how to resolve this? Is there something I can easily change 
in the php.ini file that will resolve this issue?

Off the top of my head it sounds like something is 
being output before
the header, which causes an error. If you also have 
error display
turned off, you will likely just see a white screen 
with no useful
information.

Make sure none of your includes have trailing 
whitespace or are trying
to print out information before the header itself.

Best bet is to turn on errors and log them, then you 
will see where
the output started if infact that is your issue.

Cheers



Don't turn on errors if this machine is public, as it could 
potentially give out more information to people than you want. First, look at 
the error logs for PHP, which record all the errors you've had with the site, 
whether you have them displayed or not.


Thanks,
Ash
http://www.ashleysheridan.co.uk 
http://www.ashleysheridan.co.uk/  http://www.ashleysheridan.co.uk/  
http://www.ashleysheridan.co.uk/ 






Have you checked both the PHP and Apache error logs? Things like 
invalid commands in an .htaccess file can cause server crashes.


Thanks,
Ash
http://www.ashleysheridan.co.uk http://www.ashleysheridan.co.uk/  
http://www.ashleysheridan.co.uk/ 






They could be in a variety of places depending on how your system is set up. It 
should show you if you do a phpinfo(); in a page on its own.


Thanks,
Ash
http://www.ashleysheridan.co.uk http://www.ashleysheridan.co.uk/ 




-- 
This message has been scanned for viruses and 
dangerous content by comp-wiz.com http://comp-wiz.com/ , and is 
believed to be clean. 


[PHP] Site Moved From PHP4 to PHP5 Server - header, location no longer working

2010-01-06 Thread Vernon Webb
I move a number of sites from one server to another and one the one server we 
had php4 and now we have php5 and since then my server seems to hang every time 
there is a header, location redirect. Anyone have any ideas on how to resolve 
this? Is there something I can easily change in the php.ini file that will 
resolve this issue?

Thanks
~V



[PHP] After Upgrade to php 5 unlink fails

2006-11-14 Thread Vernon Webb
I've just upgraded to php 5 and am now getting the following error:

Warning: 
unlink(/home/mywebsite/public_html/resumes/travelport_holiday_rev1.html) 
[function.unlink]: No such file or directory 

This worked fine prior to the upgrade and obviously the file does exist. 

What has changed and how can I correct this?

Thanks

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



[PHP] php 3 to 5 upgrade: foreach loop no longer working

2006-04-18 Thread Vernon Webb
I've recently upgraded a server from Fedora Core 3 to Core 5 in the process php 
had 
been upgraded from either 3 or 4 to php 5. In doing so I had to do a major 
overhaul of 
a web site as many things stopped working (.i.e $HTTP_POST_VAR, etc). Haven't 
gotten 
through most of that I know have a problem with a page that is being submitted 
to 
another page which contains different values for checkboxes. I would pull the 
values 
from each checkbox using a foreach loop as such: 

foreach ($checkbox as $value) {
echo Value: $valuebr /\n;
}

however the value is no longer being echoed to the page. 

What am I missing here?

This is the code that is being submitted, $num being an incremented value:

input name=checkbox[?php echo $num; ?] type=checkbox id=checkbox[?php 
echo 
$num; ?] value=?php echo $row_rsADS['customers_id']; ? /

Thanks in advance

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



Re: [PHP] php 3 to 5 upgrade: foreach loop no longer working

2006-04-18 Thread Vernon Webb
 Register Globals?

You got it. Is there any advantage to having this turned off?

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



[PHP] Search File

2003-11-21 Thread Vernon Webb
I'm trying to find a way to search text files in a directory using php. I've
done some researching under the filesystem section on php.net but seem to
have come up empty handed. Is there a way to do keyword searches on a txt
file in a directory hopefully with some type of relevance ranking?

Thanks

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



Re: [PHP] UPDATE MySQL

2002-11-13 Thread Vernon Webb
Here's the thing. I'm trying to update a record when a user logs in. I have 
a login script that I am trying to have automatically update a record upon 
login. I figure the easiest way to do it is have the page submitted to 
another page which updated the record's last access date and then redircts 
to the actual page they are going to.

This however does not work I am getting a Parse error.



-- Original Message ---
From: Marco Tabini [EMAIL PROTECTED]
To: vernon [EMAIL PROTECTED]
Sent: 13 Nov 2002 17:18:18 -0500
Subject: Re: [PHP] UPDATE MySQL

 I can see two things that are not correct in the statement:
 
 First, the date you're setting is in UNIX format--but MySQL wont' 
 like that. You need to use FROM_UNIXTIME.
 
 Second, the username is a string (I guess), but it's not within
 quotation marks.
 
 $myquery = UPDATE penpals SET 
 lastaccess=FROM_UNIXTIME($lastaccessdate) WHERE ID='$myuserid';
 
 Two notes:
 
 The MySQL extension does not normally print out errors. You need to
 explicity call mysql_error() to do that. In this case, you can add it
 after the call to mysql_query(), e.g.:
 
 die (mysql_error());
 
 Also, you are passing HTTP data directly to MySQL. This can allow a
 malicious user to insert potentially evil code in your call and cause
 all sorts of damage. I suggest you consider filtering that 
 information using one of the many methods available.
 
 Marco
 
 -- 
 
 php|architect - The magazine for PHP Professionals
 The first monthly worldwide magazine dedicated to PHP programmers
 
 Come visit us at http://www.phparch.com!
--- End of Original Message ---


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




Re: [PHP] UPDATE MySQL

2002-11-13 Thread Vernon Webb
I made some modifications to the code and I do not get ant error messages, 
but the database is still not updated. Here's the code:

?php
  $hostname_connPENPALS = localhost;
  $database_connPENPALS = phpenpals;
  $username_connPENPALS = username;
  $password_connPENPALS = password;

// SET DATE and SET USER ID SESSION VARAIBLE
  $lastaccessdate = gmdate(M d, Y);
  $myuserid = $HTTP_SESSION_VARS['svUserID'];

  mysql_select_db($database_connPENPALS, $connPENPALS);
$myquery = UPDATE penpals SET lastaccess='$lastaccessdate' WHERE 
ID='$myuserid';
  $result = mysql_query($myquery, $connPENPALS);

  echo mysql_error();

//  header(Location: successfullogin.php);
?


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