Marlin Unruh | 1 Dec 2005 01:31

Re: custom CAD directory/file browser

Jay Blanchard wrote:
> [snip]
> Can I use an anchor element to pass info back to the self same php 
> script? If so how? I can't seem to find my way though this aspect of the 
> project.
> [/snip]
>
> You can include information in the query string of the URL
>
> <a href="foo.php?directory=/path/to/may/files/">Click Here</a>
>
> The information would be available in the $_GET array as $_GET['directory']
>
>   
This did the trick but, how do I clear out the $_GET array? As I move 
around the directories the 'directory' string gets longer and longer. 
I'm not sure if it is an Apache variable or what that I need to clear to 
empty the ?directory= string. Below is what builds up in the browser 
address window as I go in and out of directories. How do I dump it?

http://localhost/cad.php?directory=c:/suncosys/cyl/../sbr/../act/2d/obsolete/..

-- 

Regards,
  Marlin Unruh
  Sunco Systems Inc.
  (308) 326-4400

--

-- 
(Continue reading)

EasyHorpak.com | 1 Dec 2005 05:33

hi everyone

Why this list very quiet?.
No one in this list.

Please feel free to reply to this email if you have additional questions or concerns

ชวน จุดาบุตร 
01-7499093
ติดต่อลงโฆษณา อพาร์ทเมนท์,
แมนชั่น, หอพัก โทร. 01-749-9093, 02-938-8301
************************************************************************
http://www.EasyHorpak.com - แหล่งค้นหาหอพัก, คอนโด,
ที่พัก, อพาร์ทเมนท์ 
http://www.EasyHorpak.com/webdesign - บริการดูแลและออกแบบเว็บไซต์
http://www.EasyHorpak.com/internet -
แหล่งรวมผู้ให้บริการติดตั้งอินเตอร์เน็ตในอพาร์ทเมนท์ 
http://www.EasyHorpak.com/software -
แหล่งรวมโปรแกรมสำหรับอพาร์ทเมนท์ 
http://www.EasyHorpak.com/move - แหล่งรวมผู้ให้บริการขนย้าย
http://www.EasyHorpak.com/coin - แหล่งรวมผู้ให้บริการตู้หยอดเหรียญ
Todd Cary | 1 Dec 2005 05:50

Using POST to pass variables

When I have more than one button on a page, I us what I call a reentrant 
approach.  That is the page calls itself.

If the page is emailer.pgp, the the FORM tag would be

<form method="get" action="emailer.php">

At the top is

<?php
   $send    = $_GET[btnSend];  // Send button pressed
   $cancel  = $_GET[btnCancel];// Cancel is pressed
   $message = $_GET[message];
   if ($send) {
     header("location: send.php?message=" . $message);
   }
   if ($cancel) {
     header("location: index.php");
   }
?>

Is there a better way to do this so I can use a POST form?

Thank you...

Todd

--

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

David Robley | 1 Dec 2005 06:04
Picon
Picon

Re: Using POST to pass variables

Todd Cary wrote:

> When I have more than one button on a page, I us what I call a reentrant
> approach.  That is the page calls itself.
> 
> If the page is emailer.pgp, the the FORM tag would be
> 
> <form method="get" action="emailer.php">
> 
> At the top is
> 
> <?php
>    $send    = $_GET[btnSend];  // Send button pressed
>    $cancel  = $_GET[btnCancel];// Cancel is pressed
>    $message = $_GET[message];
>    if ($send) {
>      header("location: send.php?message=" . $message);
>    }
>    if ($cancel) {
>      header("location: index.php");
>    }
> ?>
> 
> Is there a better way to do this so I can use a POST form?
> 
> Thank you...
> 
> Todd
What about:

(Continue reading)

Fil | 1 Dec 2005 05:58
Picon

$_POST won't work for me


Ladies and Gentlemen,

Thankyou for this opportunity of picking someones brains before I tear 
the place apart.  I am just starting with PHP but have encountered an 
insurmountable hurdle..  I need to work through   HTML form  "posting" 
examples to a PHP script.  ONE STEP after "Hello World"

I have taken the following steps:

1:   My php.ini   (The only one on the system ) is located in /etc/php.ini

Because I am using an above 4.1 version of PHP
I have manually altered the values of

register_globals = On

2: I have repeatedly stopped and restarted Apache webserver.
(Version 2)

3.  I have a "Hello World" HTML - > hello.php  that loads and runs 
succesfully hence I have a valid   Webserver PHP HTML connection with my 
browser.

4. In "Hello World I have taken the liberty of including a  phpinfo()

5. The output of phpinfo()  among others reveals:

post_max_size	8M	8M
precision	14	14
(Continue reading)

EasyHorpak.com | 1 Dec 2005 06:25

Re: Using POST to pass variables

use $_POST[btnSend];  to use post method

----- Original Message ----- 
From: "Todd Cary" <todd <at> aristesoftware.com>
To: <php-general <at> lists.php.net>
Sent: Thursday, December 01, 2005 11:50 AM
Subject: [PHP] Using POST to pass variables

> When I have more than one button on a page, I us what I call a reentrant 
> approach.  That is the page calls itself.
> 
> If the page is emailer.pgp, the the FORM tag would be
> 
> <form method="get" action="emailer.php">
> 
> At the top is
> 
> <?php
>   $send    = $_GET[btnSend];  // Send button pressed
>   $cancel  = $_GET[btnCancel];// Cancel is pressed
>   $message = $_GET[message];
>   if ($send) {
>     header("location: send.php?message=" . $message);
>   }
>   if ($cancel) {
>     header("location: index.php");
>   }
> ?>
> 
> Is there a better way to do this so I can use a POST form?
(Continue reading)

David Robley | 1 Dec 2005 06:34
Picon
Picon

Re: $_POST won't work for me

Fil wrote:

> 
> Ladies and Gentlemen,
> 
> Thankyou for this opportunity of picking someones brains before I tear
> the place apart.  I am just starting with PHP but have encountered an
> insurmountable hurdle..  I need to work through   HTML form  "posting"
> examples to a PHP script.  ONE STEP after "Hello World"
> 
> I have taken the following steps:
> 
> 1:   My php.ini   (The only one on the system ) is located in /etc/php.ini
> 
> Because I am using an above 4.1 version of PHP
> I have manually altered the values of
> 
> register_globals = On
> 
> 2: I have repeatedly stopped and restarted Apache webserver.
> (Version 2)
> 
> 3.  I have a "Hello World" HTML - > hello.php  that loads and runs
> succesfully hence I have a valid   Webserver PHP HTML connection with my
> browser.
> 
> 4. In "Hello World I have taken the liberty of including a  phpinfo()
> 
> 5. The output of phpinfo()  among others reveals:
> 
(Continue reading)

EasyHorpak.com | 1 Dec 2005 06:39

Re: $_POST won't work for me

Could you let me know your OS and Webserver program.
Did you use appserv for begin learn php?

----- Original Message ----- 
From: "Fil" <fil_mat <at> dodo.com.au>
To: <php-general <at> lists.php.net>
Sent: Thursday, December 01, 2005 11:58 AM
Subject: [PHP] $_POST won't work for me

>
> Ladies and Gentlemen,
>
> Thankyou for this opportunity of picking someones brains before I tear the 
> place apart.  I am just starting with PHP but have encountered an 
> insurmountable hurdle..  I need to work through   HTML form  "posting" 
> examples to a PHP script.  ONE STEP after "Hello World"
>
> I have taken the following steps:
>
> 1:   My php.ini   (The only one on the system ) is located in /etc/php.ini
>
> Because I am using an above 4.1 version of PHP
> I have manually altered the values of
>
> register_globals = On
>
> 2: I have repeatedly stopped and restarted Apache webserver.
> (Version 2)
>
> 3.  I have a "Hello World" HTML - > hello.php  that loads and runs 
(Continue reading)

Todd Cary | 1 Dec 2005 07:08

Re: Using POST to pass variables

Except this passes the "message" in the URL.  Is there a way to pass 
variables as a POST (not in the URL)?

I have a class that creates a new socket, however on my client's shared 
server, the creation of sockets is not allowed.  With a new socket, I am 
able to pass the variable information via the socket (POST).

Todd

David Robley wrote:
> Todd Cary wrote:
> 
>> When I have more than one button on a page, I us what I call a reentrant
>> approach.  That is the page calls itself.
>>
>> If the page is emailer.pgp, the the FORM tag would be
>>
>> <form method="get" action="emailer.php">
>>
>> At the top is
>>
>> <?php
>>    $send    = $_GET[btnSend];  // Send button pressed
>>    $cancel  = $_GET[btnCancel];// Cancel is pressed
>>    $message = $_GET[message];
>>    if ($send) {
>>      header("location: send.php?message=" . $message);
>>    }
>>    if ($cancel) {
>>      header("location: index.php");
(Continue reading)

Ian Barnes | 1 Dec 2005 07:42
Favicon

Database Class Help

Hi,

We have a database class that we want to use to connect to multiple
databases at the same time using different variables.

Here is part of the db class:

class db {
  var $dbh = "";
  var $q   = "";

  function db($db_host, $db_user, $db_pass, $db_name) {
    $this->dbh =  <at> mysql_pconnect($db_host, $db_user, $db_pass);
    $this->select_db($db_name);
  }

  function select_db($db) {
    if (! <at> mysql_select_db($db, $this->dbh)) {
      die("<em>Cannot select database because:</em></p>\n<p><code>" .
mysql_error() . "</code>");
    }
  }

  function num_rows($_q) {
    if (!$this->q = mysql_query($_q, $this->dbh)) {
      die("Invalid query \"<code>" . $_q . "</code>\"</p>\n<p><code>" .
mysql_error() . "</code>");
    } else {
      return mysql_num_rows($this->q);
    }
(Continue reading)


Gmane