Re: [PHP] Similar functions?

2003-11-19 Thread RT
I'm not sure if this is what you're looking for but if it is it will be much easier the regex's http://ca.php.net/manual/en/ref.ctype.php The functions here look to see if variables are alpha, numeric, or alpha/numeric and some other stuff. On Thu, 2003-11-20 at 01:24, Jake McHenry wrote: > Can

[PHP] SESSION wierdness....

2003-11-19 Thread David HM Spector
I'm seeing really odd behavior using session variables and wonder if I'm really just missing something obvious... My env is: RH9, httpd-2.0.40-21.5, PHP 4.2.2 (RH RPM, gazillion compile flags enabled), session support enabled, register_globals is ON I am writing a multi-page form, on the fir

RE: [PHP] Similar functions?

2003-11-19 Thread Jake McHenry
> -Original Message- > From: Bob Eldred [mailto:[EMAIL PROTECTED] > Sent: Thursday, November 20, 2003 1:21 AM > To: Jake McHenry > Subject: Re: [PHP] Similar functions? > > > Wouldn't is_numeric work? > > - Original Message - > From: "Jake McHenry" <[EMAIL PROTECTED]> > To: <[E

Re: [PHP] Similar functions?

2003-11-19 Thread Robert Cummings
On Thu, 2003-11-20 at 01:24, Jake McHenry wrote: > Can anyone tell me if there are similar functions in php as javascript > isNaN, or do I just have to do a http://www.php.net/manual/en/function.is-numeric.php Cheers, Rob. -- .. | Inter

[PHP] Similar functions?

2003-11-19 Thread Jake McHenry
Can anyone tell me if there are similar functions in php as javascript isNaN, or do I just have to do a if (preg_match('/([EMAIL PROTECTED]&*()_=+|\?/><,.;:{}-])/', $_POST['Personal_Hotel_CC_Number']) == 0){} I know the above doesn't work, would there be an easier way for me to find if any of th

RE: [PHP] tax functions

2003-11-19 Thread Chris Hubbard
Sara, You're on the right track. You've created your functions, but they need some work before they can be used. Starting with getTax() you've got a naming convention conflict, while not necessarily a problem, it's bad style. Instead of $item as the parameter for the function, use something like

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-19 Thread Anthony Ritter
Additinally, upon looking at the session files in: C:/apache/tmp: I get from session file from script session_1a.php: products|s:23:"a:1:{i:0;s:6:"Tardis";}"; ... However, looking at session file from script session_1.php: I get: products|s:2:"N;"; -- "Anthony Ritter" <[EMA

Re: [PHP] Re: file_exists on Windows problem

2003-11-19 Thread Jason Wong
On Thursday 20 November 2003 13:05, Chris Williams wrote: > Thanks, but it make the test to move on to other things like, > size($filename) which tells me the file does not exist. print_r($_FILES) -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators *

[PHP] tax functions

2003-11-19 Thread Sara Daugherty
Hello, I am new to php. I am trying to learn functions. Can someone look at my code and tell me if I am on the right track or if I am doing something wrong? Here is the link where my script can be found: http://www.areawebdirectory.net/taxfunction.txt Thanks, Sara D. -- PHP General Mailing List (

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-19 Thread Anthony Ritter
Sure. Here it is. There are three scripts. session_1.php: the original form script. session_1a.php: a revised script with a conditional else. session_2.php: the receiving script for the session array variable. Running script 1a and 2 works fine. However the original script 1 and 2 gives me a e

[PHP] date question

2003-11-19 Thread Martin Cameron
$ndays=14; function get_next_dates($ndays) { $today=date("m-d-Y",mktime(0,0,0,date("m"),date("d"),date("Y"))); $forward_date=date("m-d-Y",mktime(0,0,0,date("m"),date("d")+$few_days,date("Y"))); print "$today === $few_days === $forward_date"; for($i=0;$i<$ndays;$i++) { $new_days_array[]=date(

Re: [PHP] R: [PHP] mailing multilple addresses...?

2003-11-19 Thread Ryan A
Hey, Pretty good program, i might use it myself after a few modifications. Much better than the old emails.. eg: "Tristan pretty is out of the office.." :-D Cheers, -Ryan http://Bestwebhosters.com - Original Message - From: <[EMAIL PROTECTED]> To: "Alessandro Vitale" <[EMAIL PR

Re: [PHP] retrieving ENUM description from MySQL

2003-11-19 Thread John W. Holmes
Alan Lord wrote: Imagine a database table, field defined as ENUM with a list of allowed types such as "Mr", "Mrs", "Miss", "Dr", "Prof", etc - you get the idea. I've read the MySQL manual and by using SHOW COLUMNS FROM "table_name" LIKE "enum_column_name"; I can get a result. But the string of

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-19 Thread John W. Holmes
Anthony Ritter wrote: Thanks again but here's what happens when I run that. The form box appears. I select an option. I hit submit. The page that loads says: Warning: Invalid argument supplied for foreach() in c:\apache\htdocs\session_yyy.php on line 13 I then hit the link: Back to content page. T

[PHP] Re: file_exists on Windows problem

2003-11-19 Thread Chris Williams
Thanks, but it make the test to move on to other things like, size($filename) which tells me the file does not exist. Chris "Manuel VáZquez Acosta" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > It may be an OS feature file_exists relies on... > But you can use is_uploaded_file() fu

Re: Re[2]: [PHP] Creating a line break between letter groupings

2003-11-19 Thread Doug Parker
Worked great. Thanks!! "Tom Rogers" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi, > > Thursday, November 20, 2003, 11:12:55 AM, you wrote: > TR> Hi, > > TR> Keep track of the first letter and if it changes echo a > > TR> $key = '' > > TR> //loop through results > > TR> while

[PHP] Re: IE 6 mangling posted code

2003-11-19 Thread Manuel Vázquez Acosta
It seems to me a problem with the ' signs. I have posted, stored, and retrieved html in many projects, using IE6, and every time an error like this one showed up, the causes happened to be one of these: magic_quotes of PHP were not taken into account in the PHP code. strings delimiters ('

Re: [PHP] how can i use sessions with frames

2003-11-19 Thread Marek Kilimajer
phptom wrote: Hi folks, I want to use a frameset with two frames, one leftFrame and one rightFrame. sometimes i need to change both frames at the syame time. Frames should not make muh problems the loginpage is a single frame window. How do i have to write my php code to prevent all these

[PHP] Re: file_exists on Windows problem

2003-11-19 Thread Manuel Vázquez Acosta
It may be an OS feature file_exists relies on... But you can use is_uploaded_file() function to check whether the file exists or not. Manu. "Chris Williams" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I'm again trying to understand differences in Apache and Windows installs of

[PHP] Re: how can i use sessions with frames

2003-11-19 Thread Manuel Vázquez Acosta
You can use a query technique: if (!session_registered(..)) session_start(); Or you can use the @ sign: @session_start(); Manu. "Phptom" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi folks, > > I want to use a frameset with two frames, one leftFrame and one

Re[2]: [PHP] Creating a line break between letter groupings

2003-11-19 Thread Tom Rogers
Hi, Thursday, November 20, 2003, 11:12:55 AM, you wrote: TR> Hi, TR> Keep track of the first letter and if it changes echo a TR> $key = '' TR> //loop through results TR> while($result = mysql..){ TR> $char = strtoupper(substr($row['name'],0,1)); TR> if(empty($key){ TR> $key = $ch

Re: [PHP] Creating a line break between letter groupings

2003-11-19 Thread Tom Rogers
Hi, Thursday, November 20, 2003, 11:03:22 AM, you wrote: DP> I'm reading a list of stores from a database and ordering them DP> alphabetically. How would I place a line break in between each letter DP> grouping? For example, DP> Applebee's DP> Aaron's Place DP> Aardvark Store DP> Bumblebee's

Re: [PHP] Installing Turck MMcache on win

2003-11-19 Thread Curt Zirzow
* Thus wrote Veress Berci ([EMAIL PROTECTED]): > Hello! > > But when I run mmcache.php, it says that it's not installed. > Then i've noticed that I have a php.ini in my winnt folder too (I think > that's because i've installed "PHPTriad" first and then PHP 4.3.4). > So I've updated it too but stil

[PHP] Creating a line break between letter groupings

2003-11-19 Thread Doug Parker
I'm reading a list of stores from a database and ordering them alphabetically. How would I place a line break in between each letter grouping? For example, Applebee's Aaron's Place Aardvark Store Bumblebee's Bears R' Us Big Bad Johnny's Caterpillar central Coffee time!! etc.- with the line

[PHP] Installing Turck MMcache on win

2003-11-19 Thread Veress Berci
Hello! I've downloaded "turck-mmcache-2.4.6-win32-php-4.3.4.zip". I'm running PHP 4.3.4 (InstallShield version) on Apache 1.3.23. The default setting for PHP was to run as CGI - but Turck readme said, it needs to be mod. OK, i've set httpd.conf. I've copied mmcache things into php.ini (c:\apache\p

Re: [PHP] mail -f option for removing nobody@localhost Return-Path

2003-11-19 Thread Curt Zirzow
* Thus wrote Glenn Gasner ([EMAIL PROTECTED]): > Here is the code I'm using trying to replace [EMAIL PROTECTED] with my email > address when I use the PHP mail() function to send a message: > > $headers="From: Glenn Gasner <[EMAIL PROTECTED]>\r\n" > ."Reply-To: Glenn Gasner <[EMAIL PROTECTED]>\r\n

Re: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Curt Zirzow
Scott, Please dont post 500+ lines of stuff to the list. You only needed to post the relevent code relevent to the subject at hand. * Thus wrote Scott Fletcher ([EMAIL PROTECTED]): > > for ($i=1;$i > { > > if (substr($res_str, $i, 9) == "

[PHP] file_exists on Windows problem

2003-11-19 Thread Chris Williams
I'm again trying to understand differences in Apache and Windows installs of PHP when I try to upload a file to the server. It seems on Windows, I can't get the file I'm uploading. To try to understand this I created a very simple html form that uploads a text file to the server's TEMP directory u

Re: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Eugene Lee
On Wed, Nov 19, 2003 at 04:54:39PM -0500, Scott Fletcher wrote: : : "Ray" <[EMAIL PROTECTED]> wrote: : > try : > $res_str_len = strlen($res_str); : > for ($i=1;$i<$res_str_len;++$i) : > : > one less function call in the loop and the prefix version of ++ is : > sometimes a tad faster then the postf

[PHP] Re: mail -f option for removing nobody@localhost Return-Path

2003-11-19 Thread Manuel Lemos
Hello, On 11/19/2003 08:09 PM, Glenn Gasner wrote: Here is the code I'm using trying to replace [EMAIL PROTECTED] with my email address when I use the PHP mail() function to send a message: $headers="From: Glenn Gasner <[EMAIL PROTECTED]>\r\n" ."Reply-To: Glenn Gasner <[EMAIL PROTECTED]>\r\n" ."Re

[PHP] Re: HTML email problem

2003-11-19 Thread Manuel Lemos
Hello, On 11/19/2003 12:54 PM, Binay wrote: I m sendig out HTML email, using mimemail class which encodes the whole message to be sent in base64 and Content-Transfer-Encoding: is also specified as base64 only. Now one of my client is complaining that he is getting garbage in the email (shown belo

[PHP] Re: HTTP Authentication thru PHP

2003-11-19 Thread Manuel Lemos
Hello, On 11/19/2003 12:30 PM, Chandu Nannapaneni wrote: hello all , I'm able to get successfully http authenticated from my php scripts Ex : $header = "POST /myscript.php HTTP/1.0\r\nAuthorization: Basic "; $header .= base64_encode("$username:$password")."\r\n"; $header .= "Content-

RE: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Chris W. Parker
Scott Fletcher on Wednesday, November 19, 2003 1:12 PM said: > function CBC_XML_BreakUp(&$strResponse_XML, &$strResponse_HTML) > > { [snip] Wow I didn't think you were going to post your whole program. :0 1. Are you sure the for() loop is the slow part? 2. As so

[PHP] Re: PHP Mail handler?

2003-11-19 Thread Manuel Lemos
Hello, On 11/19/2003 11:55 AM, Jacques Roux wrote: Is there a mail function or object that I can use on my PHP sites that does the same as the CDONTS object in ASP? Where can I find some tutorials on this subject? You may want to try this class to do what CDONTS does and more: http://www.phpclas

RE: [PHP] HTML email problem

2003-11-19 Thread Martin Towell
When I send HTML emails, I don't base64 encode it, I just set the content-type to text/html. The mail clients that I've tested it with renders it correctly HTH Martin > I m sendig out HTML email, using mimemail class which encodes > the whole message to be sent in base64 and > Content-Transfer-

[PHP] how can i use sessions with frames

2003-11-19 Thread phptom
Hi folks, I want to use a frameset with two frames, one leftFrame and one rightFrame. sometimes i need to change both frames at the syame time. the loginpage is a single frame window. How do i have to write my php code to prevent all these session errors. session already startet in .

RE: [PHP] date question

2003-11-19 Thread Daniel Purdy
Hello all, I would like to create a php function as follows: function get_next_dates($ndays) { /* 1. get the current date 2. create an array say $results 3. Store the dates for the next $ndays in $results */ return $results } So in my main program I can include th

[PHP] date question

2003-11-19 Thread Ahbaid Gaffoor
Hello all, I would like to create a php function as follows: function get_next_dates($ndays) { /* 1. get the current date 2. create an array say $results 3. Store the dates for the next $ndays in $results */ return $results } So in my main program I can include the file with

[PHP] Announcement: Smarty template engine 2.6.0 released

2003-11-19 Thread Monte Ohrt
Hello! 2.6.0 has been released. There are numerous enhancements and fixes, take a look at the release notes for the details. Have fun! -Monte Homepage: http://smarty.php.net/ Release Notes: http://smarty.php.net/release_notes.php ChangeLog: http://smarty.php.net/misc/NEWS Download: http:/

[PHP] IE 6 mangling posted code

2003-11-19 Thread Pablo Gosse
Hi all. I'm not sure if this is a browser issue, or a php issue, but while I'm leaning more towards the side of browser I'm not really certain and I'm interested to see if anyone has had problems similar to this. I've got a form by which html code is being submitted to a database. When I submit t

[PHP] mail -f option for removing nobody@localhost Return-Path

2003-11-19 Thread Glenn Gasner
Here is the code I'm using trying to replace [EMAIL PROTECTED] with my email address when I use the PHP mail() function to send a message: $headers="From: Glenn Gasner <[EMAIL PROTECTED]>\r\n" ."Reply-To: Glenn Gasner <[EMAIL PROTECTED]>\r\n" ."Return-Path: Glenn Gasner <[EMAIL PROTECTED]>"; mail(

Re: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Scott Fletcher
Sample code is found in earlier posting... Someone post a reply on a seperate thread... Scott "Eugene Lee" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On Wed, Nov 19, 2003 at 03:10:39PM -0500, Scott Fletcher wrote: > : > : Why does the for() loop for PHP so slow when it is

Re: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Scott Fletcher
That's a great idea! Recently changed the code and the postfix of ++ to prefix of ++. Still about the same... What so odd about this script is that I wrote it in Visual Basic for one of the application. It took only a few seconds for a PC workstation (Pentium 3 - Windows 2000). So, converting

Re: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Ray
try $res_str_len = strlen($res_str); for ($i=1;$i<$res_str_len;++$i) one less function call in the loop and the prefix version of ++ is sometimes a tad faster then the postfix version. On Wednesday 19 November 2003 15:11, you wrote: > function CBC_XML_BreakUp(&$strResponse_XML, &$strResponse_HTM

Re: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Eugene Lee
On Wed, Nov 19, 2003 at 03:10:39PM -0500, Scott Fletcher wrote: : : Why does the for() loop for PHP so slow when it is digesting a large : amount of data? Is there a way to make the loop go faster? Maybe it's your for() loop that's constructed in a less optimal way. Some source code would he

Re: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Scott Fletcher
function CBC_XML_BreakUp(&$strResponse_XML, &$strResponse_HTML) { global $res_str; $XML_Start = "Null!"; $XML_End = "Null!"; $HTML_Start = "Null!"; $HTML_End = "Null!"; //This loop work only for [XML[XML[HTML]]], not [XML[XML][HTML]]... //If the 'Options' variable in the Query URL string is

Re: [PHP] how to create a function and return two parameters????

2003-11-19 Thread Scott Fletcher
Ummm, look like I'll stick with number two. Didn't know about the "&" value to pass value back and forth in PHP Thanks, Scott F. "Chris W. Parker" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Scott Fletcher on Wednesday, November 19, 2003 12:07

Re: [PHP] String matching for sample code doesn't work....

2003-11-19 Thread Curt Zirzow
* Thus wrote Scott Fletcher ([EMAIL PROTECTED]): > Hi Everyone! > > --snip-- >$res_str = "Whoof"; > >for ($i=0;$i<100;$i++) >{ > if (substr($res_str, $i, 9) == "

Re: [PHP] PHP syntax error or javascript mistake?

2003-11-19 Thread Marek Kilimajer
Kenn Murrah wrote: I'm trying to open a new window on top of the current window, and it does that, but the "original" (bottom) window changes to read "Object Window" ... I can get back to the original with the "Back" button but of course don't want to ask that of the user ... I simply want a new

RE: [PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Chris W. Parker
Scott Fletcher on Wednesday, November 19, 2003 12:11 PM said: > Why does the for() loop for PHP so slow when it is digesting a > large amount of data? Is there a way to make the loop go faster? Show us your loop. -- Don't like reformatting your Outlook replies

RE: [PHP] how to create a function and return two parameters????

2003-11-19 Thread Chris W. Parker
Scott Fletcher on Wednesday, November 19, 2003 12:07 PM said: > I wanted to know how do I return two parameters within a > function. I'm not having much luck with it. I kept getting errors... [snip] >return $strResponse_XML,$strResponse_HTML; That's becaus

[PHP] Why is the php loop, 'for()', so slow????

2003-11-19 Thread Scott Fletcher
Hi Everyone! Why does the for() loop for PHP so slow when it is digesting a large amount of data? Is there a way to make the loop go faster? Thanks, Scott -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] how to create a function and return two parameters????

2003-11-19 Thread Scott Fletcher
Hi Everyone! I wanted to know how do I return two parameters within a function. I'm not having much luck with it. I kept getting errors... --snip-- function CBC_XML_BreakUp($strResponse_XML, $strResponse_HTML) { global $res_str; $strResponse_XML = substr($res_str, 0, 100); $strRes

RE: [PHP] Question about video (PHP unrealted)

2003-11-19 Thread Chris W. Parker
Frank Tudor on Wednesday, November 19, 2003 11:26 AM said: > I know this is bad but this is the only listserver/newgroup > thingy I use because I am php challenged. Actually you have (nearly) the entire internet at your beck and call. Me: "Frank, google. Google, Fr

Re: [PHP] Comparing 2 strings.

2003-11-19 Thread Ed Curtis
I guess I did miss that it says that the comparison is case sensitive and binary safe. Thanks, Ed On Wed, 19 Nov 2003, CPT John W. Holmes wrote: > From: "Ed Curtis" <[EMAIL PROTECTED]> > > > I currently store text from a MySQL blob field in a string $orig_text. I > > need to compare that wi

[PHP] Question about video (PHP unrealted)

2003-11-19 Thread Frank Tudor
I know this is bad but this is the only listserver/newgroup thingy I use because I am php challenged. Any how, I want to embed windows media player in my php pages (which I have done successfully), but I need help: I was wondering which is the best format for demand downloading of video files (no

Re: [PHP] Comparing 2 strings.

2003-11-19 Thread CPT John W. Holmes
From: "Ed Curtis" <[EMAIL PROTECTED]> > I currently store text from a MySQL blob field in a string $orig_text. I > need to compare that with something someone type in from a form stored in > $new_text. How would I go about comparing them to see if they are > different or exactly the same? strcmp

[PHP] PHP syntax error or javascript mistake?

2003-11-19 Thread Kenn Murrah
Greetings: I can't decide if my problem is PHP or Javascript, but I've been staring at this line of code for too long without being able to see why it's behaving the way it is I'm trying to open a new window on top of the current window, and it does that, but the "original" (bottom) windo

[PHP] Comparing 2 strings.

2003-11-19 Thread Ed Curtis
I currently store text from a MySQL blob field in a string $orig_text. I need to compare that with something someone type in from a form stored in $new_text. How would I go about comparing them to see if they are different or exactly the same? strcmp doesn't look like it will handle this too well

[PHP] php and java

2003-11-19 Thread Edward Peloke
Ok, First, let me say, I have looked at the manual and searched the past posts but still can't get this to work. I also should say that this is my first time trying to bridge php and java so this may be a stupid questionI have a java class(DateUtil) in a package (testphp). I then took the pa

[PHP] Re: String matching for sample code doesn't work....

2003-11-19 Thread Scott Fletcher
Never mind that! It work now Been working on it for a few hours though "Scott Fletcher" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi Everyone! > > I'm not really sure why does this simple script not work. When I run > the code, the loop kept going until it timed

RE: [PHP] stepping through alphabet

2003-11-19 Thread Don Read
On 19-Nov-2003 Steve Buehler wrote: > > Amazing what I learned today. :) I love this list and its people. > How about one more? (ver 4.1.0): foreach(range('A', 'Z') as $letter) { echo $letter, "\n"; } Regards, -- Don Read [EMAIL PROTECTED] -- It's alw

Re: [PHP] Counting elements in an array

2003-11-19 Thread John Nichel
Jeff McKeon wrote: How would I count the number of elements in an array that had a certain value? In other words, if I have $fruit = array(orange,orange,apple,bananna,orange,apple,pear); How could I get the number of elements from $fruit where the value is "orange"? Thanks, Jeff $temp = array_

[PHP] Re: About iMail Help

2003-11-19 Thread Scott Fletcher
It look like a email software called, 'imail' "D. Jame" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Hi, Anyone know about imail.? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] String matching for sample code doesn't work....

2003-11-19 Thread Scott Fletcher
Hi Everyone! I'm not really sure why does this simple script not work. When I run the code, the loop kept going until it timed out. I'll enclose the simple code here... --snip-- $res_str = "Whoof"; for ($i=0;$i<100;$i++) { if (substr($res_str, $i, 9) == "

Re: [PHP] Memory Size Help Please

2003-11-19 Thread Nick Wilson
* and then Raditha Dissanayake declared > Hi, > > Jay's comment was a fair one. It's not always possible to help without > full info. I beg to differ, the point was valid but the manner unfriendly at best. > You could try writing your data directly to disk instead of keeping them > in me

Re: [PHP] Memory Size Help Please

2003-11-19 Thread Raditha Dissanayake
Hi, Jay's comment was a fair one. It's not always possible to help without full info. You could try writing your data directly to disk instead of keeping them in memory as your code seems to be doing. In that case your regex function might need to go into the character data handler. Nick Wils

Re: [PHP] mailing multilple addresses...?

2003-11-19 Thread Tristan . Pretty
It should be off...! I went away for two weeks recently, and left my subscription runing ot he list... sorry... I'll be more careful... It's been a funny few weeks... ;-) Tris... Marek Kilimajer <[EMAIL PROTECTED]> 19/11/2003 17:17 To [EMAIL PROTECTED] cc [EMAIL PROTECTED] Subject Re: [PH

Re: [PHP] mailing multilple addresses...?

2003-11-19 Thread Marek Kilimajer
[EMAIL PROTECTED] wrote: Not a problem... I do try and be thorough when I create mails... I'll be more list friendly in the future... cheers for the heads up! Nw, if I can only solve my prob, I can go home ;-) When you go home, don't forget to turn on your out of office autoreply, everyone love

Re: [PHP] Memory Size Help Please

2003-11-19 Thread Nick Wilson
* and then Jay Blanchard declared > Nope, not enough info to spot the problem. I could point you in a Spare me the sarcasm. Here's the code if anyone can help, thanks. http://www.weblogs.com/changes.xml'); $xml=implode("\n", $xml); // Pattern match string $urlpattern = '/((http|https|ftp):

Re: [PHP] Memory Size Help Please

2003-11-19 Thread Raditha Dissanayake
hi How about using fopen() and reading line by line. And for xml parsing if you are using DOM switch to SAX that will always help. Nick Wilson wrote: Hi all, Can anyone spot the problem here and point me in the right direction? I have a script that goes and fetches the xml at weblogs.com (ht

[PHP] retrieving ENUM description from MySQL

2003-11-19 Thread Alan Lord
Hi all, This is a bit wierd so don't flame please. Imagine a database table, field defined as ENUM with a list of allowed types such as "Mr", "Mrs", "Miss", "Dr", "Prof", etc - you get the idea. I've read the MySQL manual and by using SHOW COLUMNS FROM "table_name" LIKE "enum_column_name"; I c

RE: [PHP] Memory Size Help Please

2003-11-19 Thread Jay Blanchard
[snip] Can anyone spot the problem here and point me in the right direction? [/snip] Nope, not enough info to spot the problem. I could point you in a direction, but that wouldn't help I am afraid. Wait, hold that thought, I have a direction to point you in. Please provide us with relevant detail,

Re: [PHP] R: [PHP] mailing multilple addresses...?

2003-11-19 Thread Tristan . Pretty
Cheers to everyone, it works great! Easy when I look at it now, but ant it the way... I'm off to the pub now.. later... Tris... "Alessandro Vitale" <[EMAIL PROTECTED]> 19/11/2003 16:50 To <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]> cc Subject [PHP] R: [PHP] mailing multilple addresses...?

[PHP] Memory Size Help Please

2003-11-19 Thread Nick Wilson
Hi all, Can anyone spot the problem here and point me in the right direction? I have a script that goes and fetches the xml at weblogs.com (http://www.weblogs.com/changes.xml). It then extracts the urls of the updated blogs and goes and uses file() to read each of them and extract some more stu

[PHP] R: [PHP] mailing multilple addresses...?

2003-11-19 Thread Alessandro Vitale
try this: if ($action == 'send') { $fimail = explode(",", $list); $count = count($fimail); $show = "Users that have been mailed:"; $i = 1; while ($count > $i) { mail($fimail[$i], "Subject", $message, $headers); $show .= "$fimail"; $i++; }

Re: [PHP] mailing multilple addresses...?

2003-11-19 Thread Tristan . Pretty
Not a problem... I do try and be thorough when I create mails... I'll be more list friendly in the future... cheers for the heads up! Nw, if I can only solve my prob, I can go home ;-) Jason Wong <[EMAIL PROTECTED]> 19/11/2003 16:42 Please respond to [EMAIL PROTECTED] To [EMAIL PROTECTED]

RE: [PHP] Counting elements in an array

2003-11-19 Thread Jay Blanchard
[snip] >> $fruit = array(orange,orange,apple,bananna,orange,apple,pear); >> >> How could I get the number of elements from $fruit where the value is >> "orange"? [/snip] >From http://www.php.net/array_keys with additions; $array = array("blue", "red", "green", "blue", "blue"); $countArray = coun

Re: [PHP] mailing multilple addresses...?

2003-11-19 Thread Jason Wong
You have started a new thread by taking an existing posting and replying to it while you changed the subject. That is bad, because it breaks threading. Whenever you reply to a message, your mail client generates a "References:" header that tells all recipients which posting(s) your posting refers

RE: [PHP] mailing multilple addresses...?

2003-11-19 Thread Jay Blanchard
[snip] if ($action == 'send') { $fimail[] = explode(",", $list); $count = count($fimail[]); $show = "Users that have been mailed:"; $i = 1; while ($count > $i) { mail($fimail[], "Subject", $message, $headers); $show .= "$fimail"; $i++; } }

Re: [PHP] Counting elements in an array

2003-11-19 Thread Jason Wong
On Thursday 20 November 2003 00:33, Jeff McKeon wrote: > Jason Wong wrote: > > On Wednesday 19 November 2003 23:24, Jeff McKeon wrote: > >> How would I count the number of elements in an array that had a > >> certain value? > >> > >> In other words, if I have > >> > >> $fruit = array(orange,orange,

RE: [PHP] Counting elements in an array

2003-11-19 Thread Jeff McKeon
Jason Wong wrote: > On Wednesday 19 November 2003 23:24, Jeff McKeon wrote: >> How would I count the number of elements in an array that had a >> certain value? >> >> In other words, if I have >> >> $fruit = array(orange,orange,apple,bananna,orange,apple,pear); >> >> How could I get the number

[PHP] mailing multilple addresses...?

2003-11-19 Thread Tristan . Pretty
Below is some code, I've written, where I'm trying to do the following... 1. Display a text box, for a user to enter a number of email addresses, seperated by a comma. 2. take that value, split it based on the comma and place that vlaue into an array. 3. Count the No of elements in the array 4.

RE: [PHP] stepping through alphabet

2003-11-19 Thread Jay Blanchard
[snip] OK, my bad -- I let my fingers do the talking without proper monitoring from my brain. This is what I actually use in more than a few scripts: for ($c='A'; $c!='AA'; $c++): echo $c; endfor; I just forgot to change the comparison from <= to != I guess this

RE: [PHP] stepping through alphabet

2003-11-19 Thread Ford, Mike [LSS]
On 19 November 2003 16:15, Jay Blanchard contributed these pearls of wisdom: > [snip] > 'Z'+1 is defined to be 'AA' (it says that in the manual, > too!), so your loop has to be: > > for($letter = 'A'; $letter <= 'AA'; $letter++){ > echo $letter . "\n"; > } > [/snip] > > Run this, you'l

RE: [PHP] stepping through alphabet

2003-11-19 Thread Jay Blanchard
[snip] 'Z'+1 is defined to be 'AA' (it says that in the manual, too!), so your loop has to be: for($letter = 'A'; $letter <= 'AA'; $letter++){ echo $letter . "\n"; } [/snip] Run this, you'll be surprised at what you get. -- PHP General Mailing List (http://www.php.net/) To unsubscrib

RE: [PHP] stepping through alphabet

2003-11-19 Thread Ford, Mike [LSS]
On 19 November 2003 14:25, Jay Blanchard contributed these pearls of wisdom: > [snip] > for ($letter = 'A'; $letter++; $letter <= 'Z') > echo " href=\"?action=alphabet&letter=$letter\">$letter\n"; > [/snip] > > I tested this and found two small problems. The code works if > you do this (I was

[PHP] array_diff question

2003-11-19 Thread Manuel Vázquez Acosta
Hi: I read on the docs that array_diff and array_intersect were "broken on 4.0.4". Does this mean that there is a best method to do it? Manu. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Counting elements in an array

2003-11-19 Thread Jason Wong
On Wednesday 19 November 2003 23:24, Jeff McKeon wrote: > How would I count the number of elements in an array that had a certain > value? > > In other words, if I have > > $fruit = array(orange,orange,apple,bananna,orange,apple,pear); > > How could I get the number of elements from $fruit where th

[PHP] Re: Custom Session usind MySQL

2003-11-19 Thread Manisha Sathe
thanks all for your help, will try it out now manisha "Manisha Sathe" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I want the session to be accessed from different websites, so i got the > answer in this forum only to make use of customised session with mysql. > > I searched the

[PHP] PHP-Only Polling Script?

2003-11-19 Thread Mark D Hiatt
Can anyone recommend a good, simple PHP-only polling script? I have a non-profit with no money that wants people to be able to select one from a range of candidates, and then see the total number of votes, the percentage breakdown and probably a histogram or a bar graph showing the most popula

RE: [PHP] Counting elements in an array

2003-11-19 Thread Jay Blanchard
[snip] How would I count the number of elements in an array that had a certain value? In other words, if I have $fruit = array(orange,orange,apple,bananna,orange,apple,pear); How could I get the number of elements from $fruit where the value is "orange"? [/snip] http://www.php.net/array_keys -

Re: [PHP] Counting elements in an array

2003-11-19 Thread Sophie Mattoug
$i = 0; foreach ($fruit as $k) if ('prange' == $k) $i++; (The result is $i, of course) Jeff McKeon wrote: How would I count the number of elements in an array that had a certain value? In other words, if I have $fruit = array(orange,orange,apple,bananna,orange,apple,pear); How could I get th

[PHP] Counting elements in an array

2003-11-19 Thread Jeff McKeon
How would I count the number of elements in an array that had a certain value? In other words, if I have $fruit = array(orange,orange,apple,bananna,orange,apple,pear); How could I get the number of elements from $fruit where the value is "orange"? Thanks, Jeff -- PHP General Mailing List (htt

Re: [PHP] I cannot run a .php file on a IIS

2003-11-19 Thread CPT John W. Holmes
From: "Papadogoulas Christos" <[EMAIL PROTECTED]> > I was going to ask you how can I run a .php file using IIS. > IIS and PHP, and a virtual directory are already installed. I would suggest you actually make an attempt at installing PHP according to the directions in the manual... http://www.p

Re: [PHP] mcrypt libraries?

2003-11-19 Thread Jas
Evan Nemerson wrote: On Tuesday 18 November 2003 01:13 pm, Jas wrote: Curt Zirzow wrote: * Thus wrote Jas ([EMAIL PROTECTED]): I am not sure if I should post my question here but I will anyways. Ok, I have compiled the mcrypt libraries on a Redhat 9 box running apache 2 with php4. And I need t

[PHP] HTML email problem

2003-11-19 Thread Binay
Hi all, I m sendig out HTML email, using mimemail class which encodes the whole message to be sent in base64 and Content-Transfer-Encoding: is also specified as base64 only. Now one of my client is complaining that he is getting garbage in the email (shown below) after the sign up process in t

[PHP] Re: HTTP Authentication thru PHP

2003-11-19 Thread pete M
its probably because its possible to authenticate with an url ? eg http://name:[EMAIL PROTECTED] Chandu Nannapaneni wrote: hello all , I'm able to get successfully http authenticated from my php scripts Ex : $header = "POST /myscript.php HTTP/1.0\r\nAuthorization: Basic "; $header .=

Re: [PHP] stepping through alphabet

2003-11-19 Thread Chris Boget
> I tested this and found two small problems. The code works if you do > this (I was myself amazed that letters would increment) But is that a bug? Or a feature? You could also do this, which would probably be more universal: // 65 through 90 for upper case // 97 through 122 for lower case for(

Re: [PHP] HTTP Authentication thru PHP

2003-11-19 Thread Sophie Mattoug
Jay Blanchard wrote: Or colons. It is a Bad Practice[tm] to use any special characters in user names and/or passwords. It is not universally allowed from OS to OS I disagree with this : special characters are useful to have better passwords (more difficult to crack), but as apache stores the so

  1   2   >