The session handling of php seems not to work very well on my computer:
if session.gc_probability is set to a value smaler 35, it never executes my
gabarage_collection-function. When it is bigger than 35, it's executed every
time.
I'm using W2K and php 4.02? Does anybody knows the reason for this
On php.net I found this:
When you use REMOTE_ADDR for getting the IP of the current user, sometimes
you get the IP of the ISP Cache server.
When this happens, the HTTP_X_FORWARDED_FOR is also set, it contains the IP
of the user.
[...]
Note that the X-Forwarded for header might contain multiple ad
Hi,
I'm using homesite 4.5.1 and I've not had the problem you describe.
However, since I use a remote server, when I have a php page up, and go to
design view, funny things do happen. I just don't go there anymore.
Hugh
- Original Message -
From: Andonny <[EMAIL PROTECTED]>
To: <[EMAIL PR
I can't seem to do any system(), exec(), passthru(), etc on my windows
system..
I've tried doing "command /c "...
Its showing
Warning: Unable to fork [command /c net] in c:\phpdev3\www\net.php on line 2
- James "ReDucTor" Mitchell
--
PHP General Mailing List (http://www.php.net/)
To un
On 09-Sep-2001 Dana Holt wrote:
>
> I have a query that uses a LEFT JOIN, but the two tables have some columns
> with the same name. How can I tell the columns from each table apart? It
> seems that the "joined" table overwrites the values from the other table.
>
If the column is part of the j
A "callback" is when you execute a function, and you provide to it a name of
*another* function, which it will call on some data in the middle of its
task.
It's a very handy way to provide extreme flexibility in functional
languages.
For example:
function my_array_walk($array, $function){
w
Hello Gaylen,
I am not sure what worldpay uses as an operating system but this work
just perfect. Thanks
Saturday, September 08, 2001, 6:09:08 PM, you wrote:
Gaylen Fraley> Is this under Windows? If so, it's probably passing \r\n : carriage
Gaylen Fraley> return/line feed. Check for both.
Ga
You wrote:
> I have a simple question...
> How can a space inserted to a string after the 3rd char ??
>
> washington ->> was hington
$str = 'washington';
$str = ereg_replace('^(.{3})(.*)$', '\\1 \\2', $str);
--
-Ryan :: ICQ - 595003 :: GigaBoard - http://www.gigaboard.net/
--
PHP Gene
Maybe something like:
$word="washington";
$length=strlen($word);
$a=substr($word,0,3);
$b=substr($word,3,$length-3);
$string=$a." ".$b;
print $string;
you might want to test for the length of $word first
to make sure $word has more than 3 characters
--- Andras Kende <[EMAIL PROTECTED]> wrot
Hi,
I have a simple question...
How can a space inserted to a string after the 3rd char ??
washington ->> was hington
Thanks :)
Andras
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To cont
I have a query that uses a LEFT JOIN, but the two tables have some columns
with the same name. How can I tell the columns from each table apart? It
seems that the "joined" table overwrites the values from the other table.
Anyone know?
Thanks.
--
Dana Holt / [EMAIL PROTECTED]
--
PHP Genera
It really depends on what you use the user input for.
If you are just storing into a database and splashing it out to a html page
later, htmlspecialchars( ) is adequete protection.
If this is a filename, then checks for the prefix "http://"; and '..' and
quotes in the file name, and a base dire
Hi,
Does the new version of homesite still have the same result with php. When
I used to change anything in Design View and then went back to Edit View
the ?> became ?>. Does this still happen???
Thanks
Andonny
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EM
I think my question could be restated to: What characters are potentially
lethal in user input. I can do the regex. But don't know what to parse out
of the strings.
would removing \ / . do the trick?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTE
Unfortunately, I can't access these settings. It's not our computer that
hosts
our website.
Regards,
Pieter Philippaerts
"Richard Lynch" <[EMAIL PROTECTED]> wrote in message
01e501c138ce$f3008300$6401a8c0@Lynchux100">news:01e501c138ce$f3008300$6401a8c0@Lynchux100...
> Options:
> Increase the set
Use something like this to find out what character is *REALLY* in the stuff
coming from worldpay:
for($i = 0; $i < strlen($worldpay_address); $i++){
$char = $worldpay_address[$i];
if (($ord = ord($char)) < 32){
echo "$char[$ord]";
}
else{
echo $char;
}
}
Anothe
Compare your with theirs and see what cURL differences
there are...
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
- Ori
There are various "sounds like" modules such as soundex and metaphone and
suchlike.
These can ameliorate bad spelling.
Another option, if you have a limited number of types available, is to give
the user a popup menu rather than free-form box to type in.
In general, the fewer ways you can provide
http://php.net/getenv
http://php.net/setenv
Why you want to set them in the Environment instead of just regular
variables is beyond me.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Vo
Compare PHP versions from your computer and
http://php.net/socket
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
- Origi
You'll have to define what you mean by "currently online".
Do you mean actually waiting this moment for HTML to finish streaming to
their browser?
Or do you just mean, in my session files and not timed out yet?
Probably the easiest way to do that would be to use
http://php.net/session-set-save-
That '4' you see is that this is the FOURTH thing you've asked MySQL to do
in this script.
You need to use http://php.net/mysql_result or other similar function to get
your actual answer.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? L
Add *ANOTHER* variable in the header("Location:") code that says
"&redirect=1"
In your page3, do:
if($redirect){
$menuID = $foo;
}
else{
$menuID = $bar;
}
Where foo comes from the location, but bar comes from page2.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EM
http://php.net/zlib
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
- Original Message -
From: Brack <[EMAIL PROTECTED
Options:
Increase the settings in MySQL that limit how many databases can be open at
once.
Decrease the number of Apache children running.
Basically, as long as you have more Apache children than MySQL connections
available, you can get this message.
Actually, have a few spare MySQL connections,
You probably won't be able to measure the difference unless you are doing
10,000 print statements...
Optimize the things that are slow, not the things that are already fast.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy
Use the MySQL function to_seconds or whatever it is.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
- Original Message --
@fopen(...) or error_log("Unable to fopen: $php_errormsg");
Check your Apache log after this.
http://php.net/error_log
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little
There's a Un*x utility for automagically doing this, but it leaves the new
file blank, almost for sure...
man logrotate
Can we safely assume no *other* PHP script is going to be trying to write to
this chat file while you're messing with it? If not, you really need to
move to a database solution
You can probably do a CGI install and only put the directives in your
.htaccess or inside your httpd.conf VirtualHost block.
For the Module, there's no way to Load/Unload for different Hosts.
You could do the LoadModule and only have the AddType in *your* Host, but
the Module itself would be part
http://php.net/readfile
http://php.net/header
You'll want to send Content-type: application/x-octet-stream if you want to
force download, or, errr, whatever a PDF is if you want them to just view
it.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help
You'll have to use the function to find out if the function is defined.
http://php.net/function_exists
You may want to mess with method_exists and try to define it as a method
rather than a global function, which is what I think you are doing at this
point.
--
WARNING [EMAIL PROTECTED] address i
You either see GD in all that mess, or it ain't there.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
- Original Message
It's done at the end of a function, or at any other time, when the variable
is no longer in scope.
You really only need this on a large, long-running script or where memory is
an issue...
For web-sites, that's quite rare.
For a shell script, it might make sense.
--
WARNING [EMAIL PROTECTED] ad
take out the header, and see if you have any error messages.
I'm also willing to bet that cdpf_open() returns some special values for
error -- Your code should check that.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy
You'll have to get a new version of php_dbg.dll from PHPEd, I think...
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
- O
Try not using "" and 0 for domain and secure. You're using the defaults
anyway, I think...
I think the "" is the real culprit...
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunte
You may need to escape it with "file\\ name" for the shell...
Only I woulda thought PHP would take care of that...
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little tim
You probably have differing versions of MySQL compiled into PHP and what you
are actually *running* on your computer.
Re-compile PHP and be sure to use --with-mysql=/path/to/your/mysql/source
That source *MUST* match your running MySQL server.
Watch the configure output messages, and be sure you
Is this under Windows? If so, it's probably passing \r\n : carriage
return/line feed. Check for both.
--
Gaylen
"Richard Kurth" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I have a problem I am trying to set up a credit card form for worldpay
>
> And in
Saturday, September 08, 2001, 5:40:46 PM, you wrote:
AM> when i submit a form and try to have it post a cookie in the php thing i get
AM> this error message:
AM> Warning: Cannot add header information - headers already sent by (output
AM> started at /usr/local/www/data/vi2dev/root/layout/functio
when i submit a form and try to have it post a cookie in the php thing i get
this error message:
Warning: Cannot add header information - headers already sent by (output
started at /usr/local/www/data/vi2dev/root/layout/functions.php:167) in
/usr/local/www/data/vi2dev/root/admin/manager.php on li
Hi,
What is a callback in preg_replace_callback(...) ?
how can I use it ? can anybody give me an example ?
Thanks,
Arash
--
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 administ
I have a problem I am trying to set up a credit card form for worldpay
And in the address field that I have to send to them it has to go in
a textarea
So when you fill this in it would look like this
address
city
state
Now this works fine for sending them the data but when the data is
sent ba
hi,
The long explanation is below the summary.
SUMMARY
page1.php
Header(location:page2.php)
page2.php
HTML link to page3.php
page3.php
REFERER=page1.php
But in page3 i WANT to see page2.php as REFERER.
So i suppose i must change something in page1. But what?
XXX
For emails I've seen some nice work somewhere in the annoted manual.
I think it's in the chapter about regular expressions..
http://www.php.net/manual/en/function.ereg.php
You might not only want to kill anything dangerous.. Checking email address
is also handy to prevent your database to be fi
It is an operator in PHP: %
ie. echo 3 % 2;
-Rasmus
On Sat, 8 Sep 2001, Ville Mattila wrote:
> Hi folks,
>
> I found this kind of formulae which should calculate the distance between two points
>on earth:
>
> tc1=mod(atan2(sin(lon1-lon2)*cos(lat2),
>cos(lat1)*sin(lat2)-sin(lat1)*c
Hi folks,
I found this kind of formulae which should calculate the distance between two points
on earth:
tc1=mod(atan2(sin(lon1-lon2)*cos(lat2),
cos(lat1)*sin(lat2)-sin(lat1)*cos(lat2)*cos(lon1-lon2)), 2*pi)
This is not PHP code, but now I would need the same formulae in PHP. But I
Wow... ok now i get it.. thanks guys
Aaron Moore
"Michael Kimsal" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Aaron, CC Zona wrote before that:
>
>
> If track_vars is on (always true if version >= 4.0.3), then the global
vars
> $HTTP_GET_VARS['bob'] and $H
Aaron, CC Zona wrote before that:
If track_vars is on (always true if version >= 4.0.3), then the global vars
$HTTP_GET_VARS['bob'] and $HTTP_GET_VARS['phil'] are already set.
And if register_globals is on, then the global vars $bob and $phil are also
already set.
--
php-general Digest 8 Sep 2001 18:30:26 - Issue 864
Topics (messages 66512 through 66538):
Re: how to execute a php script thru a cron job
66512 by: Carry Ian
Re: run a script for any HTTP request (was: run a script on access to a directory)
66513 by: Enrique Vadillo
I am looking for general a function to that would render user input
harmless.
I would write my own but don't know what to strip from the input that could
make it potentially damaging on linux boxes. I need to accept email and
phone numbers.
Thanks in advance,
Kevin
--
PHP General Mailing Li
I'm trying to get a count of the number of records in a database that have
the keyword "cat", for example. Below is the original code; I added the
query with count at the bottom of this code but it doesn't seem to be
working. I just get a return of "4" which doesn't correspond correctly with
the
http://php.net/parse_str
On Sat, 8 Sep 2001, Aaron Moore wrote:
> Well hers teh perl version of the the parser... how do i convert this to php
>
> $tmp = $ENV{'QUERY_STRING'};
> @pairs = split(/&/, $tmp);
>
> foreach $item (@pairs) {
> ($key, $content) = split(/=/,$item,2);
> $content =~ tr/+/
Well hers teh perl version of the the parser... how do i convert this to php
$tmp = $ENV{'QUERY_STRING'};
@pairs = split(/&/, $tmp);
foreach $item (@pairs) {
($key, $content) = split(/=/,$item,2);
$content =~ tr/+/ /;
$content =~ s/%(..)/pack("c",hex($1))/ge;
$fields{$key} = $content;
}
-
>From the smarty manual
{literal}