php-general Digest 15 Dec 2002 22:09:08 -0000 Issue 1765

Topics (messages 128323 through 128346):

Re: Querying two tables
        128323 by: Lars Olsson

Re: Session: I RTFM
        128324 by: Marco Tabini
        128325 by: michael kimsal

Getting full HTTP request the page was requested with?
        128326 by: Leif K-Brooks
        128328 by: Hatem Ben
        128335 by: Leif K-Brooks

AIM and PHP
        128327 by: John Meyer

New PHP Editor/IDE Project
        128329 by: Hidayet Dogan

Getting a field value
        128330 by: drparker
        128333 by: Jason Wong

JPG from Blob to HTML
        128331 by: Miro Kralovic
        128332 by: Jason Wong
        128334 by: Miro Kralovic

PHP/MySQL Query
        128336 by: Steven M
        128337 by: Leif K-Brooks
        128343 by: Steven M

Problems with "ftp_put()", .in.-file already exists
        128338 by: Tobias Schlitt

Socket_connect() timeout
        128339 by: Max Clark

PGP/PHP
        128340 by: Jonathan
        128341 by: Jonathan

Re: arrays
        128342 by: drparker

Passing text info using $PHP_SELF
        128344 by: Lightfirst
        128345 by: Jason Sheets

Executing a Perl/CGI program from PHP
        128346 by: Troy May

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message --- Hi!

To fetch information from several tables you usually use a join operation. Here's a starting point in the MySQL manual.

http://www.mysql.com/doc/en/JOIN.html

/Lars ([EMAIL PROTECTED])



Cesar Aracena wrote:
Hi all,

I have several tables from which I have to fetch certain products &
categories based on customer selection. The tables are as follows:

Table 1 - Categories
catid (autonum)
catname

Table 2 - Sub categories
subcatid (autonum)
subcatname

Table 3 - Products
prodid (autonum)
prodname

Table 4 - Relationships
Catid
Subcatid
Prodid

Now, the question is how to fetch all the sub-categories let's say that
are related to category 0001. I know it's as simple as relating two
tables in one query, but I don't remember how. Any help appreciated.


Cesar L. Aracena
[EMAIL PROTECTED]
[EMAIL PROTECTED]
(0299) 156-356688
Neuquén (8300) Capital
Argentina




--- End Message ---
--- Begin Message ---
Single quotes are normal strings. Double quotes are strings in which
substitutions can take place. For example:

<?php

$a = 'test';

echo '$a';      // outputs $a
echo "$a";      // outputs test

?>

Double quotes also expand escape strings (e.g."\n") whereas single
quotes don't.

Cheers,


Marco
-- 
------------
php|architect - The Magazine for PHP Professionals
The monthly magazine dedicated to the world of PHP programming

Check us out on the web at http://www.phparch.com!
--- Begin Message ---
Marco (or anyone)

What is the difference between:
$familyname = getvar("familyname");
and
$familyname = getvar('familyname');

What do single quotes do, as a general rule, that double cannot (he asks remembering 
something, but not sure what)?




Marco Tabini wrote:

> I haven't followed the rest of the thread, but how about using a
> function?
>
> function getvar ($varname)
> {
>         if (isset ($_POST[$varname])
>         {
>                 $_SESSION[$varname] = $_POST[$varname];
>                 return $_POST[$varname];
>         }
>         elseif (isset ($_SESSION[$varname]))
>                 return $_SESSION[$varname];
> }
>
> session_start();
>
> // You don't need session_register anymore
>
> $familyname = getvar('familyname');
>
> and so on--just one line per variable.
>
> Hope this helps.
>
> Cheers,
>
> Marco
> --
> ------------
> php|architect - The Magazine for PHP Professionals
> The monthly magazine dedicated to the world of PHP programming
>
> Check us out on the web at http://www.phparch.com!
>
>                                                   
>-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Subject: [PHP] Session: I RTFM
> Date: Sat, 14 Dec 2002 18:41:40 -0500
> From: John Taylor-Johnston <[EMAIL PROTECTED]>
> Reply-To: [EMAIL PROTECTED]
> Organization: FLSH, U-de-S
> To: [EMAIL PROTECTED]
>
> >Jason wrote:
> >RTFM again.
>
> Jason, again, I RTFM, but did not get it working.
> Otherwise I wouldn't have dared ask a question.
>
> >Sessions depends on a number of factors
> >including your version of PHP and the setting of register_globals.
>
> The FM manual says:
>
> "$_SESSION (or $HTTP_SESSION_VARS with PHP 4.0.6 or less) is recommended"
>
> So I am using "PHP Version 4.1.2" (and "4.2.3" on my localhost to test offline)
>
> Ok. I quit using $HTTP_POST_VARS["familyname"].
>
> With a little rethinking, I have this working, I hope.
>
> Now ... is there a cleaner way to assign my variable "familyname"?
>
> Pseudo code:
>
> if _post["familyname"] exists set session variable
>                  (no sense in setting it until I post it)
> if _session["familyname"] exists, $familyname = $_SESSION["familyname"];
>
> I'll have about 30 variables. Going to be alot of lines. There must be an easier, 
>cleaner way?
>
> <?php
> #session_name("TestALS");
> session_start();
>
> if (isset($_POST["familyname"]))
> {
> session_register("familyname");
> $familyname = $_POST["familyname"];
> echo "Yay: \$familyname= $familyname<br>";
> }
>
> if (isset($_SESSION["familyname"]))
> {
> $familyname = $_SESSION["familyname"];
> echo "yay session works, \$familyname= $familyname<br>";
> }
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php

--
John Taylor-Johnston
-----------------------------------------------------------------------------
"If it's not open-source, it's Murphy's Law."

  ' ' '   Collège de Sherbrooke:
 ô¿ô   http://www.collegesherbrooke.qc.ca/languesmodernes/
   -     Université de Sherbrooke:
          http://compcanlit.ca/
          819-569-2064



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

--- End Message ---
--- End Message ---
--- Begin Message ---
Marco Tabini wrote:
Single quotes are normal strings. Double quotes are strings in which
substitutions can take place. For example:

<?php

$a = 'test';

echo '$a';	// outputs $a
echo "$a";	// outputs test

?>

Double quotes also expand escape strings (e.g."\n") whereas single
quotes don't.
However, in a case like this:

--------------
What is the difference between:
$familyname = getvar("familyname");
and
$familyname = getvar('familyname');
--------------

There's no effective difference.

:)

Good magazine Marco - keep it up!

Michael Kimsal
http://www.phpappserver.com
734-480-9961

--- End Message ---
--- Begin Message --- Is there a way to find out exactly what HTTP request was made for a page? Something like:
GET http://myserver.com/whatever.php HTTP/1.1
Host: myserver.com

--
The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law.


--- End Message ---
--- Begin Message ---
$url = "http://myserver.com";;

$sockhandle = @fsockopen($url, 80, &$errno, &$errstr);
if(!$sockhandle) {
$mes = "server $url not available!";
$result = "<center><h5>$mes</h5></center>";
return $result;
} else {
$request = "GET / HTTP/1.1\r\n";
$request .= "User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows
98)\r\n";
$request .= "Host: $url\r\n";
$request .= "Connection: Close\r\n\r\n";
fputs($sockhandle, $request);
$res = "";
$line = fgets($sockhandle, 1024); //Request Method
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Close Method
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Server Type
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Date
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Transfer-Encoding
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Content-Type
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Cache-control
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Set-Cookie
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //End Header "space"
$res .= "$line\n";
$res = addslashes($res);
return $res;

----- Original Message -----
From: "Leif K-Brooks" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, December 15, 2002 4:54 PM
Subject: [PHP] Getting full HTTP request the page was requested with?


> Is there a way to find out exactly what HTTP request was made for a
> page?  Something like:
> GET http://myserver.com/whatever.php HTTP/1.1
> Host: myserver.com
>
> --
> The above message is encrypted with double rot13 encoding.  Any
unauthorized attempt to decrypt it will be prosecuted to the full extent of
the law.
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php

--- End Message ---
--- Begin Message --- Thanks, but I'm trying to see what the client sent to get my page, not what a host returns when I send it a request...

Hatem Ben wrote:

$url = "http://myserver.com";;

$sockhandle = @fsockopen($url, 80, &$errno, &$errstr);
if(!$sockhandle) {
$mes = "server $url not available!";
$result = "<center><h5>$mes</h5></center>";
return $result;
} else {
$request = "GET / HTTP/1.1\r\n";
$request .= "User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows
98)\r\n";
$request .= "Host: $url\r\n";
$request .= "Connection: Close\r\n\r\n";
fputs($sockhandle, $request);
$res = "";
$line = fgets($sockhandle, 1024); //Request Method
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Close Method
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Server Type
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Date
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Transfer-Encoding
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Content-Type
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Cache-control
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //Set-Cookie
$res .= "$line\n";
$line = fgets($sockhandle, 1024); //End Header "space"
$res .= "$line\n";
$res = addslashes($res);
return $res;

----- Original Message -----
From: "Leif K-Brooks" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, December 15, 2002 4:54 PM
Subject: [PHP] Getting full HTTP request the page was requested with?



Is there a way to find out exactly what HTTP request was made for a
page? Something like:
GET http://myserver.com/whatever.php HTTP/1.1
Host: myserver.com

--
The above message is encrypted with double rot13 encoding. Any

unauthorized attempt to decrypt it will be prosecuted to the full extent of
the law.


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



--
The above message is encrypted with double rot13 encoding.  Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law.


--- End Message ---
--- Begin Message ---
        does anybody know of a class or a PEAR module to check the status of an AIM
user and see if they are online or offline.

--- End Message ---
--- Begin Message ---
Hello,

I'm going to write a new PHP editor/ide, it named 'PHP Express'.
I opened new website for this project. http://www.phpexpress.com
and i created a small voting about 'user interface'. If you want
to support me and/or if you have an idea for this project you can
connect this web site and vote or you can send me your ideas.

Thanks for interest and have a good programming with PHP.

PHP Express Project Web Site: http://www.phpexpress.com
Hidayet Dogan: http://www.hido.net

                                             Hidayet Dogan
                              [EMAIL PROTECTED]

Pleksus Bilisim Teknolojileri D.T.O. A.S.
----------------------------------------------------------
caldiran sok. 14/6 06420 kolej ankara * www.pleksus.com.tr
tel : +90 312 4355343 * faks: +90 312 4354006

--- End Message ---
--- Begin Message ---
I'm adding information with the INSERT command to 2 tables.  In the
first table, called "courses", I have a field called "course_id" that is
an auto-increment - assigned by the table.  In the second table, called
"par", I have a field also called "course_id".   I need to assign to
this field the value that is assigned for "course_id" in the "courses"
table.  The problem is, I don't know what it is going to assign, and I
can't get the variable with a query such as "SELECT * FROM counties
WHERE course_id = ##" because I don't know what number is going to be
assigned as the course_id.  Basically, I need to store the that
course_id value of the course I just added in a a variable, and I don't
know how to retrieve that variable.

Any help would be greatly appreciated...

--- End Message ---
--- Begin Message ---
On Monday 16 December 2002 01:22, drparker wrote:

This is the type of question that is best asked on the php-db list. 

> I'm adding information with the INSERT command to 2 tables.  In the
> first table, called "courses", I have a field called "course_id" that is
> an auto-increment - assigned by the table.  In the second table, called
> "par", I have a field also called "course_id".   I need to assign to
> this field the value that is assigned for "course_id" in the "courses"
> table.  The problem is, I don't know what it is going to assign, and I
> can't get the variable with a query such as "SELECT * FROM counties
> WHERE course_id = ##" because I don't know what number is going to be
> assigned as the course_id.  Basically, I need to store the that
> course_id value of the course I just added in a a variable, and I don't
> know how to retrieve that variable.

If you're using MySQL you can use mysql_insert_id(). If you're using some 
other DBMS then have a look at the manual to see whether there is a similar 
function.

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *

/*
Pardo's First Postulate:
        Anything good in life is either illegal, immoral, or fattening.

Arnold's Addendum:
        Everything else causes cancer in rats.
*/

--- End Message ---
--- Begin Message ---
Hi,

I have few images in PostgreSQL Blob field that I want to retrieve and put
on HTML page. Is there a way how can I do it directly from blob, or I have
to copy it into tmp file first and then use <img src> tags in html?

TIA,
miro.


--- End Message ---
--- Begin Message ---
On Monday 16 December 2002 01:33, Miro Kralovic wrote:

* Bad thread start
\__________________

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 to. A mail client uses this information
to build a threaded view ("tree view") of the postings.

With your posting style you successfully torpedoed this useful feature; your
posting shows up within an existing thread it has nothing to do with.

Always do a fresh post when you want to start a new thread. To achieve this,
click on "New message" instead of "Reply" within your mail client, and enter
the list address as the recipient. You can save the list address in your
address book for convenience.

> I have few images in PostgreSQL Blob field that I want to retrieve and put
> on HTML page. Is there a way how can I do it directly from blob, or I have
> to copy it into tmp file first and then use <img src> tags in html?

You can output it directly. Just send the appropriate headers beforehand. 
Search archives for details.

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *

/*
The doctrine of human equality reposes on this: that there is no man
really clever who has not found that he is stupid.
                -- Gilbert K. Chesterson
*/

--- End Message ---
--- Begin Message ---
ops, sorry for that..

-----Original Message-----
From: Jason Wong [mailto:[EMAIL PROTECTED]]
Sent: Sunday, December 15, 2002 12:39
To: [EMAIL PROTECTED]
Subject: Re: [PHP] JPG from Blob to HTML


On Monday 16 December 2002 01:33, Miro Kralovic wrote:

* Bad thread start
\__________________

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 to. A mail client uses this information
to build a threaded view ("tree view") of the postings.

With your posting style you successfully torpedoed this useful feature; your
posting shows up within an existing thread it has nothing to do with.

Always do a fresh post when you want to start a new thread. To achieve this,
click on "New message" instead of "Reply" within your mail client, and enter
the list address as the recipient. You can save the list address in your
address book for convenience.

> I have few images in PostgreSQL Blob field that I want to retrieve and put
> on HTML page. Is there a way how can I do it directly from blob, or I have
> to copy it into tmp file first and then use <img src> tags in html?

You can output it directly. Just send the appropriate headers beforehand.
Search archives for details.

--
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *

/*
The doctrine of human equality reposes on this: that there is no man
really clever who has not found that he is stupid.
                -- Gilbert K. Chesterson
*/


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

--- End Message ---
--- Begin Message ---
How do i make a form that will allow me to add 2 to the value of a MySQL
field?  I am trying to change it from 75 to 77.  Is this possible?

Thanks


--- End Message ---
--- Begin Message ---
mysql_query("update table set field=field+1 where whatever='whatever'");

Steven M wrote:

How do i make a form that will allow me to add 2 to the value of a MySQL
field? I am trying to change it from 75 to 77. Is this possible?

Thanks




--
The above message is encrypted with double rot13 encoding.  Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law.



--- End Message ---
--- Begin Message ---
Leif

Many thanks for that, your help is much appreciated.  *smiles*

Steven M


--- End Message ---
--- Begin Message ---
Hi all!

I've written some small FTP-Class, which i would like to 
release into PEAR.
The class covers a method, to recursively up- and download whole
directories. But everytime i try running the method over the 
whole PEAR-API-Doc, i generated with phpdoc, i get the 
following error, even, if the upload-directory is empty:
-- snip --
ftp_put():
/public_html/privat/pear/XML/XML_Transformer_Namespace_PHP.html:
Temporary hidden file
/public_html/privat/pear/XML/.in.XML_Transformer_Namespace_PHP.html.
already exists in <b>/usr/lib/php/pear/Net/FTP.php</b> on line
<b>498</b><br />
-- snip --

You can find the class here (for error-reviewing):
http://www.schlitt-design.de/ftp.zip.

Thans a lot for every help!
Regards,
Toby
-- 
<?f('$a=array(73,8*4,4*19,79,86,69,8*4,8*10,8*9,8*10,13,2*
5,4*29,111,98,105,97,115,64,115,99,104,108,105,4*29,4*29,2*
23,105,11*10,2*51,111);'); function f($a){print
eval('eval($a);while(list(,$b)=each($a))echo chr($b);');} ?>
--- End Message ---
--- Begin Message ---
Warning: socket_connect() unable to connect [60]: Operation timed out in
/usr/home/maxc/public_html/admin/functions.inc on line 66

Is there any way to time out this function? I only want to wait 5 seconds.

Thanks in advance,
Max

"Johannes Schlueter" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
On Friday 13 December 2002 21:30, Max Clark wrote:
> I found the socket_create function that is listed as experimental and
> requires a re-compile of php. Is there a built in way to perform this kind
> of test?


Based upon the second example on
http://www.php.net/manual/en/ref.sockets.php :

echo "<h2>TCP/IP Connection</h2>\n";

/* Get the service for TCP-Port 25. */
$service_port = getservbyport (25, 'tcp');

/* Get the IP address for the target host. */
$address = gethostbyname ('www.example.com');

/* Create a TCP/IP socket. */
$socket = socket_create (AF_INET, SOCK_STREAM, 0);
if ($socket < 0) {
    echo "socket_create() failed: reason: " . socket_strerror ($socket) .
"\n";
} else {
    echo "OK.\n";
}

echo "Attempting to connect to '$address' on port '$service_port'...";
$result = socket_connect ($socket, $address, $service_port);
if ($result < 0) {
    echo "socket_connect() failed.\nReason: ($result) " .
socket_strerror($result) . "\n";
} else {
    echo "OK.\n";
}


johannes

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





--- End Message ---
--- Begin Message ---
I have necessary PGP client software on my machine and have tested the
functionality of PGP from my site, however, I want to know how to use PHP to
send a PGP email.

This is the scenario, 

I have a shopping cart which directs to SSL, then while in SSL, the customer
will input their information, including credit card info. 

I want to show a receipt, (no cc #'s of course) and send the order to an
administrator of the site using PGP after all the information has been
gathered and send it from SSL. The site's admin will be able decrypt the
information using the client software.

Thanks in advance.
===================
Jonathan Villa
Application Developer
IS Design & Development
www.isdesigndev.com <http://www.isdesigndev.com/> 
414.429.0327
===================
--- End Message ---
--- Begin Message ---
I have necessary PGP client software on my machine and have tested the
functionality of PGP from my site, however, I want to know how to use
PHP to send a PGP email.

This is the scenario, 

I have a shopping cart which directs to SSL, then while in SSL, the
customer will input their information, including credit card info. 

I want to show a receipt, (no cc #'s of course) and send the order to an
administrator of the site using PGP after all the information has been
gathered and send it from SSL. The site's admin will be able decrypt the
information using the client software.


Thanks in advance.


--- End Message ---
--- Begin Message ---
this should work:

for ($i=0; $i<5; $i++) {
  $mypics[$i] = $picture;
}


Edward Peloke wrote:

> Ok, very basic question, how do I am going through a loop 5 times, each
> time, I want to store a value into an array, do I simply set the value of
>
> $picture=array($mypics);
>
> and each time it loops it will take the current value of $picture and then I
> can get out each value by $mypics[0], $mypics[1], etc?
>
> Thanks,
> Eddie

--- End Message ---
--- Begin Message ---
I am using PHP and MySql and wanted to know if it possible to pass the value
inserted in a text box back to the page using PHP_SELF. Bellow is the
snipped of code. The part that is not working is &q=input. Any ideas?

Thanks.



while($query_data = mysql_fetch_array($result)) {

$id = $query_data ["q_id"];

$q = $query_data ["question"];

$a = $query_data ["answer"];

echo "<TR>\n";

echo "<TD WIDTH=\"5%\" ALIGN=\"CENTER\">$id</TD>\n";

echo "<TD WIDTH=\"70%\" ALIGN=\"CENTER\">$q</TD>\n";

echo "<TD WIDTH=\"15%\" ALIGN=\"CENTER\"><input type=\"text\"
name=\"textfield\" value=$a></TD>\n";

echo "<TD WIDTH=\"10%\" ALIGN=\"CENTER\">

<form name=\"update\" method=\"post\"
action=\"$PHP_SELF?action=change&id=$id&q=input\">

<input type=\"submit\" name=\"input\" value=\"Update\">



--- End Message ---
--- Begin Message ---
Rather than using forms to pass information to a script you should
consider using sessions instead.

In any case if you are going to use forms instead of appending the
information to the form action use the input type=hidden field.

<input type="hidden" name="action" value="change">

This keeps your form action clean and it also allows you to cleanly use
POST instead of GET.

Jason

On Sun, 2002-12-15 at 12:23, Lightfirst wrote:
> I am using PHP and MySql and wanted to know if it possible to pass the value
> inserted in a text box back to the page using PHP_SELF. Bellow is the
> snipped of code. The part that is not working is &q=input. Any ideas?
> 
> Thanks.
> 
> 
> 
> while($query_data = mysql_fetch_array($result)) {
> 
> $id = $query_data ["q_id"];
> 
> $q = $query_data ["question"];
> 
> $a = $query_data ["answer"];
> 
> echo "<TR>\n";
> 
> echo "<TD WIDTH=\"5%\" ALIGN=\"CENTER\">$id</TD>\n";
> 
> echo "<TD WIDTH=\"70%\" ALIGN=\"CENTER\">$q</TD>\n";
> 
> echo "<TD WIDTH=\"15%\" ALIGN=\"CENTER\"><input type=\"text\"
> name=\"textfield\" value=$a></TD>\n";
> 
> echo "<TD WIDTH=\"10%\" ALIGN=\"CENTER\">
> 
> <form name=\"update\" method=\"post\"
> action=\"$PHP_SELF?action=change&id=$id&q=input\">
> 
> <input type=\"submit\" name=\"input\" value=\"Update\">
> 
> 
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php

--- End Message ---
--- Begin Message ---
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

--- End Message ---

Reply via email to