Re: [PHP] Protecting database passwords

2004-07-01 Thread - Edwin -
Hi, On Wednesday 30 June 2004 09:58, Bob Hockney wrote: Hi there, I wrote a php script that accesses a database, and I am wondering about securing the password to the database. I could prompt the user for the password every session, but I don't necessarily want the user to have the

Re: [PHP] What do I need in order to do the following with php.

2004-07-01 Thread - Edwin -
On Thursday 01 July 2004 01:38, [EMAIL PROTECTED] wrote: I want to make sure I'm correct in doing something. What do I need in order to perform the following: - Send an XML message to something at a website, have it load a database with the message, and

Re: [PHP] Protecting database passwords

2004-07-01 Thread - Edwin -
On Thursday 01 July 2004 02:17, Chris W. Parker wrote: Red Wingate mailto:[EMAIL PROTECTED] on Wednesday, June 30, 2004 9:33 AM said: Hashing ... but i guess he wants to protected the password needed to access the DB not a PW stored in the DB. you probably understand this already

Re: [PHP] Re: Converting strings to match multiple charsets

2004-07-01 Thread - Edwin -
On Thursday 01 July 2004 06:42, Red Wingate wrote: yep, as i said it was displayed correctly everywhere expect in the forms oh i might mention - Mozilla worked well but IE destroyed the data (only in textareas) Just an idea... How about doing something like this: Retrieve data from the

Re: [PHP] Web live radio

2004-07-01 Thread ascll
Raditha Dissanayake [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] PHP is probably not the sbest technology for streaming content. Take a look at shoutcast or icecast or some other product like that which are custom made for this purpose. SHOUTcast vs Icecast, which one is better

Re: [PHP] Protecting database passwords

2004-07-01 Thread - Edwin -
On Thursday 01 July 2004 08:25, Chris W. Parker wrote: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] on Wednesday, June 30, 2004 4:15 PM said: How can I use a password hash to log on to a database server (or for any other login for that matter)? i apologize. i completely misunderstood

Re: [PHP] Is that a PECL in your pants?

2004-07-01 Thread - Edwin -
On Thursday 01 July 2004 13:56, Curt Zirzow wrote: * Thus wrote John W. Holmes: Curt Zirzow wrote: Thanks for the explanation Curt. I'll do my best to educate! :) As far as XSLT and XSL, the one is prefered over the other. What do you mean by this? XSLT is preferred over XSL?

Re: [PHP] Is that a PECL in your pants?

2004-07-01 Thread John W. Holmes
- Edwin - wrote: I guess it's more on the underlying library. (i.e. Sablotron vs libxslt) Yeah, I guess that's what I meant; the XSLT extension versus the XSL extension which basically comes down to the libraries powering them. Anyone have any recommendations which one would be better to use in

Re: [PHP] Protecting database passwords

2004-07-01 Thread Curt Zirzow
* Thus wrote - Edwin -: On Thursday 01 July 2004 02:17, Chris W. Parker wrote: Red Wingate mailto:[EMAIL PROTECTED] on Wednesday, June 30, 2004 9:33 AM said: Hashing ... but i guess he wants to protected the password needed to access the DB not a PW stored in the DB. you

Re: [PHP] imagerotate - lossless?

2004-07-01 Thread - Edwin -
On Thursday 01 July 2004 12:20, CSN wrote: Anybody know if imagerotate does lossless rotation on jpeg's? I don't know :) but maybe you can try this: Rotate an image 360°, save it under a different name, then examine it. (filesize, quality, etc.) - E - -- PHP General Mailing List

Re: [PHP] Is that a PECL in your pants?

2004-07-01 Thread - Edwin -
On Thursday 01 July 2004 15:49, John W. Holmes wrote: - Edwin - wrote: I guess it's more on the underlying library. (i.e. Sablotron vs libxslt) Yeah, I guess that's what I meant; the XSLT extension versus the XSL extension which basically comes down to the libraries powering them.

Re: [PHP] What do I need in order to do the following with php.

2004-07-01 Thread Gabriel Birke
I want to make sure I'm correct in doing something. What do I need in order to perform the following: - Send an XML message to something at a website, have it load a database with the message, and return an acknowledgement.

Re: [PHP] What do I need in order to do the following with php.

2004-07-01 Thread Justin Patrin
On Thu, 1 Jul 2004 09:13:16 +0200, Gabriel Birke [EMAIL PROTECTED] wrote: I want to make sure I'm correct in doing something. What do I need in order to perform the following: - Send an XML message to something at a website, have it load a database

[PHP] Re: Converting strings to match multiple charsets

2004-07-01 Thread Torsten Roehr
Red Wingate [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] yep, as i said it was displayed correctly everywhere expect in the forms oh i might mention - Mozilla worked well but IE destroyed the data (only in textareas) Do you run the utf8 decoded data through htmlentities()? What

[PHP] Re: problem with embeded objects and reference

2004-07-01 Thread Daniel Kullik
Vincent Dupont wrote: Hi, could anyone help on this 'by reference' problem. I have 2 classes. The main class as a child class. The child class has properties (array) I would like to be able to manipulate the child's properties even after the child has been inserted into the main class. Does this

[PHP] Re: install/config error - please help

2004-07-01 Thread David Robley
On Wed, 30 Jun 2004 23:01, Long P Nguyen wrote: any ideas with this install/config error? [EMAIL PROTECTED] php-4.3.7]# ./configure --with-mysql=/usr/local/mysql creating cache ./config.cache checking host system type... i686-pc-linux-gnu checking for gcc... gcc checking whether the C

[PHP] Session file problem?

2004-07-01 Thread [EMAIL PROTECTED]
Code I¹m using: session_cache_expire(0); session_cache_limiter('private'); setcookie(cookie,,0,/,iffinet.com,1); session_start(); I use session_destroy(); in the logout function but the /tmp/sess_* file does not get deleted. Also the cookie doesn¹t go away even though it is set to expire at

Re: [PHP] Protecting database passwords

2004-07-01 Thread Gerben
I think he is talking about the password that is written inside the script in the mysql_connect statement. I think he is worried that someone could access it's code and find out the DB password. One solution is to make the database only accessible from localhost (you could create a new user/pass

[PHP] flock(), fclose() and O/S buffering

2004-07-01 Thread Andrew Hill
Hi all, I have a question about the way flock() and fclose() work in PHP. Consider the following code, slightly modified from the flock() PHP manual page: $fp = fopen(/tmp/lock.txt, w+); if (flock($fp, LOCK_EX)) { // do an exclusive lock fwrite($fp, $processName\n); flock($fp, LOCK_UN);

[PHP] Re: Session file problem?

2004-07-01 Thread Daniel Kullik
[EMAIL PROTECTED] wrote: Code I¹m using: session_cache_expire(0); session_cache_limiter('private'); setcookie(cookie,,0,/,iffinet.com,1); session_start(); I use session_destroy(); in the logout function but the /tmp/sess_* file does not get deleted. Also the cookie doesn¹t go away even though it

[PHP] mod_rewrite

2004-07-01 Thread pete M
Know this is off topic bu can anyone help with a tuotial of something - been looking everywhere All I want is a rule to rewrite www.example.com?page=mypageid=20this=that to www.example.com/mypage/20/this tia Pete -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

RE: [PHP] flock(), fclose() and O/S buffering

2004-07-01 Thread Michael Sims
Andrew Hill wrote: $fp = fopen(/tmp/lock.txt, w+); if (flock($fp, LOCK_EX)) { // do an exclusive lock fwrite($fp, $processName\n); flock($fp, LOCK_UN); // release the lock } else { echo Couldn't lock the file !; } fclose($fp); [...] In this case, although process B is the second

Re: [PHP] Re: How to escape apostrophe in HTML textbox exactly???

2004-07-01 Thread Scott Fletcher
Clicked on the search query on php.net and got to one website after another which then lead to this website http://us4.php.net/manual/en/function.mysqli-real-escape-string.php Now, I see the problem, the i was added to the word, mysql. So, probably clicked on the wrong link somewhere

[PHP] mysql_escape_string() vs addslashes()...

2004-07-01 Thread Scott Fletcher
I would argue that something like mysql_escape_string() is better than addslashes(), so I agree with you for the most part anyway. :-) It all depends on what database is being used and how. Starting a new topic since the related-topic lists got too long. So, run that again about what you

RE: [PHP] mod_rewrite[Scanned]

2004-07-01 Thread Michael Egan
Pete, There was a thread some time ago on the issue of cloaking URLs in which a couple of contributors pointed to tutorials on the following site: http://www.alistapart.com/articles/urls/ HTH, Michael Egan -Original Message- From: pete M [mailto:[EMAIL PROTECTED] Sent: 01 July 2004

[PHP] mysql_escape_string vs. mysqli_escape_string....

2004-07-01 Thread Scott Fletcher
What the hell??? When I enter the mysql_escape_string in the search for textbox at www.php.net, I get a mysqli_escape_string result. So, the question here is, is the website mistaken or is someone made a typo when posting to this php newsgroup??? Scott F. -- PHP General Mailing List

RE: [PHP] Is that a PECL in your pants?

2004-07-01 Thread Ford, Mike [LSS]
On 01 July 2004 04:10, John W. Holmes wrote: Can anyone explain the purpose of PECL to me besides what it says on the web page (http://pecl.php.net)? Besides what's already been said, it also decouples the release cycles of the extensions from that of PHP itself. An upgrade to a PECL

RE: [PHP] mod_rewrite

2004-07-01 Thread David Bevan
Hi Pete, Check out the documentation on the Apache site: http://httpd.apache.org/docs-2.1/mod/mod_rewrite.html They also have a URL Rewriting Guide: http://httpd.apache.org/docs-2.1/misc/rewriteguide.html Hope this helps. Regards, David -Original Message- From: pete M

Re: [PHP] Re: How to escape apostrophe in HTML textbox exactly???

2004-07-01 Thread Scott Fletcher
Ah, when I enter the mysql_escape_string in the search for textbox, I get a mysqli_escape_string webpage So, it wasn't me that make a mistake after all I didn't know there is mysqli as well. Scott F. Scott Fletcher [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Clicked on

Re: [PHP] Protecting database passwords

2004-07-01 Thread Bob Hockney
Gerben wrote: I think he is talking about the password that is written inside the script in the mysql_connect statement. I think he is worried that someone could access it's code and find out the DB password. What I am concerned about is a local user on the server machine, not access through

[PHP] Help ASAP

2004-07-01 Thread Syed Ghouse
Hi All (B (BWill anybody tell me how to execute a shell script thru php (B (Band how to create a unix user thru php (B (BThanks in advance (B (BRegards (BSyed

[PHP] Re: Help ASAP

2004-07-01 Thread Torsten Roehr
Syed Ghouse [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi All Will anybody tell me how to execute a shell script thru php and how to create a unix user thru php Thanks in advance Regards Syed Take a look here: http://de.php.net/function.shell-exec Regards, Torsten Roehr --

[PHP] Redirecting a user

2004-07-01 Thread Shaun
Hi, Please could someone tell me how I can redirect a user to the page they came from including any query strings attached to the URL? Many thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Protecting database passwords

2004-07-01 Thread John W. Holmes
From: Bob Hockney [EMAIL PROTECTED] I think he is talking about the password that is written inside the script in the mysql_connect statement. I think he is worried that someone could access it's code and find out the DB password. What I am concerned about is a local user on the server

[PHP] Re: Redirecting a user

2004-07-01 Thread Torsten Roehr
Shaun [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, Please could someone tell me how I can redirect a user to the page they came from including any query strings attached to the URL? header('location: ' . $_SERVER['REQUEST_URI']); exit; Regards, Torsten Roehr -- PHP General

[PHP] Comparison Operator

2004-07-01 Thread Gabe
I was looking at the comparison operators page and noticed that these two operators were listed as PHP4 only. Is that an error, or are they really not used in PHP5? I don't want to use them if they're going to break when I upgrade. And if they aren't included, then does something else

RE: [PHP] Comparison Operator

2004-07-01 Thread Michael Sims
Gabe wrote: I was looking at the comparison operators page and noticed that these two operators were listed as PHP4 only. Is that an error, or are they really not used in PHP5? I don't want to use them if they're going to break when I upgrade. And if they aren't included, then does

Re: [PHP] Comparison Operator

2004-07-01 Thread Gabe
Michael Sims wrote: Gabe wrote: I was looking at the comparison operators page and noticed that these two operators were listed as PHP4 only. Is that an error, or are they really not used in PHP5? I don't want to use them if they're going to break when I upgrade. And if they aren't included,

[PHP] Re: mysql_escape_string vs. mysqli_escape_string....

2004-07-01 Thread Thomas Seifert
Scott Fletcher wrote: What the hell??? When I enter the mysql_escape_string in the search for textbox at www.php.net, I get a mysqli_escape_string result. So, the question here is, is the website mistaken or is someone made a typo when posting to this php newsgroup??? Scott F. I get

Re: [PHP] Comparison Operator

2004-07-01 Thread Curt Zirzow
* Thus wrote Michael Sims: Gabe wrote: I was looking at the comparison operators page and noticed that these two operators were listed as PHP4 only. Is that an error, or are they really not used in PHP5? I don't want to use them if they're going to break when I upgrade. And if they

Re: [PHP] Protecting database passwords

2004-07-01 Thread Peter Risdon
Bob Hockney wrote: Gerben wrote: I think he is talking about the password that is written inside the script in the mysql_connect statement. I think he is worried that someone could access it's code and find out the DB password. What I am concerned about is a local user on the server machine, not

Re: [PHP] mysql_escape_string() vs addslashes()...

2004-07-01 Thread Curt Zirzow
* Thus wrote Scott Fletcher: I would argue that something like mysql_escape_string() is better than addslashes(), so I agree with you for the most part anyway. :-) It all depends on what database is being used and how. Starting a new topic since the related-topic lists got too long.

[PHP] ?php include(str_replace(.html, .htm, $_SERVER[PATH_TRANSLATED]));?

2004-07-01 Thread John Taylor-Johnston
Hi, I need another variable. I need the filename itself. I want to substitute /var/www/html/new1/foo.html for /var/www/html/new1/phpinfo.htm and then include /var/www/html/new1/html/phpinfo.htm This doesn't do it anymore. I can't see a way to go up to directory html: ?php

[PHP] Re: Redirecting a user

2004-07-01 Thread John Taylor-Johnston
Apache can do this too, right? I'm sure I saw a bit of code floating about? Torsten Roehr wrote: Shaun [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, Please could someone tell me how I can redirect a user to the page they came from including any query strings attached

Re: [PHP] mysql_escape_string() vs addslashes()...

2004-07-01 Thread Scott Fletcher
In that case, I'll have to stick to addslashes() instead of mysql_real_escape_string() because I'm escaping some of the PHP's post string in the MySQL's syntax and not yet using the mysql's connection until some decision making script play a role in it. Blah!! Thanks, Scott F. Curt Zirzow

[PHP] I'm very curious about the object-orientated thingies in PHP 5.....

2004-07-01 Thread Scott Fletcher
Hey everyone, I'm very curious about the object-orientated thingies in PHP 5. Anyone know of a sample scripts I can read it on? And how does it work since the browser-webserver is one sided in communication or one way, not both way? Scott F. -- PHP General Mailing List

[PHP] Re: I'm very curious about the object-orientated thingies in PHP 5.....

2004-07-01 Thread Torsten Roehr
Scott Fletcher [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hey everyone, I'm very curious about the object-orientated thingies in PHP 5. Anyone know of a sample scripts I can read it on? And how does it work since the browser-webserver is one sided in communication or one

[PHP] sending html via SOAP

2004-07-01 Thread Vidyut Luther
Hi, I'm using the NuSOAP class to get some information from a different physical server, so far i've gotten the basic methods done, but I was wondering if it's a good idea to have the server return a complete html form back via the SOAP envelope, or should I do something else ?. Just tryin to

Re: [PHP] ?php include(str_replace(.html, .htm, $_SERVER[PATH_TRANSLATED]));?

2004-07-01 Thread Matt M.
On Thu, 01 Jul 2004 11:52:47 -0400, John Taylor-Johnston [EMAIL PROTECTED] wrote: Hi, I need another variable. I need the filename itself. I want to substitute /var/www/html/new1/foo.html for /var/www/html/new1/phpinfo.htm I am not exactly sure what you want to do but I think you

Re: [PHP] mysql_escape_string vs. mysqli_escape_string....

2004-07-01 Thread Justin Patrin
On Thu, 1 Jul 2004 09:37:46 -0400, Scott Fletcher [EMAIL PROTECTED] wrote: What the hell??? When I enter the mysql_escape_string in the search for textbox at www.php.net, I get a mysqli_escape_string result. So, the question here is, is the website mistaken or is someone made a typo when

Re: [PHP] Web live radio

2004-07-01 Thread raditha dissanayake
ascll wrote: SHOUTcast vs Icecast, which one is better and easier to setup? that's not a question for the php list! Thanks. -- Raditha Dissanayake. - http://www.raditha.com/megaupload/upload.php Sneak past the PHP file upload limits. -- PHP

[PHP] XSL was:Re: [PHP] Is that a PECL in your pants?

2004-07-01 Thread raditha dissanayake
- Edwin - wrote: As far as XSLT and XSL, the one is prefered over the other. What do you mean by this? XSLT is preferred over XSL? Any reasons why you can point me to? Thanks again. I probably should have edited that part out, I only know that through rumors. I'm unfamiliar

Re: [PHP] mysql_escape_string vs. mysqli_escape_string....

2004-07-01 Thread Scott Fletcher
try mysql_escape_string(). and I'm using Mozilla... Justin Patrin [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Thu, 1 Jul 2004 09:37:46 -0400, Scott Fletcher [EMAIL PROTECTED] wrote: What the hell??? When I enter the mysql_escape_string in the search for textbox at

Re: [PHP] Protecting database passwords

2004-07-01 Thread Siddharth Hegde
Not really a direct solution, but anyways...You could use Turck MMCache to convert the code into bytecode. That way nobody can see the password, atleast not too easily. - Sid On Thu, 01 Jul 2004 16:28:57 +0100, Peter Risdon [EMAIL PROTECTED] wrote: Bob Hockney wrote: Gerben wrote: I

Re: [PHP] mysql_escape_string vs. mysqli_escape_string....

2004-07-01 Thread Justin Patrin
I'm using Firefox. If I use mysql_escape_string() I get a listing of functions which does include mysql_escape_string and mysqli_escape_string. It doesn't go straight to mysqli_escape_string, though. If you search without parenthesis, it works as expected. You don't need (aren't supposed to use)

[PHP] PHP5 contest

2004-07-01 Thread Siddharth Hegde
Hi, Does anyone know who to contact if they have any Qs regarding the PHP5 contest. One of the Qs I had - Are we allowed to use Pear library and classes. Thanks, - Sid -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] [Stats] PHP Net List: June 2004

2004-07-01 Thread Bill Doerrfeld
-- Searchable archives for this list are available at http://www.listsearch.com/phplist.lasso --

[PHP] Re: I'm very curious about the object-orientated thingies in PHP 5.....

2004-07-01 Thread Lars Torben Wilson
Scott Fletcher wrote: Hey everyone, I'm very curious about the object-orientated thingies in PHP 5. Anyone know of a sample scripts I can read it on? And how does it work since the browser-webserver is one sided in communication or one way, not both way? Scott F. Zend.com is absolutely

Re: [PHP] PHP5 contest

2004-07-01 Thread Richard Davey
Hello Siddharth, Thursday, July 1, 2004, 7:17:52 PM, you wrote: SH Does anyone know who to contact if they have any Qs regarding the PHP5 SH contest. One of the Qs I had - Are we allowed to use Pear library and SH classes. Do you mean the Zend PHP5 contest? If so, yes you can use PEAR

Re: [PHP] PHP5 contest

2004-07-01 Thread Siddharth Hegde
Do you mean the Zend PHP5 contest? Yes, Thank you On Thu, 1 Jul 2004 19:28:02 +0100, Richard Davey [EMAIL PROTECTED] wrote: Hello Siddharth, Thursday, July 1, 2004, 7:17:52 PM, you wrote: SH Does anyone know who to contact if they have any Qs regarding the PHP5 SH contest. One of the

Re: [PHP] PHP5 contest

2004-07-01 Thread John W. Holmes
Siddharth Hegde wrote: Does anyone know who to contact if they have any Qs regarding the PHP5 contest. One of the Qs I had - Are we allowed to use Pear library and classes. That's a good question. I bet that's asked frequently. They should make a list of questions like that and call it a QTAFA;

Re: [PHP] Protecting database passwords

2004-07-01 Thread Peter Brodersen
On Thu, 01 Jul 2004 06:55:38 -0700, [EMAIL PROTECTED] (Bob Hockney) wrote: What I am concerned about is a local user on the server machine, not access through the web server. It sounds like it can be done if there is a separate user or group for the web server process, but this site specific.

[PHP] regex problem

2004-07-01 Thread Josh Close
I'm trying to get a simple regex to work. Here is the test script I have. #!/usr/bin/php -q ? $string = hello\nworld\n; $string = preg_replace(/[^\r]\n/i,\r\n,$string); $string = addcslashes($string, \r\n); print $string; ? This outputs hell\r\nworl\r\n so it's removing the char before the

Re: [PHP] regex problem

2004-07-01 Thread Justin Patrin
On Thu, 1 Jul 2004 16:41:50 -0500, Josh Close [EMAIL PROTECTED] wrote: I'm trying to get a simple regex to work. Here is the test script I have. #!/usr/bin/php -q ? $string = hello\nworld\n; $string = preg_replace(/[^\r]\n/i,\r\n,$string); $string =

[PHP] Re: regex problem

2004-07-01 Thread Lars Torben Wilson
Josh Close wrote: I'm trying to get a simple regex to work. Here is the test script I have. #!/usr/bin/php -q ? $string = hello\nworld\n; $string = preg_replace(/[^\r]\n/i,\r\n,$string); First, the short version. You can fix this by using backreferences: $string = preg_replace(/([^\r])\n/i,

Re: [PHP] regex problem

2004-07-01 Thread Josh Close
Why is it taking the char before the [^\r] also? -Josh On Thu, 1 Jul 2004 15:17:04 -0700, Justin Patrin [EMAIL PROTECTED] wrote: On Thu, 1 Jul 2004 16:41:50 -0500, Josh Close [EMAIL PROTECTED] wrote: I'm trying to get a simple regex to work. Here is the test script I have.

[PHP] Re: regex problem

2004-07-01 Thread Josh Close
Thanks, that's exactly what I was looking for. -Josh On Thu, 01 Jul 2004 15:17:41 -0700, Lars Torben Wilson [EMAIL PROTECTED] wrote: Josh Close wrote: I'm trying to get a simple regex to work. Here is the test script I have. #!/usr/bin/php -q ? $string = hello\nworld\n;

Re: [PHP] regex problem

2004-07-01 Thread Curt Zirzow
* Thus wrote Justin Patrin: On Thu, 1 Jul 2004 16:41:50 -0500, Josh Close [EMAIL PROTECTED] wrote: I'm trying to get a simple regex to work. Here is the test script I have. #!/usr/bin/php -q ? $string = hello\nworld\n; $string = preg_replace(/[^\r]\n/i,\r\n,$string); $string

[PHP] Create a function

2004-07-01 Thread John Taylor-Johnston
I have a menu with a bunch of items. How can I clean up this code and push it through a function? Your basic newbie Question :) Thanks, John pa class=nav href=index.html?php if(stristr($_SERVER[SCRIPT_FILENAME],index.html)) { echo bHome/b; }else{ echo Home; } ?/a pa class=nav href=index.html?php

[PHP] Re: Create a function

2004-07-01 Thread Jason Barnett
$pages = array('index.html' = 'Home', 'search.html' = 'Search'); function menu($pages) { foreach ($pages as $page = $desc) { if (stristr($_SERVER['SCRIPT_FILENAME']), $page) { echo 'pa class=nav href=index.html/ab' . $desc . '/b/p'; } else { echo 'pa class=nav

[PHP] Re: Create a function

2004-07-01 Thread Jason Barnett
Jason Barnett wrote: $pages = array('index.html' = 'Home', 'search.html' = 'Search'); function menu($pages) { foreach ($pages as $page = $desc) { if (stristr($_SERVER['SCRIPT_FILENAME']), $page) { sheesh, $desc should be in between anchors echo 'pa class=nav href=index.htmlb' . $desc

[PHP] Online Users

2004-07-01 Thread Matt Palermo
I am trying to keep a MySQL table of all currently online users for a system I'm making. It's pretty simple to add the username to the list when they login, but I don't know how to remove their username when they leave (unless they click the logout button). Basically I want to be able to keep a

Re: [PHP] Online Users

2004-07-01 Thread Curt Zirzow
* Thus wrote Matt Palermo: they click the logout button). Basically I want to be able to keep a list of all currently active users. So if they close out their browser, it will remove their name from the list (within a reasonable time frame). I'm No can do. You'll just have to expire people

Re: [PHP] Online Users

2004-07-01 Thread zareef ahmed
Hi, If you are using a database on your server you can do this as follows: 1. Make a table named active_users(userid,last_access); 2. Record every visit of a user to any page. 3. you can delete the entries from this table on a condition like :: delete from active_users where last_access is less

[PHP] PHP Bug ?

2004-07-01 Thread adwinwijaya
Hi... I found a bug (may be) I tried to do like this: $temp = $country_list[$country_symbol['AU']] ; this didnt work, so I have to change to : $symbol = $country_symbol['AU']; $temp = $country_list[$symbol] ; is this PHP bug ? -- Best regards, adwinwijaya

Re: [PHP] PHP Bug ?

2004-07-01 Thread zareef ahmed
Hi, which version on php u r using? it should work. (Actually working on own system with php 4.3.2) try $country_list[($country_symbol['AU'])]; Zareef Ahmed --- adwinwijaya [EMAIL PROTECTED] wrote: Hi... I found a bug (may be) I tried to do like this: $temp =

[PHP] HTTP RAW DATA

2004-07-01 Thread Alan McDonald
Does anyone know a way of getting the raw data passed back from a server? I want to compare the total raw data sent back from Apache with that sent back from IIS for a particular file. I don;t want any filtering at all and I need to catch it so I can see it all. Thanks Alan -- PHP General

[PHP] HTTP_AUTHORIZATION question

2004-07-01 Thread Alan McDonald
I have files contained in a download directory (.doc, .xls etc files) so I can't request authentication on each download from insie the files. I use authentication against a DB for the rest of the site and all pages are protected this way. My only way to protect these download files is to place

Re: [PHP] Online Users

2004-07-01 Thread Matt Palermo
Is it possible to make a table of all logged in users session ids and then check to see if the session still exists every couple minutes? So every minute or two, it would go through the table and for each record it would get the session id, then check that session id to see if it's still in

Re: [PHP] HTTP_AUTHORIZATION question

2004-07-01 Thread raditha dissanayake
Alan McDonald wrote: I have files contained in a download directory (.doc, .xls etc files) so I can't request authentication on each download from insie the files. I use authentication against a DB for the rest of the site and all pages are protected this way. My only way to protect these download

Re: [PHP] HTTP RAW DATA

2004-07-01 Thread raditha dissanayake
Alan McDonald wrote: Does anyone know a way of getting the raw data passed back from a server? I want to compare the total raw data sent back from Apache with that sent back from IIS for a particular file. I don;t want any filtering at all and I need to catch it so I can see it all. Thanks Alan

[PHP] Just wanted to say....

2004-07-01 Thread Brent Clements
PHP 5 rocks. Thanks to all of the developers who have spent their time and efforts creating such an awesome application development language. Sincerely, Brent Clements Innovative PHP Solutions, L.L.C.