php-windows Digest 18 Mar 2005 02:36:39 -0000 Issue 2611

Topics (messages 25765 through 25768):

is it harmful ?
        25765 by: Amir Jebelli
        25767 by: Jason Barnett

Re: Problem with redirect
        25766 by: Jason Barnett
        25768 by: Bunmi AKinmboni

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [email protected]


----------------------------------------------------------------------
--- Begin Message ---
is it harmful if I connect to internet while my apache web server is running ?


--- End Message ---
--- Begin Message ---
Amir Jebelli wrote:
> is it harmful if I connect to internet while my apache web server is running ?
>

*Any* time you connect to the internet you are exposing your computer to
potential viruses, crackers, and the sort.  Having an Apache server
running on a machine offers different ways for an attacker to come after
your system... but IMO it's less dangerous than browsing the internet
with Internet Explorer!

--
Teach a man to fish...

NEW? | http://www.catb.org/~esr/faqs/smart-questions.html
STFA | http://marc.theaimsgroup.com/?l=php-general&w=2
STFM | http://php.net/manual/en/index.php
STFW | http://www.google.com/search?q=php
LAZY |
http://mycroft.mozdev.org/download.html?name=PHP&submitform=Find+search+plugins

Attachment: signature.asc
Description: OpenPGP digital signature


--- End Message ---
--- Begin Message ---
Bunmi Akinmboni wrote:
> I develop under windows. Why will my redirect be giving this error:
>
> Warning: Cannot modify header information - headers already sent by
> (output started at
...

Search the archives for your error message, you will find the answer.

--
Teach a man to fish...

NEW? | http://www.catb.org/~esr/faqs/smart-questions.html
STFA | http://marc.theaimsgroup.com/?l=php-general&w=2
STFM | http://php.net/manual/en/index.php
STFW | http://www.google.com/search?q=php
LAZY |
http://mycroft.mozdev.org/download.html?name=PHP&submitform=Find+search+plugins

Attachment: signature.asc
Description: OpenPGP digital signature


--- End Message ---
--- Begin Message ---
Thanks guys.
As suggested, I had previous sent an echo command.
Regards,
Bunmi

George Pitcher wrote:

Bunmi,

I haven't seen any replies, though you may have had some off-list.

Somehere in your code, you are outputting data. You cannot have any output
before a header(). Even a testing echo would have this effect.

Hope this helps..

George in Oxford


Michael Quinn wrote:

Because you have already sent output to the browser before calling the
header() function.  Maybe you have <head /> tags somewhere before your code
or something.

There is a lazy workaround below for you.

if (isset($HTTP_SERVER_VARS['HTTPS']) && ($HTTP_SERVER_VARS['HTTPS']
== "on")) {
$protocol = "https://";;
}
if (preg_match("#^/#", $url)) {
$url = $protocol.$server_name.$url;
} else if (!preg_match("#^[a-z]+://#", $url)) {
$url = $protocol.$server_name.(preg_replace("#/[^/]*$#", "/",
$HTTP_SERVER_VARS["PHP_SELF"])).$url;
}
echo "<script>location.href='" . $url . "';</script>";
}
exit;
}



Jason Barnett wrote:
Bunmi Akinmboni wrote:

I develop under windows. Why will my redirect be giving this error:

Warning: Cannot modify header information - headers already sent by
(output started at

....

Search the archives for your error message, you will find the answer.

--
Teach a man to fish...

NEW? | http://www.catb.org/~esr/faqs/smart-questions.html
STFA | http://marc.theaimsgroup.com/?l=php-general&w=2
STFM | http://php.net/manual/en/index.php
STFW | http://www.google.com/search?q=php
LAZY |
http://mycroft.mozdev.org/download.html?name=PHP&submitform=Find+search+plugins




--- End Message ---

Reply via email to