RE: [PHP] php / apache

2001-06-30 Thread Jason Lustig
Why would you want to do that? I don't think it's really possible... unless you do something wacky with Apache... --Jason -- 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

[PHP] Parse error: Needs T_VARIABLE or $

2001-06-30 Thread Jason Lustig
This is really weird. Very, very, very weird. I have the following code in a script: if (!empty(trim($rowData[3]))) { $tdStr.= trim($rowData[3]); } Now, when I run it, I get the following error: Parse error: parse error, expecting `T_VARIABLE' or `'$'' in c:\server\wwwroot\contributor

RE: [PHP] closing window after submit

2001-06-30 Thread Jason Lustig
use onsubmit = "somefunction();" in the tag, and make the somefunction() function close the window. --Jason -- 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

RE: [PHP] PHP Menu.

2001-06-28 Thread Jason Lustig
You would have to use javascript to do that... PHP is server-side, not client-side. You could create the javascript with PHP, but the PHP can't make the menu pop out and stuff... --Jason -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

RE: [PHP] $REMOTE_ADDR error

2001-06-28 Thread Jason Lustig
>Also, if your web-server is on your machine, well, you always are 127.0.0.1 >when you surf... It depends on what you have your server set up as. If you have your server set up to listen to the IP 128.205.233.10 then $REMOTE_ADDR will return 128.205.233.10, even if it's on your machine... --Jaso

RE: [PHP] PHP crashing IIS 5 on Wnidows 2K

2001-06-27 Thread Jason Lustig
>Assuming that you are using the ISAPI version of PHP, it is >probably crashing >because that version of PHP is not very stable. You should upgrade >to 4.0.6 >which contains improvements in that area, but it is still not >perfect. If you >find 4.0.6 unstable either change from ISAPI to CGI or if y

RE: [PHP] RE: Events Listings

2001-06-27 Thread Jason Lustig
If you don't have access to a database, why not put all the data in arrays and then use the array sorting functions? --Jason -- 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 admini

[PHP] PHP crashing IIS 5 on Wnidows 2K

2001-06-26 Thread Jason Lustig
I have PHP 4.04pl1 set up on a IIS 5 server on Windows 2k. However, it keeps on crashing the server -- not all the time, but sometimes it does, sometimes it doesn't. And I have no idea whatsoever what is causing it. I *think* that it has to do with my include()s. I end up including all my function

RE: [PHP] Enter to BR

2001-06-26 Thread Jason Lustig
try nl2br() --Jason -- 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] Passing an array to a C program from a php script??

2001-06-26 Thread Jason Lustig
Why not make a separate .txt file which is read by the PHP script to make its variable with file(), and have the C file read it with ifstream to make up its variable? --Jason -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-

RE: [PHP] Expand/parse variables in file

2001-06-26 Thread Jason Lustig
>$a = "whatever"; >$b = "abc $a def"; >echo $b; > >which results in "abc whatever def" ??? > >What am I missing? $b = "abc $a def"; That gets parsed because it's in double-quotes. Since $a is a variable, it inputs whatever $a is, in this case "Whatever". So it ends up printnig out "abc whatever

RE: [PHP] Percentages

2001-06-24 Thread Jason Lustig
How 'bout using this hack: function formatPercent ($decimal, $round = 2) { return round($decimal*100, $round).'%'; } --Jason -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the lis

RE: [PHP] $PHP_SELF name space?

2001-06-24 Thread Jason Lustig
$PHP_SELF is a global variable. You're trying to call it from inside a function, which won't work unless you declare it as global to the function (unless you have some thing in the php.ini file set that I don't remember off the top of my head what it's called which will make all that stuff global

RE: [PHP] Program execution functions doesn´t work in my system

2001-06-24 Thread Jason Lustig
>I need to run some external programs from a PHP script. >How could I do that? You might be able to use them through (D)COM objects, since you're on an NT server. I'm not sure about the passthrough() functions and stuff on NT, though... I've never really used them (or had reason to). --Jason -

RE: [PHP] php not working

2001-06-24 Thread Jason Lustig
>I've added the lines: >AddType application/x-httpd-php .php >AddType application/x-httpd-php-source .phps >to my httpd.conf file Maybe try adding: AddType application/x-httpd-php4 .php instead of: AddType application/x-httpd-php .php It depends on how you did th

[PHP] Connecting to a remote MSSQL database via ODBC and setting up the MSSQL extension

2001-06-24 Thread Jason Lustig
I am connecting to a remote MSSQL database from my dev box (windows/apache/php4.06). However, my dev box doesn't have MSSQL installed on it (or else I wouldn't have to connect remotely -- I could copy the DB file to the comp and then use it in MSSQL, connecting locally). To use the MSSQL extension

[PHP] PEAR

2001-06-23 Thread Jason Lustig
I just installed PHP 4.06 on my setup, and noticed that there's a bunch of classes/scripts in the /pear directory. Does anyone know what the status of these scripts are, as in if they are finished quality (ie, they can be used successfully on websites)? I thought that PEAR was still being develope

RE: [PHP] Is it possible to have the parameters fo a function be exited HTML?

2001-06-23 Thread Jason Lustig
> >Its probably just as fast for you to test it out using what you >have written >here as it is for someone to give you the answer. > Well, that thought occurred to me just after I sent the email... but there's nothing you can do after hitting the "send" button, can you? --Jason -- PHP Genera

RE: [PHP] Variable variable names...

2001-06-22 Thread Jason Lustig
There's a number of things you can do with variable variables... they're quite powerful, I like 'em a lot. :) Anyway, you can do This would output stuff I think that's what you were asking... You've got to use the { and } around the variables you're using to make teh variable variable.

[PHP] Which is more expensive: concatenation or embedding?

2001-06-22 Thread Jason Lustig
There are two ways to get your variables into a string -- concatenation with single-quoted strings, or embedding in evaluated double-quoted strings. Which is more expensive to the server? For example: Now, which is more expensive? Is it more expensive to concatenate them, or to evaluate the wh

RE: [PHP] SQL statement for clearing a table

2001-06-22 Thread Jason Lustig
This SQL statement: "DELETE FROM myTable;" That should work... pretty much, unless you give a WHERE statement, it will do whatever you want (UPDATE, SELECT, DELETE, etc) to every record in the table. --Jason -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PRO

[PHP] Is it possible to have the parameters fo a function be exited HTML?

2001-06-22 Thread Jason Lustig
Is it possible to break up the parameters of a function with ?> and http://www.php.net";>php.net With this example, will it output the following HTML? HTTP://WWW.PHP.NET";>PHP.NET I know i