[PHP] Page Rederection Problems

2003-03-13 Thread Kelly Protsko
Basically what I am doing is having a post call a page with the following code to email the form contents. I want the page to redirect back to the page it was sent from after the mail has been sent. The top mailing part works fine but when I put the header redirect in at the bottom I get an

RE: [PHP] php and mysql

2003-02-20 Thread Kelly Protsko
I'm not sure what you mean by cut the records at 1/4, if you mean only bringing back 1/4 of the rows you could use the LIMIT clause in your sql statement and give it a number of rows you want brought back. To sort alphabetically just use the order by command in SQL So your query would look

RE: [PHP] simple ereg question

2003-02-20 Thread Kelly Protsko
Did you try this syntax yet? The with the ^ and $search matching beginning and end I tested out the code myself and it worked fine. http://www.theoutersphere.com/testing/testnumbers.php //here is the exact code that I used echo $_POST[vari] .br; if (eregi('^[0-9]+$',$_POST[vari]) ||

RE: [PHP] string manipulation

2003-02-20 Thread Kelly Protsko
Use strrpos() which will find the last occurrence of something in a string then just use substr() to pull everything from that point on in the string. Kelly -Original Message- From: Gregory Heinrichs [mailto:[EMAIL PROTECTED]] Sent: February 20, 2003 5:13 PM To: [EMAIL PROTECTED]

RE: [PHP] file not opening in internet explorer

2003-02-19 Thread Kelly Protsko
You may also need world execute on the file before it will work. I've had this problem myself with certain files and they would only show up once I had world execute on them. rw-r-r-x IF you are looking for a good tutorial there is an awesome book PHP and MySQL web development by welling and

RE: [PHP] excluding same field values in mysql

2003-02-19 Thread Kelly Protsko
If you only want one email do a select distinct email that way only one email address will be brought back from you query. $query=mysql_query(select company, Email from members); $query = mysql_query(select company, distinct(Email) from members); if you want a good book for this check out MySQL

RE: [PHP] Simple ereg question

2003-02-19 Thread Kelly Protsko
You had it pretty close but try and make a few minor changes to it I've tested the function below and it works for what you are trying to do. I am not sure of a way to test for the null with eregi other than putting and or statement in. if (eregi('^[0-9]+$', $_POST[gamt_$i]) || $_POST[gamt_$i]

RE: [PHP] PHP fileperms

2003-02-18 Thread Kelly Protsko
Here is how the numbers work for file permissions. 644 = rw-r--r-- 0 --- no access 1 --x execute 2 -w- write 3 -wx write and execute 4 r-- read 5 r-x read and execute 6 rw- read and write 7 rwx read write execute -Original Message- From: DIKSHA NEEL [mailto:[EMAIL PROTECTED]]