[PHP-WIN] basic sessions...

2003-03-07 Thread Stephen Edmonds
> - Original Message - > From: "Radovan Radic" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Friday, March 07, 2003 2:40 PM > Subject: Re: [PHP-WIN] basic sessions... > > > > > > > > You need a session_start() on every page that needs to examine/update > > > $_SESSION[] ... > > > >

[PHP-WIN] Re: [PHP-INST] I get a "File Download" dialogue box

2003-02-10 Thread Stephen Edmonds
Copy of message sent out last time someone had a similar problem: Chances are you've not put the commands in the correct place, instead just copy and pasted them into the config file. LoadModule php4_module C:\PHP\sapi\php4apache.dll This has to be in the same place as all the other LoadModule co

[PHP-WIN] Re: [PHP-INST] php not executed, mime type problem? - Fixed :-)

2003-02-03 Thread Stephen Edmonds
RE: [PHP-INST] php not executed, mime type problem?Thats okay. I'm glad that it helped you out. I know how annoying it is getting these things working! Stephen - Original Message - From: Boutelle, Jonathan To: 'Stephen Edmonds' ; Zavier Sheran ; Boutelle, J

Re: [PHP-WIN] Multiple MySQL Queries

2003-02-01 Thread Stephen Edmonds
Not that I know of. Try taking a look in the php manual (http://www.php.net) for the MySQL Section. If you can find a method there, then use it. Otherwise I believe you are better off doing each query one by one. On another note, if you did do them all at the same time and something went wrong it m

Re: [PHP-WIN] error - permissions?

2003-02-01 Thread Stephen Edmonds
It probably means that your MySQL is not configured to allow for 'root' to login. If you have phpMyAdmin, you can use it to login to your MySQL server and set up the user. Stephen - Original Message - From: "Pat Johnston" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, Februar

Re: [PHP-WIN] Web pages don't show up in IE 6 w/SP1.

2003-01-31 Thread Stephen Edmonds
vel Design BF 1942 Basics". > When I click on that link all of the scrollable info isn't there. > > Thanks, > > Jammy > > > From: "Stephen Edmonds" <[EMAIL PROTECTED]> > To: "Jammy Hall" <[EMAIL PROTECTED]> > CC: "PHP Windo

Re: [PHP-WIN] Web pages don't show up in IE 6 w/SP1.

2003-01-30 Thread Stephen Edmonds
Well its not your browsers fault - PHP is all generate before being sent to the browser. Is PHP enabled on your webserver? Which server are you using? Did you remember to restart the server after installing php? And is your file end with .php? More infomation on your server/php page would be helpf

Re: [PHP-WIN] Is this possible

2003-01-28 Thread Stephen Edmonds
No, however... you could use include( "whatever.php" ); so that the form submits to one page, which then includes both pages and does whatever it is you need. Why you want to submit to two places is a mystery though... Stephen - Original Message - From: "Wade" <[EMAIL PROTECTED]> To: <

Re: [PHP-WIN] php-win2k error in apache as isapi module

2003-01-26 Thread Stephen Edmonds
Two things. Firstly, how are you running your source code? Secondly, when do you get the error? When you try to run the script or when you try to start Apache? - Original Message - From: "Vikas Pande" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, January 26, 2003 1:21 PM Subj

Re: [PHP-WIN] Moving an uploaded file keeps failing

2003-01-20 Thread Stephen Edmonds
Currently from what I can see there are a few problems: The Form: Send this file: action is not essential if the form is sending to itself (okay, maybe thats just me being lazy :p). However, you missed out a vital field This needs to appear just before the file upload input. It tells PHP

Re: [PHP-WIN] It just doesn't make sense!

2003-01-17 Thread Stephen Edmonds
Grr it just takes the biscuit. I found the problem in my menu system. Basically, I was trying to send on two ? rather than using an &. So incredibly annoying, yet so incredibly simple... ah well Stephen - Original Message - From: "Stephen Edmonds" <[EMAIL PROTECTED]&

[PHP-WIN] It just doesn't make sense!

2003-01-17 Thread Stephen Edmonds
I am currently re-writing part of my website to allow people who don't use cookies to still use the site features. However, I have run into a problem. I send the session ID from page to page via the query string, and retreve it using $_GET. Everything works fine, and if set I store the details in $

Re: [PHP-WIN] Getting IP Address and previous URL from user??

2003-01-12 Thread Stephen Edmonds
Sure. If you ever want to see what variables you can access and how they are stored, simply write a script with phpinfo(32); in. It outputs ALL variables which you can access from your script. In this case: Remote IP (Person who accessed the script) $_SERVER["REMOTE_ADDR"] File that was accessed (a

Re: [PHP-WIN] Which Web server to run under XP

2003-01-12 Thread Stephen Edmonds
Xitami is not a good choice for XP. I don't know why, but it has problems handling sessions properly, not to mention a few other bugs I ran into. I strongly suggest you use something like Apache, IIS (if you have XP professional, although IIS does suck quite badly lol), or even Abyss (http://www.ap

Re: [PHP-WIN] initialize variables (was: Using the GET Method)

2003-01-12 Thread Stephen Edmonds
- Original Message - From: "Bobo Wieland" <[EMAIL PROTECTED]> To: "Sean Malloy" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Sunday, January 12, 2003 2:59 PM Subject: [PHP-WIN] initialize variables (was: Using the GET Method) > Please, explain this to me, because I couldn't figure it o

Re: [PHP-WIN] [newbie] What does this mean?

2003-01-07 Thread Stephen Edmonds
Open up your httpd.conf file and search for: DocumentRoot You need to change the setting so it points to the same directory as where your webpage is stored. In my case, I store my files in 'C:/Documents and Settings/Stephen/My Documents/Web Pages/', so I setting the Document Root to: DocumentRoot

Re: [PHP-WIN] mail() function not working

2003-01-06 Thread Stephen Edmonds
To fix your mail server: You need to enable mail relaying on your mail server. HOWEVER, it is VERY VERY important that ONLY the IP address of 127.0.0.1 is allowed to relay mail. If any IP can use the mail relay service, then anyone can use your mail server to send out spam annomously. Once that is

Re: [PHP-WIN] PHP Editors

2003-01-06 Thread Stephen Edmonds
You can find a large list of many of the PHP editors at http://phpeditors.dancinghippo.com/ My personal favourite is Magnum Studio Light, its free and quite feature packed... but then again everyone likes their own brand. See http://www.maguma.com/products/studio/studio_overview.php for more detai

Re: [PHP-WIN] PHP 4.3.0 no gif support?

2003-01-05 Thread Stephen Edmonds
Due to the copyright laws, GD had to remove all gif support. I believe you can still open .gif files, but you can not edit/save them. You should try using something which is open license like a .png file... I am not awear of any gif section in phpinfo... i've yet to see one. I could be wrong, but

Re: [PHP-WIN] PHP from the Browser?

2003-01-05 Thread Stephen Edmonds
Actually now that I come to think about it, there is a 3rd option. I use a script editor called Magnum PHP Studio. It has a feature where it can run your script in PHP acting like the webserver. I am not sure if you can use it to submit forms etc etc, but it would provide a basic method for you to

Re: [PHP-WIN] PHP from the Browser?

2003-01-05 Thread Stephen Edmonds
Sorry, but he is right. Your browser can't be set to work with php unless you have a webserver like apache/Xitami/etc... Your two choices are to upload to your host and test, or to download a free webserver... Oh, btw, as for your code: PHP Test "; ?> You don't need that ; as the are on

Re: [PHP-WIN] running php with apache with different php.inis

2003-01-03 Thread Stephen Edmonds
No, you can only have one php.ini file used by php... HOWEVER it is possible to make changes to php.ini settings in the .htaccess files. Take a look at http://www.php.net/manual/en/function.ini-set.php, it contains infomation on the options that can be changed and where. How you make changes in .ht

Re: [PHP-WIN] iis5 php 4.2.3 multiple -c php.ini possible?

2002-12-23 Thread Stephen Edmonds
http://www.php.net/manual/en/function.ini-set.php Gives a list of all php.ini options, and where they can be set (Everywhere, Per Folder, php.ini only etc etc) Hope this proves helpful Stephen - Original Message - From: "Petar" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, D

Re: [PHP-WIN] general survey.... php.ini config gui

2002-12-22 Thread Stephen Edmonds
It sounds like a great idea, for the people who are newer to php. However, the 'old veteran's will probably not use it... - Original Message - From: "A Weaver" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, December 22, 2002 12:16 PM Subject: [PHP-WIN] general survey php.ini

Re: [PHP-WIN] Cookies working on test but not my application

2002-12-19 Thread Stephen Edmonds
nds from that date. I then put +3600 on the end, so it adds 3600 seconds, or 1 hour 60 seconds per minute 60 minutes per hour 60 * 60 3600 Hope this solves your problem Stephen - Original Message - From: "George Pitcher" <[EMAIL PROTECTED]> To: "Stephen Edmond

Re: [PHP-WIN] Cookies working on test but not my application

2002-12-17 Thread Stephen Edmonds
Frames are not the issue here, any page in a frame still gets the cookie providing it is in a domain for which the cookie is set. I suggest making a page with the following That will output ALL the variable data for your page. If your cookie has been sent back by the browser, then you should see

Re: [PHP-WIN] Warning messages

2002-12-16 Thread Stephen Edmonds
12/site154/web/guestbook_post.php on line 16 > > Warning: fwrite(): supplied argument is not a valid File-Handle resource in > /home/.sites/112/site154/web/guestbook_post.php on line 18 > > Warning: flock(): supplied argument is not a valid File-Handle resource in > /home/.sites/112/

Re: [PHP-WIN] Warning messages

2002-12-16 Thread Stephen Edmonds
That means you have an error in your use of fwrite its not a proper 'file pointer'. Its not a setting you can change in your php.ini, as it is cause by a problem with your script. In fact, your script should not work because of the error. If you paste the code and what your script does, I may

Re: [PHP-WIN] newbie question (forms)

2002-12-12 Thread Stephen Edmonds
Its just a warning. It tells you that you are using a variable which has no value. Just ignore the notice, or turn down error reporting to exclude notices. All it means is that the variable of $test which you have included in your script HAS NO VALUE. If you were to write something like $test = "I

Re: [PHP-WIN] mystery line

2002-12-06 Thread Stephen Edmonds
Only if you circle your computer 3 times and tap your heels together. Or was that tap your heels together 3 times, then circle your computer? One of the two... - Original Message - From: "Svensson, B.A.T. (HKG)" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]>; "PHP Windows Help List" <[EMAIL

Re: [PHP-WIN] hello there.

2002-12-06 Thread Stephen Edmonds
It's called 'Register Globals' Basically, rather than having $DOCUMENT_ROOT, all the preset variables are stored in 'Super arrays'. This means you will now have to use $_SERVER["DOCUMENT_ROOT"] For more information: http://www.php.net/manual/en/security.registerglobals.php Use phpinfo(32); to li

Re: [PHP-WIN] socket timeout

2002-12-05 Thread Stephen Edmonds
Take a look at http://www.php.net/manual/en/function.socket-set-timeout.php Quote: 'this function _does_not_ work on sockets which connect to a port you set up using the sockets-family of functions. it only seems to work for connections using fsock and fopen. (and functions which are derived from

Re: [PHP-WIN] trouble with update from php 3 to php 4.2.3

2002-12-04 Thread Stephen Edmonds
include takes the base directory to be the same directory the script is in. e.g. Running the file c:\my_web\Stephen\index.php include( "hello.php" ) this includes the file c:\my_web\Stephen\hello.php Hope this helps Stephen - Original Message - From: "Omar" <[EMAIL PROTECTED]> To: <[EMA

Re: [PHP-WIN] user system using sessions and cookies?

2002-12-04 Thread Stephen Edmonds
My guess is that the session ID is changing. Try adding the session ID to the end of the URL and see if the output matches. If not, you know where the problem lies. e.g. header( "Location: url/page.php?SessionIDViaQuery=".session_id() ); Okay, so its harder on your page as your login script is on

Re: [PHP-WIN] Redirect browser to another URL?

2002-11-28 Thread Stephen Edmonds
I see what you mean. I suggest making a separate page to process the form... such as formprocess.php. When the user is sent to the page, you can access all the variables using $_GET or $_POST arrays (depending on how your form is sent), add the new record, and then at the bottom send the user back

Re: [PHP-WIN] Who is on line?

2002-11-28 Thread Stephen Edmonds
I don't believe that is possible. The problem is with the way the internet works. You do not have a connection to your user while they are browsing your site, only when they request a page. Client -> Requests a Page -> Connection to server open Server -> Sends the page -> Connection closed... Thi

Re: [PHP-WIN] Who is on line?

2002-11-28 Thread Stephen Edmonds
You would have to store when a user visits a page into a database and have some sort of time limit on when you remove them, or remove them when they logout/visit another page type thing Basically... database interactions - Original Message - From: "mst" <[EMAIL PROTECTED]> To: <[EMAIL PRO

Re: [PHP-WIN] Redirect browser to another URL?

2002-11-28 Thread Stephen Edmonds
if ( $FormIsSent == "My-String ) { process form header( "Location: url" ); } else { display form } I use this technique on my sites all the time. The only restriction is you can't have any output before the header. If there is an error in the form, store it in an error variable: $error[NameForEr

Re: [PHP-WIN] parse error

2002-11-19 Thread Stephen Edmonds
*sighs* Very simple answer. else CAN NOT have arguments EG if ( x is true ) { do this } elseif ( y is true ) { do this } else { print "Y is not true, X is not true"; } (The code above is not real code, it is an example of how if, elseif and else work) Change your else( $submit ) to else You do

Re: [PHP-WIN] PHP variable

2002-11-19 Thread Stephen Edmonds
Its just a warning. It tells you that you are using a variable which has no value. Just ignore the notice, or turn down error reporting to exclude notices. All it means is that the variable of $test which you have included in your script HAS NO VALUE. If you were to write something lile $test = "I

Re: [PHP-WIN] php 4.2.3, gd2, freetype 2 and still a problem with truetype fonts

2002-11-18 Thread Stephen Edmonds
I have the same problem with GD2. In the end I gave up and went back to 1.3.somin (It comes with the php distibution). The older version works, but does uses a slightly different syntax and has not got the most advanced features of GD2 (Such as drawing a filled arc!) - Original Message - F

Re: [PHP-WIN] Variable problem

2002-11-18 Thread Stephen Edmonds
If you need to remove the space, use trim( $variable ). Trim() removes all white space/tabs etc from the end and start of a string. $Variable = " LOTS of white Space :-( "; trim( $Variable ); echo "*".$Variable."*"; displays *LOTS of white Space :-(* instead of * LOTS of white Space

Re: [PHP-WIN] set up mysql without winmysqladmin?

2002-11-15 Thread Stephen Edmonds
On my Windows XP System, I only ran WinMySQLAdmin once. Now whenever my PC loads, MySQL comes online with it. I suggest you try closing WinMySQLAdmin, restarting, then seeing if you can access the database Stephen - Original Message - From: "A. J. McLean" <[EMAIL PROTECTED]> To: <[EMAIL P

[PHP-WIN] Serious Problem - Server Crashing

2002-11-11 Thread Stephen Edmonds
In the end I decided to do a full re-install of the server, php AND mysql. Everything seems to be working fine now. My guess is that the first crash was caused by a server overload or something, which then damaged my php installation. Why it worked fine over my network but not over the internet is

[PHP-WIN] Serious Problem - Server Crashing

2002-11-10 Thread Stephen Edmonds
OS Windows XP Profession (With Service Pack 1, fully up to date) Running - Abyss 1X - PHP 4.2.3 - MySQL 3.23.53-max-nt The Problem On startup, the computer loads fine. The webserver can be connected to via http://scryt.no-ip.com and the site works fine. Access from any PC on and off the network w

[PHP-WIN] Print or Echo?

2002-11-09 Thread Stephen Edmonds
This is not strictly a help question, but more of a do you question. Simply, do you use print, or do you use echo? Personally, I use print. I like the way its set out, and find it easier to understand code. But then again, that was just the way i learnt php. What do you think? Stephen -- PH

Re: [PHP-WIN] 2 Issues for Mail() in Win/PHP4-

2002-11-02 Thread Stephen Edmonds
well for a start I suggest spaces... makes a code easier to understand $subject = "Need Help"; I am not sure if that actually affects the variable... anyway mail($Email_To, $Email_Subject, $Email_Message, "From: [EMAIL PROTECTED]\r\n" ."Reply-To: [EMAIL PROTECTED

Re: [PHP-WIN] Date Increment Problem

2002-10-31 Thread Stephen Edmonds
60 seconds in an minute 60 minutes in an hour 24 hours in a day 3 days needed therefor: 60 * 60 * 24 * 3 Its worth noting there are 3600 seconds in 1 hour... so you could use 3600 * 24 * 3 - Original Message - From: "Constantin Baciu" <[EMAIL PROTECTED]> To: "Ste

Re: [PHP-WIN] Date Increment Problem

2002-10-30 Thread Stephen Edmonds
Firstly, you need to understand time. Time in computers is stored as the number of seconds since January 1st, 1970. The time now is 1035999078 (Or to humans, 17:31:30 on the 30th Oct). When you call the current time with time() it returns that long number above. You can then add on 1 days worth of

Re: [PHP-WIN] Random Numbers Script

2002-10-29 Thread Stephen Edmonds
Generating random numbers is quite easy in php. I suggest using rand( ). Simply put your upper limits and lower limits in, then it randomly chooses a number inbetween. EG: rand( 1, 9 ) generates a random number between 1 and 9. If you want to be able to control the length, then use rand however ma

Re: [PHP-WIN] configuraton of mail server with PHP/Apache

2002-10-29 Thread Stephen Edmonds
Can you also write the error message? It could be you need to turn on your Mail Server's email redirection - the feature that allows it to send email on to another system EG: My local email server gives me an address of [EMAIL PROTECTED] Trying to send mail to it using php always works, as it is a

Re: [PHP-WIN] spam protection boxes

2002-10-28 Thread Stephen Edmonds
I suggest using GD to generate the images in PHP then output them to a browser. http://www.php.net/manual/en/ref.image.php I use GD 1, as I have had issues loading fonts into GD 2 Good luck Stephen - Original Message - From: "Dash McElroy" <[EMAIL PROTECTED]> To: "Svensson, B.A.T. (HKG

[PHP-WIN] GD2 and PHP

2002-10-28 Thread Stephen Edmonds
Yesterday I decided to switch my GD library from gd.dll to gd2.dll... big mistake Now, when I try to create text using imageTTFtext( ), I get the error message of Warning: Could not find/open font in C:\server\scryt_pages\members\interface\buttons\base.php on line 53 I've tried the suggestions

Re: [PHP-WIN] PHP and Apache 2

2002-10-26 Thread Stephen Edmonds
Aparently, there are some major issues with it, but someone got it working. >From the PHP installation help mail list: Quote Starts Hey, get this.. I have a fully functional Apache 2.0.43 and PHP 4.2.3 running on Win2k. But you are right

[PHP-WIN] Php Sessions - Well, they don't work :-\

2002-10-14 Thread Stephen Edmonds
The problem is my sessions don't work properly... the ID is stored and saved in the cookie fine, and the PHP script can even acces the Session ID value in the cookie. However, when you call session_start(); it mearly creates a new session/session ID instead of resuming. I can pass on the session i