[PHP] Testing..

2003-02-09 Thread Troy May
Just a quick test.  I just re-signed up for this list after a 3 week
vacation and I haven't seen even one message yet.  So, reply if you get it
please so I know this is working.

Thanks,
Troy


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




[PHP] Executing a Perl/CGI program from PHP

2002-12-15 Thread Troy May
Hello,

I have a logging program I wrote in Perl that writes basic info to a MySQL
database.  I can't get it working from within PHP.  I've tried:

print !--#exec cgi='vislog.cgi'--;
echo (!--#exec cgi='vislog.cgi'--);
include(vislog.cgi);

Nothing works. What am I missing?

Thanks,
Troy


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




[PHP] Regex question

2002-12-12 Thread Troy May
How would take a regular non-formatted text link (http://www.link.com) and
turn it into ready to post HTML? (a
href=http://www.link.comhttp://www.link.com/a)

Darn, Outlook formats it, but you get the idea.  It would just be typed out
normally.

Any ideas?


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




[PHP] Passing arguments to the same script

2002-12-01 Thread Troy May
Hello,

I'm sure this is easy, but I'm drawing a blank.  I need to have links at the
bottom of the page that passes arguments to the same script (itself) when it
gets reloaded.  How do we do this?

I have the links like this now:

a href=index.php?samples

How do I determine what is passed?  I need to do an if statement with
different outputs depending on the argument.

if ($samples) { do something }

??  But I can't get anything to work.  How do I do it in PHP? (I have no
forms, just links)


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




RE: [PHP] Passing arguments to the same script

2002-12-01 Thread Troy May
Thanks for responding.  I think I'm still doing something wrong.  Take a
peek:

if(isset($_GET['questions'])) {
  echo Questions link content will go here;
   }
elseif(isset($_GET['samples'])) {
  echo Samples link content will go here;
   }
elseif(isset($_GET['rates'])) {
  echo Rates link content will be here;
   }
elseif(isset($_GET['contact'])) {
  echo Contact information will go here.;
} else {
echo Main content goes here.;
}

The only thing that EVER gets displayed is the final else. (Main content
goes here.)  What am I doing wrong?  Once again, the links are in this
format: a href=index.php?samples

Any ideas?


-Original Message-
From: John W. Holmes [mailto:[EMAIL PROTECTED]]
Sent: Sunday, December 01, 2002 7:39 PM
To: 'Troy May'; 'PHP List'
Subject: RE: [PHP] Passing arguments to the same script


 I'm sure this is easy, but I'm drawing a blank.  I need to have links
at
 the
 bottom of the page that passes arguments to the same script (itself)
when
 it
 gets reloaded.  How do we do this?

 I have the links like this now:

 a href=index.php?samples

 How do I determine what is passed?  I need to do an if statement
with
 different outputs depending on the argument.

 if ($samples) { do something }

if(isset($_GET['samples']))
{ do something }

---John Holmes...




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




RE: [PHP] Passing arguments to the same script

2002-12-01 Thread Troy May
Not sure which version, it's my ISP.

Adding =1 to the URL worked though.  Thanks!


-Original Message-
From: John W. Holmes [mailto:[EMAIL PROTECTED]]
Sent: Sunday, December 01, 2002 8:08 PM
To: 'Troy May'; 'PHP List'
Subject: RE: [PHP] Passing arguments to the same script


What PHP version are you using? Try $HTTP_GET_VARS['sample'] if it's an
older version. Also try index.php?sample=1, so that sample actually
has a value (although the method I gave you worked on IIS).

---John Holmes...

 -Original Message-
 From: Troy May [mailto:[EMAIL PROTECTED]]
 Sent: Sunday, December 01, 2002 11:02 PM
 To: [EMAIL PROTECTED]; 'PHP List'
 Subject: RE: [PHP] Passing arguments to the same script
 
 Thanks for responding.  I think I'm still doing something wrong.  Take
a
 peek:
 
 if(isset($_GET['questions'])) {
   echo Questions link content will go here;
  }
 elseif(isset($_GET['samples'])) {
   echo Samples link content will go here;
  }
 elseif(isset($_GET['rates'])) {
   echo Rates link content will be here;
  }
 elseif(isset($_GET['contact'])) {
   echo Contact information will go here.;
 } else {
 echo Main content goes here.;
 }
 
 The only thing that EVER gets displayed is the final else. (Main
content
 goes here.)  What am I doing wrong?  Once again, the links are in this
 format: a href=index.php?samples
 
 Any ideas?
 
 
 -Original Message-
 From: John W. Holmes [mailto:[EMAIL PROTECTED]]
 Sent: Sunday, December 01, 2002 7:39 PM
 To: 'Troy May'; 'PHP List'
 Subject: RE: [PHP] Passing arguments to the same script
 
 
  I'm sure this is easy, but I'm drawing a blank.  I need to have
links
 at
  the
  bottom of the page that passes arguments to the same script (itself)
 when
  it
  gets reloaded.  How do we do this?
 
  I have the links like this now:
 
  a href=index.php?samples
 
  How do I determine what is passed?  I need to do an if statement
 with
  different outputs depending on the argument.
 
  if ($samples) { do something }
 
 if(isset($_GET['samples']))
 { do something }
 
 ---John Holmes...
 
 




-- 
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




RE: [PHP] Passing arguments to the same script

2002-12-01 Thread Troy May
Thanks, I got it working by adding =1



-Original Message-
From: Chris Wesley [mailto:[EMAIL PROTECTED]]
Sent: Sunday, December 01, 2002 8:08 PM
To: 'PHP List'
Cc: Troy May
Subject: RE: [PHP] Passing arguments to the same script


On Sun, 1 Dec 2002, Troy May wrote:

 The only thing that EVER gets displayed is the final else. (Main content
 goes here.)  What am I doing wrong?  Once again, the links are in this
 format: a href=index.php?samples

a href=index.php?samples=1

To get the desired results with the code you posted, you have to give your
query string parameter(s) a value (as above).  If you don't want to give
samples a value, then examine the query string as a whole:
$_SERVER[QUERY_STRING]

if( $_SERVER[QUERY_STRING] == samples ) ...

g.luck,
~Chris



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




[PHP] Why all the returned emails from this list?

2002-12-01 Thread Troy May
I'm getting nailed with a bunch of returned emails like this:

[EMAIL PROTECTED] - no such user here.

There is no user by that name at this server.
: Message contains [1] file attachments


What's going on?  Each one has a different address, but the terminalgmb.ru
part is the same for each one.


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





[PHP] Redirect opening in a new window

2002-11-30 Thread Troy May
Hello,

I'm playing with a portal system now and I need to edit a module to redirect
to another site/page.  I have done this with a header() redirection, but it
takes the current window.

How can I do this and have it open a new window for the redirect?



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




RE: [PHP] Redirect opening in a new window

2002-11-30 Thread Troy May
That easy solution is not so easy for me.  This portal system is PHP-Nuke.
There's different themes, pages, etc.  It would take me 3 weeks to find and
edit all the links in a 2000 file directory.

I just need to be able to do this from the called module itself, and that
would take care of all the pages/themes in one shot.



-Original Message-
From: Jeffrey B.Ferland [mailto:[EMAIL PROTECTED]]
Sent: Saturday, November 30, 2002 12:02 PM
To: Troy May
Subject: Re: [PHP] Redirect opening in a new window


On Saturday 30 November 2002 02:55 pm, you wrote:
 Hello,

 I'm playing with a portal system now and I need to edit a module to
 redirect to another site/page.  I have done this with a header()
 redirection, but it takes the current window.

 How can I do this and have it open a new window for the redirect?

a href=/link.htm target=_blankDisplayed Link/a


-Jeff
SIG: HUP


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




RE: [PHP] forum module for NUKE?

2002-11-25 Thread Troy May
Doesn't PHP-Nuke have support forums?  It would be better to ask in there if
they do.


-Original Message-
From: The Gabster [mailto:[EMAIL PROTECTED]]
Sent: Monday, November 25, 2002 3:43 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] forum module for NUKE?


Thanks Peter...

I was there but I wasn't able to come up with anything. Can you please name
one?

Thanks a lot,
GAbi.


Peter Houchin [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 there's sort of one in there already ... but also check out
 http://www.nukescripts.net/ and that has links off that for other nuke
 sites/add on's

  -Original Message-
  From: The Gabster [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, 26 November 2002 9:35 AM
  To: [EMAIL PROTECTED]
  Subject: [PHP] forum module for NUKE?
 
 
  Hi all,
 
  I am looking for a php forum module for NUKE portal system. I am
  specifically looking for the same functionality as yahoogroups
  has where the
  user can post/receive messages on a specified email address- beside
  accessing the forum via the web.
 
  Thanks a lot,
  GAbi.
 
  __
  http://65.104.178.73/marshall/
 
 
 
  --
  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




RE: [PHP] STRICTLY CONFIDENCIAL

2002-11-21 Thread Troy May
Oldest scam in the book.  Nice try.


-Original Message-
From: desmond west [mailto:[EMAIL PROTECTED]]
Sent: Sunday, November 17, 2002 4:30 PM
To: [EMAIL PROTECTED]
Subject: [PHP] STRICTLY CONFIDENCIAL


#20 BOTHA CRESCENT,
SADTON,JOHANNESBURG,
SOUTH AFRICA.
Tel/Fax:+:+27-834377724
E-mail:[EMAIL PROTECTED]

Dear sir,

In order to transfer out (USD 126 M) One hundred
and
twenty six million United States Dollars) from
NED Bank in south africa. I have the courage to ask
you
to
look for a reliable and honest person who will be
capable for this important business believing
that
you
will never let me down either now or in future.

I am Mr. DESMOND WEST,the Chief auditor of
NED Bank in south africa.
There is an account opened in this bank in 1980
and
since 1990 nobody has operated on this account
again.
After going through some old files in the
records,
I
discovered that if I do not remit this money out
urgently it would be forfeited for nothing. The
owner
of this account is Mr. ADAMS .H. NICOLES, a
foreigner,
profession and he died since 1990. No other
person
knows about this account or any thing concerning
it,
the account has no other beneficiary and my
investigation proved to me as well that this
company
does not know anything about this account and the
amount involved is (USD 126M) One hundred and
twenty
six million United States Dollars million
dollars.

I want to first transfer USDM twenty six million
United States Dollars from this money into a safe
foreigners account abroad before the rest, but I
don't
know any foreigner.
I am only contacting you as a foreigner because
this
money cannot be approved to a local bank here,
but
can
only be approved to any foreign account because
the
money is in us dollars and the former owner of
the
account is Mr. ADAMS .H. NICOLES he is a foreigner
too.

I know that this message will come to you as a
surprise as we don't know ourselves before. We
will
sign an agreement, but be sure that it is real
and
a
genuine business.

I only got your contact address from my secretary
who operates computer, with believe in God that
you
will never let me down in this business. You are
the
only person that I have contacted in this
business;
so
please reply urgently so that I will inform you
the
next step to take immediately.
Send also your private telephone and fax number
including the full details of the account to be
used
for the deposit. I want us to meet face to face
or
sign a binding agreement to bind us together so
that
you can receive this money into a foreign account
or
any account of your choice where the fund will be
safe. And I will fly to your country for
withdrawal
and sharing and other investments.

I am contacting you because of the need to
involve
a
foreigner with foreign account and foreign
beneficiary. I need your full co-operation to
make
this work fine because the management is ready to
approve this payment to any foreigner, who has
correct

information of this account, which I will give to
you


later immediately, if you are able and with
capability
to handle such amount in strict confidence and
trust
according to my instructions and advice for our
mutual
benefit because this opportunity will never come
again
in my life. I need truthful person in this
business
because I don't want to make mistake I need your
strong assurance and trust.

With my position now in the office I can transfer
this money to any foreigner's reliable account, which
you


can provide with assurance that this money will
be
intact pending my physical arrival in your
country
for
sharing. I will destroy all documents of
transaction
immediately we receive this money leaving no
trace
to
any place. You can also come to discuss with me
face
to face after which I will make this remittance
in
your presence and two of us will fly to your
country
at least two days ahead of the money going into
the
account.

I will apply for annual leave to get visa
immediately
I hear from you that you are ready to act and
receive
this fund in your account. I will use my position
and
influence to effect legal approvals and onward
transfer of this money to your account with
appropriate clearance forms of the ministries and
foreign exchange departments.

At the conclusion of this business, you will be
given
35% of the total amount, 60% will be for me,
while
5%
will be for expenses both parties might have
incurred
during the process of transferring.

I look forward to your earliest reply.
Or by my Tel/Fax:+27-834377724

Yours truly,
MR.DESMOND WEST




__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

-- 
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




RE: [PHP] MY CLIENT

2002-11-20 Thread Troy May
Sorry, I'm holding out for the 126 million.  :)



-Original Message-
From: GEORGE EMEKA [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 20, 2002 10:18 PM
To: [EMAIL PROTECTED]
Subject: [PHP] MY CLIENT
Importance: High



GOLDEN BUSINESS OPPORTUNITY
I am an Attorney and close confidant of MRS. MARYAM
ABACHA, the former first lady and wife of the late
GEN. SANI ABACHA, the former head of state and
commander in chief of the armed forces of the Federal
Republic of Nigeria.

She (MRS. M. ABACHA), has as a result of the trust and
confidence she has in me mandated that I search for a
reliable and trustworthy foreign partner, who
will help receive some funds which she had in cash
totaling US$45m (Forty Five Million United States
Dollars Only) into a personal, company or any
reliable foreign bank account for safe keeping for a
short period of time, since her family bank accounts
within and outside the country have all been
frozen by the authorities. (I would refer you to the
website of
.http://www.transnationale.org/anglais/sources/tiersmonde/dirigeants__aba
http://allafrica.com/stories/200203180074.html
http://www.time.com/time/europe/magazine/2000/27/swiss.html ,
 for further information
about these monies and the ABACHAS)

This money in question has however, been carefully
keptin defaced form and deposited with a security
company that has branches in Europe and America.
You may therefore be required to travel to any
of the branches to collect the money on behalf of my
client for safe keeping.

It may also interest you to know that she (MRS.
ABACHA) and her family have, since the inception of
the present democratic government, been placed under
partial house arrest, with their international
traveler's passports withdrawn pending  the resolution
of current fund recovery face - off between them and
the present RTD GEN. OBASANJO led Federal Government,
which from all indications will not exceed this year.

She has decided to offer anybody who will be willing
to render this tremendous assistance 20% of the total
sum, while 5% shall be set aside for incidental
expenses.

Note that this transaction involves no risks
whatsoever, as you will have no dealing with my
Country, Nigeria. Rather, you will deal directly with
the security company, which is based where the money
is right now.

Let me have your confidential Tel/Fax Numbers in your
response to this proposal.

I shall let you into a complete picture of this
mutually beneficial transaction when I have received
your anticipated positive reply. This matter should be
treated as urgent and confidential. This is very
important.

Best Regards,

Barrister George Emeka.







--
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




RE: [PHP] Opening a file to manipulate it

2002-11-20 Thread Troy May
Thanks Ed!  Yes, another member here told me to use fread(), which is what
your link led to if you're not using the CVS version of PHP.  (whatever that
is)

I got it working with this:

?
$file = ../header.html;
$fp = fopen($file, r);
$header = fread($fp, filesize($file));
fclose ($fp);

echo $header;

I'm a Perl guy so I was looking for an easier way.  In Perl, all you have to
do is open it, dump it to a variable and close it.  I thought it would be
that easy in PHP too.  I guess Perl wins there, but PHP is much better
overall so far.  ;)

Thanks again!

Troy

-Original Message-
From: @ Edwin [mailto:[EMAIL PROTECTED]]
Sent: Saturday, November 16, 2002 9:29 PM
To: Troy May
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Opening a file to manipulate it


Hello,

Troy May [EMAIL PROTECTED] wrote:
 Hello,

 Extreme newbie here (halfway through my first book :) ).  I need to open a
 file, read the whole file into a variable, manipulate it, and then echo it
 to the screen.  I'm doing it right from my book and it's not working.
 Here's what I have now:

 ? $header = fopen(header.html,r);

 echo $header; ?

 It writes Resource id #1 at the top of the page.  What is that?!  :)

Check the manual:

  http://www.php.net/manual/en/function.fopen.php

You're echoing the result of fopen() which is an int--you have to make
sure that you're using the function properly ;)

 I have also tried using file().  That displays Array on the screen.
What
 am I doing wrong?

I think it's because you're echoing the result of file() which is an array.
You cannot just echo $the_array; Try print_r($the_array) and you'll see a
different result--though I doubt it's the one you want to see :)

Check the manual again:

  http://www.php.net/manual/en/function.file.php

Anyway, I think you're looking for something like this:

  http://www.php.net/manual/en/function.file-get-contents.php

Esp. the User Contributed Notes.

HTH,

- E


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




[PHP] Opening a file to manipulate it

2002-11-16 Thread Troy May
Hello,

Extreme newbie here (halfway through my first book :) ).  I need to open a
file, read the whole file into a variable, manipulate it, and then echo it
to the screen.  I'm doing it right from my book and it's not working.
Here's what I have now:

? $header = fopen(header.html,r);

echo $header; ?

It writes Resource id #1 at the top of the page.  What is that?!  :)

I have also tried using file().  That displays Array on the screen.  What
am I doing wrong?

Thanks!

Troy


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




RE: [PHP] re: echo w/ here document

2002-11-12 Thread Troy May
Newbie here.  Works fine for me too.


-Original Message-
From: Marco Tabini [mailto:marcot;tabini.ca]
Sent: Tuesday, November 12, 2002 5:31 AM
To: Aaron Gould
Cc: Craig Buxton;
Subject: Re: [PHP] re: echo w/ here document


Works fine on my system. As Aaron said, make sure there are no spaces
around ENDOFECHO;


Marco

--

php|architect - The magazine for PHP Professionals
The first monthly worldwide magazine dedicated to PHP programmers
Check us out on the web at http://www.phparch.com

On Tue, 2002-11-12 at 08:21, Aaron Gould wrote:
 Looks ok to me.  Try making sure that all white space is removed from
after
 the echo ENDOFECHO, and both before and after the ENDOFECHO; line.
 Heredocs don't play nicely with white space...
 --
 Aaron Gould
 [EMAIL PROTECTED]
 Web Developer
 Parts Canada


 - Original Message -
 From: Craig Buxton [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Tuesday, November 12, 2002 5:32 AM
 Subject: [PHP] re: echo w/ here document


  I'm still having a problem with including a here document. Trying this
  code:
 
  ?php
  echo ENDOFECHO
  HTML
  BODY
  hello... hello... hello... hello...
  /BODY
  /HTML
  ENDOFECHO;
  ?
 
  I get a parse error on line 7. Please help. I have a major project that
  has ground to a halt.
 
  Craig Buxton
  Gravity Pilot Productions
  [EMAIL PROTECTED]
 
 
  --
  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 General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] testing

2002-11-12 Thread Troy May
I think it works.  ;)


-Original Message-
From: pig pig [mailto:pigpig8080;yahoo.com.sg]
Sent: Tuesday, November 12, 2002 5:44 AM
To: [EMAIL PROTECTED]
Subject: [PHP] testing


testing

__
Do You Yahoo!?
Great flight deals, travel info and prizes!
http://sg.travel.yahoo.com

-- 
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