[PHP] problem forcing download

2001-05-11 Thread Bert

Hi,

I'm having some problems with forcing a file download.
I want to use the script to force the download of .doc,.pdf and .txt files
so they don't get opened in the current browser window.
I already have a script that works on most browsers (ie5.01, netsc4.07,
netsc6.01, opera4.01 all on PC) except for IE 5.5 and Opera 5 on PC.
Macintosh browsers (both IE and Netscape) don't like my script either...
IE 5.5 just opens the file in the browserwindow, Opera 5 just opens raw code
in the browserwindow (as if they were textfiles). I already had to use a
little hack to please IE 5.5, otherwise download.php got downloaded instead
of the actual file...
Please have a look at the code below.
I know I could use a javascript popup window, but I realy would like to get
this script going...

All tips are greatly appreciated!
Thanx alot!

Bert

This is what I've got for now:

**

**




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Header Location problem with PHP as CGI

2001-05-19 Thread Bert

Hello,

I'm desperate here...
I hope this question hasn't been asked a million times before (I sure
did not find an answer in the archives)

I'm developing a site that runs perfectly on a surver with the PHP
module in apache.
The problem is that the site will be hosted on a server with PHP as
CGI (from PHPinfo: Configure Command './configure'
'--prefix=/usr/local/php' '--enable-static' '--enable-safe-mode=yes'
'--enable-track-vars=yes' '--enable-memory-limit=yes'
'--enable-short-tags=no' '--with-gd=/usr/local'
'--with-mysql=/usr/local/mysql' '--enable-force-cgi-redirect' )

I have a couple of "Header: Location"s in the site that are not
working properly.
The redirect actualy happens BUT the address in the addressbar of the
browser doesn't change.
A little example: the first time someone visits he has to choose his
language. At that moment a cookie is set.
The next time he reaches the www.site.com/index.html some code checks
for the cookie and he should get redirected to the first page in his
language that is www.site.com/language/home/index.html
What actualy happens is that he gets to see the page but in the
addressbar it still shows www.site.com/index.html This gives a couple
of ptoblems:
when the user clicks refresh on his browser, the address in the
addressbar gets refreshed.
on that first page there is a java applet that doesn't get found (it
looks for it in the root instead of in the home-directory.

I hope this all is a littlebit understandable ...

I don't know if this is important but I added a .htaccess in the root
that forces .html to get parsed as php:
***
Action application/x-httpd-php /cgi/php.cgi
AddHandler application/x-httpd-php .html
***
I don't think this has something to do with it but I add it just in
case.

Thanks to anyone who can shed some light on my problem!

Bert
please check my email address if you would like to mail me

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] getimagesize (Bug? or error in PhP?)

2001-05-23 Thread Bert

On 23 May 2001 04:15:09 -0700, [EMAIL PROTECTED] ("bram") wrote:

>I' have version Version 4.0.4pl1


URL support was added in PHP 4.0.5 !
So it won't work with 4.04...

Bert

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] httpS connection with FILE

2002-05-10 Thread Bert Buckley


I would like very much to retrieve data from an 
https server using the file function, but it only
supports an http call.

1. Can someone suggest a good alternative

2. I understand this will be in PHP 4.3.  Does
anyone know a possible release date.

Thanks

Bert


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




[PHP] handle E_STRICT with own error handler

2004-05-27 Thread Bert Slagter
Hi,
I tried to use my own error handler to handle all non-fatal errors. But 
to my surprise it seems to be impossible to handle E_STRICT level 
notices. I don't know whether this is by design, not yet implemented or 
a know bug that I overlooked - but it seems rather strange :).

To reproduce:
- create your own error handler
- set error_reporting to 0
- generate a E_STRICT notice, for example by using var $x as a class member.
Your error handler won't give a sound!
Anyone an idea?
Bert
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: handle E_STRICT with own error handler

2004-05-27 Thread Bert Slagter
Jason,
Please read my question a bit better :).
PHP indeed does report the E_STRICT notices fine, that's not my problem. 
I know how error handling in PHP works :).

But I have my own error handler (see: set_error_handler()) and handle 
all notices and warnings myself (and all other E_USER_* of course). And 
I was wondering why errors of the level E_STRICT don't make it to my 
custom error handler function, in contrast to for example E_NOTICE.

Didn't expect to have to explain this here :(.
Bert
Jason Barnett wrote:
Bert Slagter wrote:
Hi,
I tried to use my own error handler to handle all non-fatal errors. 
But to my surprise it seems to be impossible to handle E_STRICT level 
notices. I don't know whether this is by design, not yet implemented 
or a know bug that I overlooked - but it seems rather strange :).

To reproduce:
- create your own error handler
- set error_reporting to 0

If you set error_reporting to 0, then why should you expect to have any 
errors reported?  You'd need error_reporting(2048) to just see those 
errors (assuming you're using PHP5).

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


[PHP] Re: Aspect Oriented Programming & PHP

2004-05-27 Thread Bert Slagter
Michael Lauzon wrote:
Since PHP5 is going to feature OOP (Object Oriented Programming), will that mean PHP6 
will feature AOP (Aspect Oriented Programming)...so far it seems AOP is only being 
used for Java at the moment; but hopefully general programming and scripting languages 
will start using them as well?!

Michael Lauzon, Founder
The Quill Society
http://www.quillsociety.org/
[EMAIL PROTECTED]
The __get, __set and __call functions are distand cousins of AOP: they 
offer the possibility to react on the fact that some method is called, 
regardless which one. It models the aspect 'any method called, what to do?'.

But note that there are no 'native AOP' languages right now, Java only 
has some obscure extensions/mutations that partly implement the AOP 
paradigm (like AspectJ, JBoss and Hyper/J).

But it would be nice though if optional AOP support would find its way 
into PHP one day :).

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


[PHP] Recent numbers on PHP Market Penetration?

2004-07-06 Thread Bert Slagter
Good afternoon,
I'm looking for recent numbers of the PHP Market Penetration - if 
possible compared to ASP/JSP. The netcraft survey only shows apache vs. 
IIS, can't find anything about PHP there.

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


Re: [PHP] Recent numbers on PHP Market Penetration?

2004-07-06 Thread Bert Slagter
Christophe Chisogne wrote:
It seems you didnt search Google very long.
I did, actually :).
Simple google searches like
"number of sites running php site:netcraft.com"
lead to results on netcraft.com, by example
a "php vs coldfusion vs jsp" page [1] found via link
on the 2003/08 netcraft survey [2]
Yeah, I've seen that one, but I'm pretty sure that in the last 11 months 
 a lot has changed. So a 2003/08 survey isn't what I mean with 'recent'.

Google leads me to Zend.com, who thinks (February 18, 2002)
"the number of web sites running PHP now exceeding 7 million" [4]
Hm, 2002/02 is ages ago on the scale of internet :).
But other sources provide more recent figures [5,6]
I found that ones too - of course. But this doesn't say anything about 
the market penetration, only about the apache-module-penetration. This 
is not the same: not every apache that has php as a module actually uses 
php and some websites use php without having it as a apache module.

Finding more information is left as exercice ;-)
Christophe
Thank you!
Bert
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php