[PHP] Free news feeds

2004-06-09 Thread csnm

Hi
I'm looking for recommendations for places I might look for free news feeds 
to incorporate into our companies website.  Specifically I'm looking for 
feeds related to the pharmaceutical and medical industries.

Thanks,
Tim
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Associative array question

2004-05-30 Thread csnm
Hello,
If I have an associative array like:
$myFriendsAges['Tom']=25;
$myFriendsAges['Bill']=35;
$myFriendsAges['Al']=45;
$myFriendsAges['Mark']=55;
Is there a way to index name into a string.  I would like to be able to 
echo something like:

My friend Bill is 35 years of age.
Is there a way to do this?
Thanks
Tim
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


RE: [PHP] Newbie Question: Variables on the fly

2004-05-27 Thread csnm
Thanks for the reply Denis,
Let me elaborate a bit.
I have a php page which I want to pass a series of variables via a url string.
eg
myPage.php?dataPoint1=10&dataPoint2=20&dataPoint3=30
The thing is I won;t know until runtime how many dataPoints there will be 
so I have also included 1 additional url variable

eg
myPage.php?totalDataPoints=3&dataPoint1=10&dataPoint2=20&dataPoint3=30
From there I want to take those data points and do several things with 
each of them.  The keep things simple lets say I want to multiply each by 3 
and then divide it by 2 and put it into a new variable (under the same 
naming system).

eg
$xtemp=$HTTP_GET_VARS[totalDataPoints];
do {
A line here which will take each dataPoint and multiply by 3 and 
divide by 2 and assign it to a new variable with the same numbering system 
(eg $myNewVar1=$HTTP_GET_VARS[dataPoint1]*3/2;
$xtemp--;
} while ($xtemp>0);

Make any more sense?
Thanks.
At 01:24 AM 28/05/2004, Dennis Seavers wrote:
Maybe others will catch on to your intention, but I think you need to
provide a bit more information.  For example, what variables do you want to
create (drawn from a file source, or create on the fly)?  Where will they
come from (a database, perhaps)?  You could create a script that creates
variables from scratch, following a (hopefully) finite mathematical
formula.  Or you could manipulate data that already exists, turning this
data into some kind of variables.
Ultimately, you'll have to give a better of sense of the end result you'd
like.
Dennis Seavers
> [Original Message]
> From: <[EMAIL PROTECTED]>
> To: PHP List <[EMAIL PROTECTED]>
> Date: 05/27/2004 9:17:11 PM
> Subject: [PHP] Newbie Question: Variables on the fly
>
> Hello,
>
> I'm sure this is a newbie question but I don't know the syntax.
>
> I want to create a series of variables within a php script at runtime
with
> a for loop.
>
> eg
>
> myVar1
> myVar2
> myVar3
> etc
>
> What is the proper syntax to do this?
>
> Thanks,
>
> Tim
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Newbie Question: Variables on the fly

2004-05-27 Thread csnm
Hello,
I'm sure this is a newbie question but I don't know the syntax.
I want to create a series of variables within a php script at runtime with 
a for loop.

eg
myVar1
myVar2
myVar3
etc
What is the proper syntax to do this?
Thanks,
Tim
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php