[PHP] get filename?

2001-03-20 Thread KPortsmout
Hi Whats the best method to get the filename of the file I am using. E.G if the file is called tom_woz_here.php and would I go about stickin that into $FileName= ??? Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,

[PHP] Header Problem

2001-03-20 Thread KPortsmout
Hi, I`m having whats probably a very basic problem but just can`t get my head around it this late in the day, anyone have any idea why this won`t work? $URL="domain.com"; header ("Location: Http://www.$URL/members/index.php"); $URL changes so I can`t write it directly into the header line,

[PHP] Sessions help please

2001-03-21 Thread KPortsmout
Hi, I am going to use sessions to authenticate and protect my pages, this is what I have so far... User logs in via form, this is checked via a SQL call, if the correct username and password are entered I run the following: session_start(); session_register("UserName","Password");

[PHP] Session Confusion

2001-03-23 Thread KPortsmout
Ok these sessions have got me all confused, I need to have two seperate sessions one for when a user signs up, to stop them using there back button and inadvertantly signing up twice. And then one when they login. Both of them work great as standalone but if say I went and log into my account

Re: [PHP] Session Confusion

2001-03-23 Thread KPortsmout
If that's a copy of your code, you might want to check the if($SET=1) line...that will always return true, because you're setting a variable, not checking for equality...should be if($SET==1) instead jack Ooops ok put that bit right, I should really know better :-) but it still doesn`t

Re: [PHP] php4 but dont work with php3

2001-03-24 Thread KPortsmout
Hi, I`m not sure if this is 100% the right method but you can try it and see. Change httpd.conf to the following. AddType application/x-httpd-php .php .php3 Ade -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail:

Re: [PHP] Delaying Printed Output

2001-03-24 Thread KPortsmout
In a message dated 24/03/2001 14:47:03 GMT Standard Time, [EMAIL PROTECTED] writes: Is it possible using PHP to print a single line of text to a browser, have a second or two delay and then print the next line, etc. etc.? Greg Hi, You can use the following commands: sleep(seconds);

[PHP] MySQL Schema

2001-03-28 Thread KPortsmout
Hi, Is there any way in PHP to print out the schema of my database tables? Cheers Ade -- 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] Tough One

2001-03-29 Thread KPortsmout
Hi, Ok I have a real tough one here (well to me it is :-) If I telnet into my server I can add a user by running the following command... /usr/sbin/cadduser -d www.domain.com -f users full name -u username -p password -w emailaddress for forwarding Which is great, but as I`m offering

Re: [PHP] Tough One

2001-03-29 Thread KPortsmout
In a message dated 29/03/2001 15:27:27 GMT Daylight Time, [EMAIL PROTECTED] writes: To get this done I would use an Expect script, driven through CGI. Mike Problem is I don`t program in CGI so have no idea what you mean :-) Ade -- PHP General Mailing List (http://www.php.net/) To

[PHP] Match em up

2001-03-29 Thread KPortsmout
Hi, I have two database`s with one table in each. (MySQL) Is there a way that I can select data from one table and then match it with the data in another and discard the results so all I am left with is the original data from the first table which never matched up. Database1

[PHP] Sessions Q.

2001-03-29 Thread KPortsmout
Hi, I currently have sessions working nicely on my site, but I want to add a timeout feature. What would be the best method, grabbing the server time and setting it using the session_register, and then running a time check so if the session time is more than one hour old destroy it?? Ade --

Re: [PHP] sessions broken when redirected?

2001-03-29 Thread KPortsmout
Hi Andrew, I`m not sure if switching from http to https will count as a *new* domain, but here is a link to some information which may solve your problem. http://phpbuilder.com/columns/chriskings20001128.php3 HTH Ade -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

Re: [PHP] php error code.

2001-03-29 Thread KPortsmout
In a message dated 29/03/2001 21:42:57 GMT Daylight Time, [EMAIL PROTECTED] writes: If you have permission to modify php.ini, see the setting "display_errors" and the attached comments. You can tell PHP to write these error messages to a log file instead of to the browser. Kirk If I

[PHP] Delete Problem

2001-03-30 Thread KPortsmout
Hi, Can anyone see a problem with this? ? $dbase="Failed_Signups"; // Connect to MySQL $Connect=mysql_connect("", "", ""); $www_domain="select Failed_Signups.EmailAddress.Email from Failed_Signups.EmailAddress left join www_domain_net.Members on

Re: [PHP] Delete Problem

2001-03-30 Thread KPortsmout
In a message dated 30/03/2001 17:59:52 GMT Daylight Time, [EMAIL PROTECTED] writes: Correct me if I am wrong, but I thought that using IN needed to be followed by a comma separated list (with each value individually separated from the others) like this: $query="DELETE FROM EmailAddress

Re: [PHP] Please Help!

2001-04-02 Thread KPortsmout
In a message dated 03/04/2001 03:52:47 GMT Daylight Time, [EMAIL PROTECTED] writes: include "class.FastTemplate.php"; Just for a start, I didn`t notice anything else in the code... include ("class.FastTemplate.php"); Ade -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

[PHP] Create Array??

2001-09-22 Thread KPortsmout
Hi, If I have a value $num = 32; based on this how can I create an Array of numbers 1 - 32, something like this... ? $num = 32; for ($i = 1; $i = $num; $i++) { // Do something } // And now $i = (1,2,3,etc ? Any suggestions?? I cannot use array_push as this has to work on a PHP3 server. TIA

Re: [PHP] Create Array?? More

2001-09-23 Thread KPortsmout
Ok, Thanks for the input, unfortunately it didn't help me solve my overall problem, so I will post that and see if anyone has any suggestions... I am basically displaying the Usernames from a .htpasswd file like this... $File=$Path$Directory1/.htpasswd; $fd = fopen ($File, r); $Content =

[PHP] exec() help

2001-11-21 Thread KPortsmout
Hi, I am running the following function in my PHP script: exec(/usr/local/bin/wget http://www.getresponse.com/cgi-bin/add.cgi?misc=1ref=001category1=trtipscat egory2=acategory3=.$Grab[2][$i].)or die (Error); It is run inside an if loop and $Grab[2][$i] contains an e-mail address. However it

[PHP] exec problem

2001-07-31 Thread KPortsmout
Hi I'm trying to create a script which my cron will run once a day to backup my MySQL database, but the exec command doesn't want to work no matter what I try... exec(mysqldump -h localhost -u user -p pass --opt DataBase BACKUPS/backup.mysql) or die(Problem); I have tried adding the full

[PHP] PHP vs CGI Search ?

2001-08-24 Thread KPortsmout
Hi, I know this question has been asked many times before so I am not asking again :-) What I am asking is how I can search the forum, is there a web based system that I can use to search??? TIA Ade -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED]

[PHP] PHP Article... Comments??

2001-08-29 Thread KPortsmout
Hi I had this article sent to me on another list I am subscribed to, just wondered what other people thought of it :-) http://www.securereality.com.au/studyinscarlet.txt Ade -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,

[PHP] Batch Coding Help Please

2001-06-25 Thread KPortsmout
Hi, I am building a custom e-mailer for one of my websites using PHP and MySQL, I know there are loads out there already but my goal here is to learn this coding myself so I can modify it to my needs as and when they change. My list only has around 5000 subscribers at the moment and I have

Re: [PHP] Batch Coding Help Please

2001-06-25 Thread KPortsmout
Hi, Unfortunately that won`t work for me because I don`t have access to setting up a Cronjob on this account, thanks for the suggestion though. Ade -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

[PHP] Time Help

2001-07-01 Thread KPortsmout
Hi, I`m trying to get the difference between two date/times and then state how many days, hours and minutes there are between them. So I take my date and convert it into unix time. Then get the current time, and then subtract the two to get the current difference in unix seconds. What I`m

Re: [PHP] Time Help

2001-07-01 Thread KPortsmout
Thanks Jeff, Thats just the job. Ade Here is the function I use when I am comparing differences ($now and $old are Unix timestamps): function datediff($now, $old) { $DIS = $now - $old; // Diff In Secs $secs = $DIS % 60; // modulo $DIS -= $secs; $days = floor($DIS /

Re: [PHP] online detection

2001-04-11 Thread KPortsmout
In a message dated 11/04/2001 12:58:11 GMT Daylight Time, [EMAIL PROTECTED] writes: Does anyone know how to detect when a user connects to the Internet similar to ICQ? Sure. Three main possibilities: (1) Install a wire tap at his telephone line, together with some logic to detect

[PHP] List Files

2001-04-19 Thread KPortsmout
Hi, Does anyone know how I can list all the files begining with help in one of my pages. So I have a dir which has various files, like so: help_me.php help_you.php help_us.php Is there some command I can use to select all the files and then print them out? TIA Ade -- PHP General Mailing

Re: [PHP] redirection

2001-04-21 Thread KPortsmout
In a message dated 21/04/2001 15:31:36 GMT Daylight Time, [EMAIL PROTECTED] writes: How to redirect to another page in php. Is there any inbuilt function available for redirection. If possible send with example. Thanks kishor Use the Header call,for more info see www.php.net and

Re: [PHP] OT-Please bare with me :)

2001-05-03 Thread KPortsmout
In a message dated 03/05/2001 18:07:18 GMT Daylight Time, [EMAIL PROTECTED] writes: Hello, I am making a suite of php tolls that I want to have all incorporated in one management website. What I would like to have is a drop down menu in a frame on the left. A great example of what I