php-general Digest 25 Aug 2003 19:14:55 -0000 Issue 2258
Topics (messages 160645 through 160677):
Re: Unable to get the values in next page
160645 by: murugesan
160646 by: Cody Phanekham
160654 by: murugesan
160657 by: murugesan
Use PHP or MySQL
160647 by: Sid
include () problems
160648 by: Mjec
160676 by: Jim Lucas
Re: Reading an MS Access Database file on *NIX platform using PHP
160649 by: Ernest E Vogelsinger
160662 by: Wouter van Vliet
ob_start and transparent sessions 4.3.2
160650 by: Miek Lohmann
php5 and mysql
160651 by: Harry Wiens
Window.status message
160652 by: murugesan
window.status
160653 by: murugesan
Problem with date('w')
160655 by: BEOI 7308
160661 by: Danielle van Gladbach
Unix end of line versus windows end of line
160656 by: Bohdan Blaha
[Newbie Guide] For the benefit of new members
160658 by: tech.leatherlink.net
Re: CMS question.
160659 by: Jay Blanchard
160666 by: Edmond Baroud
Re: mail() question
160660 by: Matthias Wulkow
160671 by: Alister
Re: In need of a script
160663 by: Jason Sheets
PHP 4.3.3 released
160664 by: Ilia Alshanetsky
Cookie saving path on Clinet
160665 by: Binay Agarwal
Re: How to open random Flash page with hyperlink?
160667 by: Curt Zirzow
Re: script not terminating on user abort
160668 by: Dennis Jacobfeuerborn
Re: HTML form handling
160669 by: sven
Recursive Object Troubles
160670 by: Joshua Groboski
Session problem in back button
160672 by: murugesan
mysql or php timestamp arithmatic
160673 by: Christian Calloway
Re: Use PHP or MySQL for MD5 function
160674 by: Daevid Vincent
querystring and frameset issue
160675 by: Irvin Amoraal
HIPAA EDI X12 stuff?
160677 by: Richard Lynch
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 ---
Thanks for the reply.Actually I don't know that I have to include the
start_session in every page.
I GOT it ATLAST.
Regards
-murugesan.
----- Original Message -----
From: "Cody Phanekham" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, August 25, 2003 12:26 PM
Subject: [PHP] RE: Unable to get the values in next page
> main.php
> -----------------
> echo $failed;// this is null here
> ----------------->
did you start the session in main.php before "echo $failed;"? eg
<?
session_name("mysessionname");
session_start();
?>
> -----Original Message-----
> From: murugesan [mailto:[EMAIL PROTECTED]
> Sent: Monday, 25 August 2003 16:46
> To: Cody Phanekham; [EMAIL PROTECTED]
> Subject: Unable to get the values in next page
>
>
> I did as what you said. But the problem now is that I am not
> able to get the
> values in the next page.
>
> index.php
> --------------
> session_name("mysessionname");
> session_start();
> --------------->
>
> auth.php
> -----------------
> $failed="yes";
> session_register('failed');
> header ("Location: /main.php");
> ----------------->
>
> main.php
> -----------------
> echo $failed;// this is null here
> ----------------->
>
> What might be the problem ?
>
> Thanks in advance,
> Murugesan.
>
>
>
> > Murugesan,
> >
> > I'll assume your redirecting the user to main.php because
> (s)he has passed
> > the authentication routine... in that case just store the
> username and
> > password as a session variable that way you wont need to
> pass the username
> > and password via the url.
> >
> > auth.php, [just before the call to header()]:
> > <?
> > session_register('empid');
> > session_register('pwd');
> > header ("Location: /main.php");
> > ?>
> >
> > then in main.php you need to start your session to access
> the session
> > variables
> > <?
> > session_name("yoursessionname");
> > session_start();
> > // you now have access to $empid and $pwd
> > echo "<br>your employee id = $empid and the password you typed was
> $pwd";
> > ?>
> >
> >
> > > -----Original Message-----
> > > From: murugesan [mailto:[EMAIL PROTECTED]
> > > Sent: Monday, 25 August 2003 15:18
> > > To: Cody Phanekham; [EMAIL PROTECTED]
> > > Subject: Re: [PHP] How to open random Flash page with hyperlink?
> > >
> > >
> > > Thanks for the information.
> > > In the code you provided
> > >
> > > ----if ((!$passwd) || (!$username)) // user hasnt logged in
> > > {
> > > .....
> > >
> > > Actually I have implemented this in a separate page.
> > >
> > > That is upon sign up of the <form> in the index page
> > > I call a new page auth.php
> > > In that file
> > > I have done this authentication and called the function
> > > header ("Location: /main.php?empid=$empid&pwd=$pwd");
> > >
> > > Actually when passing this URL the password appears in the
> > > address bar.
> > > How to over come this? It will be very much usefull if I get
> > > the answer.
> > >
> > > Thanks in advance
> > > -Murugesan
> > > --------------------------------------------------------------
> > > --------------
> > > --------------------------------------------------------------
> > > --------------
> > > -
> > > Ok lets say you want every user to login before they can
> > > access other parts
> > > of your site.
> > >
> > > index.php:
> > > <?
> > > session_name("mysessionname");
> > > session_start();
> > > session_register("s_authed");
> > > $s_authed = 0; // initialize session flag
> > >
> > > if ((!$passwd) || (!$username)) // user hasnt logged in
> > > {
> > > // display login form
> > > ...
> > > }
> > > else
> > > {
> > > // retrieve database username and password here
> > > ...
> > > // check if they match
> > > if (($db_passwd == $passwd) && ($db_username == $username))
> > > {
> > > $s_authed = 1; // user has been authorised
> > > // redirect to real page
> > > echo "
> > > <script>
> > > window.location='main.php'
> > > </script>";
> > > }
> > > }
> > > ?>
> > >
> > > main.php:
> > > <?
> > > session_name("mysessionname");
> > > session_start();
> > > if (!$s_authed) // check access
> > > {
> > > // user hasnt been authorised, therefore redirect to login page
> > > echo "
> > > <script>
> > > window.location='index.php'
> > > </script>";
> > > }
> > > else
> > > {
> > > // display page
> > > ...
> > > }
> > > ?>
> > >
> > >
> > > if a user tries to access main.php directly without logging
> > > in they will be
> > > redirected to index.php
> > >
> > > checkout http://www.php.net/manual/en/ref.session.php for
> > > more information
> > >
> > >
> > > >
> > > >
> > > > Thanks for the message.
> > > > Can you please tell me how to do session authentication?.
> > > >
> > > > -murugesan
>
****************************************************************************
*********
This e-mail, including any attachments to it, may contain confidential
and/or personal information.
If you have received this e-mail in error, you must not copy, distribute, or
disclose it, use or take any action
based on the information contained within it.
Please notify the sender immediately by return e-mail of the error and then
delete the original e-mail.
The information contained within this e-mail may be solely the opinion of
the sender and may not necessarily
reflect the position, beliefs or opinions of Salmat on any issue.
This email has been swept for the presence of computer viruses known to
Salmat's anti-virus systems.
For more information, visit our website at www.salmat.com.au.
****************************************************************************
*********
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
NP.
You only have to start a session if you want to access any session variable. You could
always including the code in a header.inc file that gets included in every php script,
that way you wont forget to start the session.
> -----Original Message-----
> From: murugesan [mailto:[EMAIL PROTECTED]
> Sent: Monday, 25 August 2003 17:14
> To: Cody Phanekham; [EMAIL PROTECTED]
> Subject: Re: [PHP] RE: Unable to get the values in next page
>
>
> Thanks for the reply.Actually I don't know that I have to include the
> start_session in every page.
> I GOT it ATLAST.
>
> Regards
> -murugesan.
>
>
> ----- Original Message -----
> From: "Cody Phanekham" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Monday, August 25, 2003 12:26 PM
> Subject: [PHP] RE: Unable to get the values in next page
>
>
> > main.php
> > -----------------
> > echo $failed;// this is null here
> > ----------------->
>
> did you start the session in main.php before "echo $failed;"? eg
> <?
> session_name("mysessionname");
> session_start();
> ?>
>
>
> > -----Original Message-----
> > From: murugesan [mailto:[EMAIL PROTECTED]
> > Sent: Monday, 25 August 2003 16:46
> > To: Cody Phanekham; [EMAIL PROTECTED]
> > Subject: Unable to get the values in next page
> >
> >
> > I did as what you said. But the problem now is that I am not
> > able to get the
> > values in the next page.
> >
> > index.php
> > --------------
> > session_name("mysessionname");
> > session_start();
> > --------------->
> >
> > auth.php
> > -----------------
> > $failed="yes";
> > session_register('failed');
> > header ("Location: /main.php");
> > ----------------->
> >
> > main.php
> > -----------------
> > echo $failed;// this is null here
> > ----------------->
> >
> > What might be the problem ?
> >
> > Thanks in advance,
> > Murugesan.
> >
> >
> >
> > > Murugesan,
> > >
> > > I'll assume your redirecting the user to main.php because
> > (s)he has passed
> > > the authentication routine... in that case just store the
> > username and
> > > password as a session variable that way you wont need to
> > pass the username
> > > and password via the url.
> > >
> > > auth.php, [just before the call to header()]:
> > > <?
> > > session_register('empid');
> > > session_register('pwd');
> > > header ("Location: /main.php");
> > > ?>
> > >
> > > then in main.php you need to start your session to access
> > the session
> > > variables
> > > <?
> > > session_name("yoursessionname");
> > > session_start();
> > > // you now have access to $empid and $pwd
> > > echo "<br>your employee id = $empid and the password
> you typed was
> > $pwd";
> > > ?>
> > >
> > >
> > > > -----Original Message-----
> > > > From: murugesan [mailto:[EMAIL PROTECTED]
> > > > Sent: Monday, 25 August 2003 15:18
> > > > To: Cody Phanekham; [EMAIL PROTECTED]
> > > > Subject: Re: [PHP] How to open random Flash page with hyperlink?
> > > >
> > > >
> > > > Thanks for the information.
> > > > In the code you provided
> > > >
> > > > ----if ((!$passwd) || (!$username)) // user hasnt logged in
> > > > {
> > > > .....
> > > >
> > > > Actually I have implemented this in a separate page.
> > > >
> > > > That is upon sign up of the <form> in the index page
> > > > I call a new page auth.php
> > > > In that file
> > > > I have done this authentication and called the function
> > > > header ("Location: /main.php?empid=$empid&pwd=$pwd");
> > > >
> > > > Actually when passing this URL the password appears in the
> > > > address bar.
> > > > How to over come this? It will be very much usefull if I get
> > > > the answer.
> > > >
> > > > Thanks in advance
> > > > -Murugesan
> > > > --------------------------------------------------------------
> > > > --------------
> > > > --------------------------------------------------------------
> > > > --------------
> > > > -
> > > > Ok lets say you want every user to login before they can
> > > > access other parts
> > > > of your site.
> > > >
> > > > index.php:
> > > > <?
> > > > session_name("mysessionname");
> > > > session_start();
> > > > session_register("s_authed");
> > > > $s_authed = 0; // initialize session flag
> > > >
> > > > if ((!$passwd) || (!$username)) // user hasnt logged in
> > > > {
> > > > // display login form
> > > > ...
> > > > }
> > > > else
> > > > {
> > > > // retrieve database username and password here
> > > > ...
> > > > // check if they match
> > > > if (($db_passwd == $passwd) && ($db_username == $username))
> > > > {
> > > > $s_authed = 1; // user has been authorised
> > > > // redirect to real page
> > > > echo "
> > > > <script>
> > > > window.location='main.php'
> > > > </script>";
> > > > }
> > > > }
> > > > ?>
> > > >
> > > > main.php:
> > > > <?
> > > > session_name("mysessionname");
> > > > session_start();
> > > > if (!$s_authed) // check access
> > > > {
> > > > // user hasnt been authorised, therefore redirect to
> login page
> > > > echo "
> > > > <script>
> > > > window.location='index.php'
> > > > </script>";
> > > > }
> > > > else
> > > > {
> > > > // display page
> > > > ...
> > > > }
> > > > ?>
> > > >
> > > >
> > > > if a user tries to access main.php directly without logging
> > > > in they will be
> > > > redirected to index.php
> > > >
> > > > checkout http://www.php.net/manual/en/ref.session.php for
> > > > more information
> > > >
> > > >
> > > > >
> > > > >
> > > > > Thanks for the message.
> > > > > Can you please tell me how to do session authentication?.
> > > > >
> > > > > -murugesan
> >
>
>
> **************************************************************
> **************
> *********
> This e-mail, including any attachments to it, may contain confidential
> and/or personal information.
> If you have received this e-mail in error, you must not copy,
> distribute, or
> disclose it, use or take any action
> based on the information contained within it.
>
> Please notify the sender immediately by return e-mail of the
> error and then
> delete the original e-mail.
>
> The information contained within this e-mail may be solely
> the opinion of
> the sender and may not necessarily
> reflect the position, beliefs or opinions of Salmat on any issue.
>
> This email has been swept for the presence of computer
> viruses known to
> Salmat's anti-virus systems.
>
> For more information, visit our website at www.salmat.com.au.
> **************************************************************
> **************
> *********
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--- End Message ---
--- Begin Message ---
I thought of including the script in all the files.Thanks for the message.
Regards,
Murugesan
----- Original Message -----
From: "Cody Phanekham" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, August 25, 2003 12:50 PM
Subject: RE: [PHP] RE: Unable to get the values in next page
NP.
You only have to start a session if you want to access any session variable.
You could always including the code in a header.inc file that gets included
in every php script, that way you wont forget to start the session.
> -----Original Message-----
> From: murugesan [mailto:[EMAIL PROTECTED]
> Sent: Monday, 25 August 2003 17:14
> To: Cody Phanekham; [EMAIL PROTECTED]
> Subject: Re: [PHP] RE: Unable to get the values in next page
>
>
> Thanks for the reply.Actually I don't know that I have to include the
> start_session in every page.
> I GOT it ATLAST.
>
> Regards
> -murugesan.
>
>
> ----- Original Message -----
> From: "Cody Phanekham" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Monday, August 25, 2003 12:26 PM
> Subject: [PHP] RE: Unable to get the values in next page
>
>
> > main.php
> > -----------------
> > echo $failed;// this is null here
> > ----------------->
>
> did you start the session in main.php before "echo $failed;"? eg
> <?
> session_name("mysessionname");
> session_start();
> ?>
>
>
> > -----Original Message-----
> > From: murugesan [mailto:[EMAIL PROTECTED]
> > Sent: Monday, 25 August 2003 16:46
> > To: Cody Phanekham; [EMAIL PROTECTED]
> > Subject: Unable to get the values in next page
> >
> >
> > I did as what you said. But the problem now is that I am not
> > able to get the
> > values in the next page.
> >
> > index.php
> > --------------
> > session_name("mysessionname");
> > session_start();
> > --------------->
> >
> > auth.php
> > -----------------
> > $failed="yes";
> > session_register('failed');
> > header ("Location: /main.php");
> > ----------------->
> >
> > main.php
> > -----------------
> > echo $failed;// this is null here
> > ----------------->
> >
> > What might be the problem ?
> >
> > Thanks in advance,
> > Murugesan.
> >
> >
> >
> > > Murugesan,
> > >
> > > I'll assume your redirecting the user to main.php because
> > (s)he has passed
> > > the authentication routine... in that case just store the
> > username and
> > > password as a session variable that way you wont need to
> > pass the username
> > > and password via the url.
> > >
> > > auth.php, [just before the call to header()]:
> > > <?
> > > session_register('empid');
> > > session_register('pwd');
> > > header ("Location: /main.php");
> > > ?>
> > >
> > > then in main.php you need to start your session to access
> > the session
> > > variables
> > > <?
> > > session_name("yoursessionname");
> > > session_start();
> > > // you now have access to $empid and $pwd
> > > echo "<br>your employee id = $empid and the password
> you typed was
> > $pwd";
> > > ?>
> > >
> > >
> > > > -----Original Message-----
> > > > From: murugesan [mailto:[EMAIL PROTECTED]
> > > > Sent: Monday, 25 August 2003 15:18
> > > > To: Cody Phanekham; [EMAIL PROTECTED]
> > > > Subject: Re: [PHP] How to open random Flash page with hyperlink?
> > > >
> > > >
> > > > Thanks for the information.
> > > > In the code you provided
> > > >
> > > > ----if ((!$passwd) || (!$username)) // user hasnt logged in
> > > > {
> > > > .....
> > > >
> > > > Actually I have implemented this in a separate page.
> > > >
> > > > That is upon sign up of the <form> in the index page
> > > > I call a new page auth.php
> > > > In that file
> > > > I have done this authentication and called the function
> > > > header ("Location: /main.php?empid=$empid&pwd=$pwd");
> > > >
> > > > Actually when passing this URL the password appears in the
> > > > address bar.
> > > > How to over come this? It will be very much usefull if I get
> > > > the answer.
> > > >
> > > > Thanks in advance
> > > > -Murugesan
> > > > --------------------------------------------------------------
> > > > --------------
> > > > --------------------------------------------------------------
> > > > --------------
> > > > -
> > > > Ok lets say you want every user to login before they can
> > > > access other parts
> > > > of your site.
> > > >
> > > > index.php:
> > > > <?
> > > > session_name("mysessionname");
> > > > session_start();
> > > > session_register("s_authed");
> > > > $s_authed = 0; // initialize session flag
> > > >
> > > > if ((!$passwd) || (!$username)) // user hasnt logged in
> > > > {
> > > > // display login form
> > > > ...
> > > > }
> > > > else
> > > > {
> > > > // retrieve database username and password here
> > > > ...
> > > > // check if they match
> > > > if (($db_passwd == $passwd) && ($db_username == $username))
> > > > {
> > > > $s_authed = 1; // user has been authorised
> > > > // redirect to real page
> > > > echo "
> > > > <script>
> > > > window.location='main.php'
> > > > </script>";
> > > > }
> > > > }
> > > > ?>
> > > >
> > > > main.php:
> > > > <?
> > > > session_name("mysessionname");
> > > > session_start();
> > > > if (!$s_authed) // check access
> > > > {
> > > > // user hasnt been authorised, therefore redirect to
> login page
> > > > echo "
> > > > <script>
> > > > window.location='index.php'
> > > > </script>";
> > > > }
> > > > else
> > > > {
> > > > // display page
> > > > ...
> > > > }
> > > > ?>
> > > >
> > > >
> > > > if a user tries to access main.php directly without logging
> > > > in they will be
> > > > redirected to index.php
> > > >
> > > > checkout http://www.php.net/manual/en/ref.session.php for
> > > > more information
> > > >
> > > >
> > > > >
> > > > >
> > > > > Thanks for the message.
> > > > > Can you please tell me how to do session authentication?.
> > > > >
> > > > > -murugesan
> >
>
>
> **************************************************************
> **************
> *********
> This e-mail, including any attachments to it, may contain confidential
> and/or personal information.
> If you have received this e-mail in error, you must not copy,
> distribute, or
> disclose it, use or take any action
> based on the information contained within it.
>
> Please notify the sender immediately by return e-mail of the
> error and then
> delete the original e-mail.
>
> The information contained within this e-mail may be solely
> the opinion of
> the sender and may not necessarily
> reflect the position, beliefs or opinions of Salmat on any issue.
>
> This email has been swept for the presence of computer
> viruses known to
> Salmat's anti-virus systems.
>
> For more information, visit our website at www.salmat.com.au.
> **************************************************************
> **************
> *********
>
> --
> 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
--- End Message ---
--- Begin Message ---
Thanks for the help.
I got it worked. The mistake I did was that I failed to call session_start()
in the next page.
-Murugesan
----- Original Message -----
From: "Burhan" <[EMAIL PROTECTED]>
To: "murugesan" <[EMAIL PROTECTED]>
Sent: Monday, August 25, 2003 3:29 PM
Subject: Re: [PHP] Unable to get the values in next page
> Quoting murugesan <[EMAIL PROTECTED]>:
>
> [ trim ]
>
> > main.php
> > -----------------
> > echo $failed;// this is null here
> > ----------------->
>
> Try echo $_SESSION['failed'];
>
> --
> Burhan
> phplist[at]meidomus[dot]com
> http://www.meidomus.com
>
--- End Message ---
--- Begin Message ---
Hello,
This question has been lingering in my mind for some time -
Say we have a function such as MD5, which is available on both PHP and MySQL? Which is
faster - the PHP version or the MySQL one. Have any benchmarks been made on this? We
can use the same question for say... arithmetic operations, string contentation...
Thanks in advance.
- Sid
--- End Message ---
--- Begin Message ---
Hi,
When I run the line:
include ("fnord.php");
with the file looking like:
<?php
define ("fnord_included", true);
function fnord ($arg = true) {
// 450 lines
return $msg;
}
?>
it prints out the return of fnord() (i.e. $msg). I've checked, and there's
no echo or print statemetns anywhere...
Oh, yeah, FYI, the pattern goes like this:
file: index.php
<?php include ("standard.php"); /* rest of page */ ?>
file: standard.php
<?php /* a few defines */ include("fnord.php"); /* rest of stuff */ header
("Content-type: text/html; encoding=utf-8"); ?>
and it prints it right up the top of index.php, causing an error with the
"header" statement (although it says the error is in fnord.php - which
contains NO header statemtns).
ideas?
Regards,
mjec
--- End Message ---
--- Begin Message ---
If you are having a problem that tells you that output was displayed on a
given line in a given file. And you found this because after the output you
tried sending headers, then look in that file on that given line, and you
will see the problem.
It could be a simple as a
?>
<?
type break in your code.
If that doesn't work, start by removing all the code in that file and adding
it back peice by peice up until you have your error message. Then you will
know what is causing the problem.
Jim Lucas
----- Original Message -----
From: "Mjec" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, August 25, 2003 12:56 AM
Subject: [PHP] include () problems
> Hi,
>
> When I run the line:
>
> include ("fnord.php");
>
> with the file looking like:
>
> <?php
> define ("fnord_included", true);
> function fnord ($arg = true) {
>
> // 450 lines
> return $msg;
>
> }
> ?>
>
> it prints out the return of fnord() (i.e. $msg). I've checked, and
there's
> no echo or print statemetns anywhere...
>
> Oh, yeah, FYI, the pattern goes like this:
>
> file: index.php
> <?php include ("standard.php"); /* rest of page */ ?>
> file: standard.php
> <?php /* a few defines */ include("fnord.php"); /* rest of stuff */ header
> ("Content-type: text/html; encoding=utf-8"); ?>
>
> and it prints it right up the top of index.php, causing an error with the
> "header" statement (although it says the error is in fnord.php - which
> contains NO header statemtns).
>
> ideas?
>
> Regards,
>
> mjec
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--- End Message ---
--- Begin Message ---
At 03:18 25.08.2003, Weston Cann said:
--------------------[snip]--------------------
>I share a low regard for Access, and I've got a set of standard
>forms/code I use to set up a nice interface to MySQL, and I showed it to
>my friend. He likes that, but there's a problem:
>
>He wants to be able to make changes offline, and then sync up.
>
>This isn't an uncommon desire... I've run into people wanting to do this
>before (with Excel spreadsheets, no less). And in fact, it's probably
>the most convenient way of doing things, as long as they're warned about
>certain dangers (overwrites from competing unsynced database files).
>There's a certain cumbersome nature about web forms and the time delay
>involved in HTTP transactions.
>
>So anyway, that's the motivation for using Access here.
--------------------[snip]--------------------
You could do that without too much effort. Export the data to be synced
from MS Access to a CSV style export format, upload it to the server and
process it. There are a couple of examples how to handle CSV style data on
SourceForge, I believe.
--
>O Ernest E. Vogelsinger
(\) ICQ #13394035
^ http://www.vogelsinger.at/
--- End Message ---
--- Begin Message ---
So, while overnight everybody has said something about this.. Let me add a
few lines. Also because I just want to keep the discussion running, since
I'm having pretty much the same kind of situation.
First of all, what I get fro your description is that your friend wants to
make changes to access 'offline'. That means: when he's not connected to the
server that should parse the MS Access file. Makes me believe that he will
have to upload the Access file to the server which parses it. Even though
there's huge bandwidths nowadays, that's really not what you want for a ms
access file. Those fella's get HUGE.
I'd suggest you use XML for the talking. Haven't tried it yet, but I know
there's VB functions availabel within MS Access to save the data from a
table to XML. Then, almost any language can read PHP and thus parse it.
Other benefits are that there's just one button to click on, and the
interface will create XML files for all of your tables. Those files will
always be smaller than your MS Access file, since the latter also has
queries, forms and a lot of kbytes nobody knows where they come from.
As for what I'm running into is this. The frontend for the database is MS
Access, the data comes from PostgreSQL (using PosgresODBC to connect) and
there are four possible places where the user can access and make changes to
the database.
- 1+2: Connected to the server, using SAMBA to access the filesystem
- 3+4: Locations where there's no internet connection whatsoever whil
editting. Data syncing happens over a swappable harddisk.
Any ideas what might be the best way to handle it. On each location edits
and additions are possible, on data should ever get lost for any reason
thinkable and thus all changes made at any place should get into the main
PostgreSQL server.
Hoping to have helped and to recieve help in return I am saluting you all :D
Wouter
-> -----Oorspronkelijk bericht-----
-> Van: Weston Cann [mailto:[EMAIL PROTECTED]
-> Verzonden: maandag 25 augustus 2003 3:18
-> Aan: [EMAIL PROTECTED]
-> Onderwerp: Re: [PHP] Reading an MS Access Database file on *NIX platform
-> using PHP
->
->
->
-> On Sunday, August 24, 2003, at 05:31 PM, Giz wrote:
->
-> > Access is a pc database. It doesn't run on unix. Why people
-> insist on
-> > beating their heads against the wall in this manner I will never know.
-> > Ignorance I suppose. The alternative is to have your friend use a
-> > relational database and have a few simple forms that will allow him to
-> > insert/update/delete. Best of both worlds, and the open source/free
-> > databases mysql/postgresql are used on thousands of websites
-> every day.
->
-> I share a low regard for Access, and I've got a set of standard
-> forms/code I use to set up a nice interface to MySQL, and I
-> showed it to
-> my friend. He likes that, but there's a problem:
->
-> He wants to be able to make changes offline, and then sync up.
->
-> This isn't an uncommon desire... I've run into people wanting
-> to do this
-> before (with Excel spreadsheets, no less). And in fact, it's probably
-> the most convenient way of doing things, as long as they're
-> warned about
-> certain dangers (overwrites from competing unsynced database files).
-> There's a certain cumbersome nature about web forms and the time delay
-> involved in HTTP transactions.
->
-> So anyway, that's the motivation for using Access here.
->
-> David Otton <[EMAIL PROTECTED]> wrote:
->
-> > Suggestion: go backwards. Set up the data in, say, MySQL with an ODBC
-> > driver, and use Access as a front-end onto that data (Access makes a
-> > good
-> > front-end for manipulating other databases). I've done this with SQL
-> > Server,
-> > but it should be possible with anything that can talk ODBC.
-> >
-> > He gets the interface he's used to, you get a database that can run
-> > under
-> > BSD. Of course, changes will be reflected in the site in real-time,
-> > which
-> > may be a good thing or a bad thing.
-> >
-> > Either that or export the data from Access in a readable format, and
-> > import
-> > it at the other end.
->
-> These ideas might work better; especially the latter. If COM doesn't
-> work under UNIX and ODBC can only talk to FoxPro, Access, and other
-> document (rather than server) oriented databases with the help of some
-> special Win32 control panel/dll, then it would seem that the
-> only way to
-> do offline updates that are then synced would be exporting from Access
-> in some standard format.
->
-> But it seems somewhat odd to me that there aren't any UNIXy (PHP, Perl,
-> something....) for parsing Access files. I know there's a few CPAN
-> modules for Excel, but it's interesting that there's apparently nothing
-> for Access.
->
->
-> ~ == ~
-> http://weston.canncentral.org/
->
-> --
-> PHP General Mailing List (http://www.php.net/)
-> To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
Hi,
I've got a strange problem with enabled transparent sessions for my scripts.
Before upgrading to PHP 4.3.2 I could use output buffering (ob_start()) and
sessions without problems. Meanwhile with this new version the PHPSESSID is
NOT appended to any link like html - tag (a href or something like that).
I found a solution by writing my own session-handling and using regular
expressions to append the session-id to any link, after outputting the
content of the buffer, but this is not a really good solution, I think.
(Btw. session.use_trans_id is on ;))
Has someone found a solution or has had an equal problem with 4.3.2?
Thanks.
Mike
Mike Lohmann
[werk01]
--- End Message ---
--- Begin Message ---
i've got a wamp with php5. is there any possibility to activate or
reinstall, etc. the mysql extension?
--- End Message ---
--- Begin Message ---
Hello all,
I have a proble in showing the window message
[snip]
echo "<a class=MEDIUMFONTB href='/list.php
onmouseover=\"javascript:window.status='hai'\" >Click here </a>";
Here on mouse over it is not displaying hai message in the status bar.
Instead when I move the mouse on the link and then after moving the mouse
apart from the link it displays the hai message in the status bar.
What might be the problem?
-murugesan
--- End Message ---
--- Begin Message ---
Hello all,
I have cleared the stage of changing the window status on mouse over
and on mouse out.
echo "<a href='/list.php' onmouseover=\"window.status=' '; return true;\"
onmouseout=\"window.status=' '; return true;\">Click here</a>";
When I keep on pressing my left mouse button it is displaying the URL in the
status bar.
How to remove the status?
Any one there to help me?
-Murugesan
--- End Message ---
--- Begin Message ---
Hi
I have a problem with the date function
<?
$theday = date("Y-m-d", time());
echo date((w), $theday);
?>
should print 1 if today is monday, 2 if today is tuesday ...
though it's printing 4 and today is monday !
any idea ?
--- End Message ---
--- Begin Message ---
Hi,
Try:
<?
echo date ("w");
?>
Danielle
Beoi 7308 wrote:
> Hi
>
> I have a problem with the date function
>
> <?
> $theday = date("Y-m-d", time());
> echo date((w), $theday);
> ?>
>
> should print 1 if today is monday, 2 if today is tuesday ...
> though it's printing 4 and today is monday !
>
> any idea ?
--- End Message ---
--- Begin Message ---
Hi,
I use PHP with apache on two systems..
(linux and windows)
when I use PHP on linux, it is ok.. I get Unix end of line, when I write to the file
with fwrite function...
when I run the same script on windows machine, I get Unix end of line too, but I need
there windows end of line,...
is it configuration of php.ini?? or how can I set it???
thx for help
BB
---
Odchozí zpráva neobsahuje viry.
Zkontrolováno antivirovým systémem AVG (http://www.grisoft.cz).
Verze: 6.0.512 / Virová báze: 309 - datum vydání: 19.8.2003
--- End Message ---
--- Begin Message ---
=========================================================
This message is for the benefit of new subscribers and those new to PHP.
Those who do not want to be bothered just filter out the [Newbie Guide]
mails. Please feel free to add more points and send to the list.
==========================================================
1. If you have any queries/problems about PHP try http://www.php.net/manual/en
first. You can download a copy and use it offline also.
2. If you can not get answer here try http://www.google.com next. Try
searching for "php YOUR QUERY" and you may be lucky to get an answer within
the first 10 results.
3. Glancing through the list archive at
http://marc.theaimsgroup.com/?l=php-general , you can find many of the
common topics discussed repeatedly and can get your answer from those
discussions.
4. If you are stuck with a script and do not understand what is wrong, instead
of posting the whole script, try doing some research yourself. One useful
trick is to print the variable/sql query using print or echo command and
check whether you get what you expected.
After diagnosing the problem, send the details of your efforts (following
steps 1,2 & 3) and ask for help in the list.
5. Provide a clear descriptive subject line. Avoid general subjects like
"Help!!", "A Question" etc.
6. When you want to start a new topic, open a new mail and enter the mailing
list address [EMAIL PROTECTED] instead of replyting to an existing
thread and replacing the subject and body with your message.
7. PHP is a server side scripting language. Whatever processing PHP does takes
place BEFORE the output reaches the client. Therefore, it is not possible to
access the users' computer related information (OS, screen size etc) using
PHP. You need to go for Java Script and ask the question in a Java Script
list.
Hope you have a good time programming with PHP.
Best regards,
--
Ma Siva Kumar,
================================================
INTEGRATED MANAGEMENT TOOLS FOR LEATHER INDUSTRY
BSG LeatherLink,
Chennai.
Ph: +91 44 55191757
URL : http://www.leatherlink.net
--- End Message ---
--- Begin Message ---
[snip]
I have a friend who have paid a developper to build him a CMS. This
honest
programmer did that (supposedly developped it on his own), encoded the
CMS
with Ioncube and did some other unethical activities as well. To make a
long
story short, I have read some articles about decoding and cracking the
source
/ reverse engineering, and it looks like it is time consuming and also
illegal.
[/snip]
What makes you think that the developer did something unethical?
[snip]
I have taken snapshots of the CMS and put them available to whoever is
interested in giving me a hand to see if this CMS is an open source one?
note the php files: categories_list.php, content_list.php and
content_edit.php.
[/snip]
I have seen those small icons used by numerous developers, but I don't
know if they are available for uncredited or uncompensated works. Other
than that those screenshots look like dozens of packages I have seen.
[snip]
the CM is also capable to upload in batch... ?
[/snip]
Capable to upload what in a batch?
--- End Message ---
--- Begin Message ---
On August 25, 2003 08:13 am, Jay Blanchard wrote:
> What makes you think that the developer did something unethical?
It looks like you're familiar with this particular case and the developper
happens to be your friend so you're defending him?
Anyways, I believe I said "to make a long stroy short". but if you insist on
knowing why I said that he did something unethical (let me add to that
"unprofessional" ); he sold an intellectual property which he was paid to
developpe to competitors in the business.
> I have seen those small icons used by numerous developers, but I don't
> know if they are available for uncredited or uncompensated works. Other
> than that those screenshots look like dozens of packages I have seen.
Thanks for the feedback.
> Capable to upload what in a batch?
Have you ever seen anyone upload bananas or oranges on the net? the most
obvious word that could be placed here is "files", excuse me for forgetting
to mention it!
BTW: thanks for the your time Jay.
Ed.
--
Edmond Baroud
Senior UNIX sysadmin mailto:[EMAIL PROTECTED]
Fingerprint 140F 5FD5 3FDD 45D9 226D 9602 8C3D EAFB 4E19 BEF9
"UNIX is very user friendly, it's just picky about who its friends are."
--- End Message ---
--- Begin Message ---
Hallo Alister,
am Montag, 25. August 2003 um 03:27 hast Du Folgendes gekritzelt:
A> Did you install postfix _after_ PHP? Did you have a sendmail binary in
A> place before you configured PHP? If it's not there are configure time,
A> it won't even compile the 'mail' function.
Yes and there was no sendmail binary before...
A> I've had the same problem before - now that PHP can recognise it's got a
A> way to send email, re-running ./configure / make / make install should
A> work. It did for me.
I did that, but I forgot to do 'make clean'... now it seems to work.
But I have still one question:
when sending mail with this sendmail binary, is it possible to pass
the mail to a local mail server instead of sending it directly to the
recipient? I ask, because I have a mail server in the network
(different machine than the one running the webserver), but I'd like
the mail not to go outside the network (I have no nameserver!)...
[10 minutes later...]
I don't get the error anymore, but no mail has been sent. No errors in
apache-logs... nothing. I'm trying to sniff the network data transfer
with ethereal, but I don't find any connection to any port 25...
In php.ini, I haven't uncomment the sendmail part (sendmail_path =
...) because there is written that default is sendmail -t -i which
should be ok...
SvT
--
Who is the ennemy?
mailto:[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
On Mon, 25 Aug 2003 14:24:25 +0200
Matthias Wulkow <[EMAIL PROTECTED]> wrote:
> A> Did you install postfix _after_ PHP? Did you have a sendmail
> A> binary in place before you configured PHP? If it's not there are
> A> configure time, it won't even compile the 'mail' function.
> Yes and there was no sendmail binary before...
>
> A> I've had the same problem before - now that PHP can recognise it's
> A> got a way to send email, re-running ./configure / make / make
> A> install should work. It did for me.
>
> I did that, but I forgot to do 'make clean'... now it seems to work.
> But I have still one question:
> when sending mail with this sendmail binary, is it possible to pass
> the mail to a local mail server instead of sending it directly to the
> recipient?
Thats a mail configuration issue. Alternatively you can have the send
the email by SMTP to your primary mail server which then sends it on
from there.
Alister
--- End Message ---
--- Begin Message ---
One thing to be aware of, Location: /newpage.php will probably work with
most browsers (I know it works with IE, Mozilla and Opera) but the spec
requires an absolute path to the file you are redirecting to including
protocol, server, path and file. As Wouter demonstrated you should
always die() after a redirect request because it is just that, a request
that the client is not required to follow.
Jason
Wouter van Vliet wrote:
Though no parse error, it can result in an notice about 'undefined index' ..
I'd prefer
<?php
if (isset($_COOKIE['pagename'])) {
header('Location: /newpage.php');
die;
};
?>
Taking care of three things:
- No undifined index notice
- the cookie can also have a value that evaluates to false
- the 'die;' makes sure the script really ends .. sometimes, somehow for
some
undefined reason it does not stop after a header..
Wouter
-> -----Oorspronkelijk bericht-----
-> Van: Curt Zirzow [mailto:[EMAIL PROTECTED]
-> Verzonden: zondag 24 augustus 2003 20:22
-> Aan: [EMAIL PROTECTED]
-> Onderwerp: Re: [PHP] In need of a script
->
->
-> * Thus wrote Stevie D Peele ([EMAIL PROTECTED]):
-> > Heres what I wrote --
-> >
-> > <?php
-> > if ($_COOKIE['pagename'])
-> > {
-> > header('Location: http://www.net-riches.com/800x600.html');
-> > }
-> > ?>
-> >
-> > and I got a parse error on line 4, but I do not see what is
-> wrong on line
-> > 4!
->
-> There is no parse error in that code.
->
-> Curt
-> --
-> "I used to think I was indecisive, but now I'm not so sure."
->
-> --
-> PHP General Mailing List (http://www.php.net/)
-> To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
After a lengthy QA process, PHP 4.3.3 is finally out! This maintenance
release solves a fair number of bugs found in prior PHP versions and
addresses several security issues. All users are *strongly* advised to
upgrade to 4.3.3 as soon as possible.
PHP 4.3.3 contains, among others, following important fixes, additions and
improvements:
* Improved the engine to use POSIX/socket IO where feasible.
* Fixed several potentially hazardous integer and buffer overflows.
* Fixed corruption of multibyte character including 0x5c as second byte in
multipart/form-data.
* Fixed each() to be binary safe for keys.
* Major improvements to the NSAPI SAPI
* Improvements to the IMAP extension
* Improvements to the InterBase extension
* Added DBA handler 'inifile' to support ini files.
* Added long options into CLI & CGI (e.g. --version).
* Added a new parameter to preg_match*() that can be used to specify the
starting offset in the subject string to match from.
* Upgraded the bundled Expat library to version 1.95.6
* Upgraded the bundled PCRE library to version 4.3
* Upgraded the bundled GD library to version GD 2.0.15
* Over 100 various bug fixes!
For a full list of changes in PHP 4.3.2, see the NEWS file.
(http://www.php.net/ChangeLog-4.php#4.3.3).
md5sums:
1171d96104e2ff2cff9e19789a4a1536 php-4.3.3.tar.bz2
fe3fede4115354155fc6185522f7c6b2 php-4.3.3.tar.gz
c3497c394b3f5829136eb2ff614da241 php-4.3.3-Win32.zip
140b98d796e81402776a133f273f0b38 php-4.3.3-installer.exe
Have fun,
Ilia Alshanetsky
[EMAIL PROTECTED]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQE/ShTMLKekh381/CERAn5VAJ9SlW4lGGwGMXGpvs2blhS8R6Sl5ACcCkPV
wWiX4ZLugm1K8xVIj2e0sKo=
=xxIX
-----END PGP SIGNATURE-----
--- End Message ---
--- Begin Message ---
Hi Everybody
I know this is vague but couldn't find the answer.
Where (i mean system path) cookies are saved on Client's machine.
I though it is in windows/temp or temporaray internet files (in win 2000) but it
wasn't there.
Please tell me.
Thanks
Binay
--- End Message ---
--- Begin Message ---
* Thus wrote Cody Phanekham ([EMAIL PROTECTED]):
> Murugesan,
>
> main.php:
> <?
> session_name("mysessionname");
> session_start();
> if (!$s_authed) // check access
> {
> // user hasnt been authorised, therefore redirect to login page
This is exactly why register globals is turned off by default now.
This is a major security hole, I can simply put in the url:
http://host/main.php?s_authed=1
And I would be considered authenticated, throughout the site.
Please turn register_globals off and use the $_SESSION variable to
access your session vars.
Curt
--
"I used to think I was indecisive, but now I'm not so sure."
--- End Message ---
--- Begin Message ---
On Mon, 2003-08-25 at 01:15, Curt Zirzow wrote:
> * Thus wrote Dennis Jacobfeuerborn ([EMAIL PROTECTED]):
> > Hi!
> > The connection_* function don't seem to work for me and I can no longer
> > determine when the user has aborted the script. When I close the browser
> > window the script just keeps running. (see bug #23163)
> >
> > The body of the script essentially looks like this:
> >
> > while( !$done ) {
> > $con->sendMessage("x"); # Send msg to Jabber server
> > sleep(1);
> > }
> >
> > I made an interesting and somewhat weird observation though:
> > If I use the print or echo command in the while-loop once (!) then the
> > script will terminate after the loop has run *exactly* three times after
> > the abort.
> >
> > If I put more than one print/echo in the loop (2->inf) then the script
> > will terminate after *exactly* 2 (!) iterations of the loop after the
> > script has aborted.
>
> how is it your knowing the number of times it is going through the
> loop when the conneciton is aborted?
By counting the number of "x" messages I receive on the other end of the
Jabber connection.
> If you know that the
> connection is aborted why isn't it breaking out of the loop? Do you
> have some code that can show this?
>
this code will just continue to send "x" messages after an abort:
while( !$done ) {
$con->sendMessage("x"); # Send msg to Jabber server
sleep(1);
}
this code will send exactly 3 "x" messages after an abort:
while( !$done ) {
$con->sendMessage("x"); # Send msg to Jabber server
sleep(1);
print "foobar";
}
this code will send exactly 2 "x" messages after an abort:
while( !$done ) {
$con->sendMessage("x"); # Send msg to Jabber server
sleep(1);
print "foobar";
print "foobar"; # any additional number of print/echo commands will
do
}
I hope this helps.
regards,
Dennis
--- End Message ---
--- Begin Message ---
Chris Baxter wrote:
> Hi,
>
> I am trying to send the results of a form to my email account and am
> having difficulty carrying the form variable through if I use an html
> mime type.
>
> Basically, if I send the form using a plain text format, the form
> results are sucessfully copied to the email, however, if I change to
> mime type to HTML (becuase I want to include a company logo and make
> the form a little easier to read by using tabulation and bold text),
> I only seem to get the HTML, not the php variables that carry the
> from info.
>
> Below is an example of the script for the body of the email, which I
> am then sending using the mail() function:
>
> $body = <html>
> <body>
> <table width="85%" border="0" align="center">
> <tr>
> <td width=50%>Applicant 1 Forename:</td>
> <td> <? $App_1_Forename; ?></td>
> </tr>
> <tr>
> <td>Applicant 1 Surname:</td>
> <td> <? $App_1_Surname; ?></td>
> </tr>
> <tr>
> <td>Applicant 2 Forename:</td>
> <td> <? echo $App_2_Forename; ?></td>
> </tr>
> <tr>
> <td>Applicant 2 Surname: </td>
> <td> <? echo $App_2_Surname; ?></td>
> </tr>
> </table>
> </body>
> </html>;
hi chris,
okay, you try to put your html-code into a string '$body', which will be
used by mail().
but, did you look at $body before sending? i'm afraid your vars are already
missing here?
maybe you have to change your code to this:
<?php
$body = '<html>
<body>
<table width="85%" border="0" align="center">
<tr>
<td width="50%">Applicant 1 Forename:</td>
<td>' . $App_1_Forename . '</td> ...';
?>
or this:
<?php
$body = "<html>
<body>
<table width=\"85%\" border=\"0\" align=\"center\">
<tr>
<td width=\"50%\">Applicant 1 Forename:</td>
<td>$App_1_Forename</td> ...";
?>
look at the quotes. which style you want to use depends on you (i prefer the
1st)
ciao SVEN
--- End Message ---
--- Begin Message ---
I am building a recursive Menu object. Inside each menu item there is an array which
should allow me to add submenu items and so on. I am having trouble, though, with
getting the submenus to stay. They are disappearing as I go along.
Here is the menu class: (part of it anyway)
class Menu {
var $iMenuId;
var $iParentId;
var $iMasterId;
var $sMenuName;
var $sMenuType;
var $bStatus;
var $vecMenu; // <- This is the array of submenus which
// will each have their own submenus
function Menu ($iMI, $iPI, $iMstI, $sMN, $sMT, $bS){
$this->iMenuId = $iMI;
$this->iParentId = $iPI;
$this->iMasterId = $iMstI;
$this->sMenuName = $sMN;
$this->sMenuType = $sMT;
$this->bStatus = $bS;
$this->vecMenu = array();
// Used as static variable since PHP4 doesn't support them.
global $menuCount;
$menuCount++;
}
function bIsMaster(){
return ($this->iMasterId == $this->iMenuId);
}
function bIsParent(){
return ($this->iParentId == $this->iMenuId);
}
function bAddMenu(&$m) {
if ($m->bIsParent() && $m->bIsMaster())
return false;
if ($this->iMenuId == $m->iParentId){
$this->vecMenu[] = &$m; // <- This is a guess.
// Added into vector by reference?
return true;
}
for ($i=0; $i < count($this->vecMenu); $i++){
$tmpMenu = $this->vecMenu[$i];
if ($tmpMenu->bAddMenu (&$m))
return true;
}
return false;
}
} //END Menu Class
Should this work? Am I just doing something completely wrong? I know someone out
there knows, please let me know if you have any ideas. I really appreciate any help I
can get.
Thanks in advance.
--
Joshua Groboski
Programmer Analyst
SAVVIS Communications Inc.
http://www.savvis.net
--- End Message ---
--- Begin Message ---
Hello all,
Now i have a problem in back button.
After signing in when I click back button It goes to login page. But
when I click the forward button it is going to the main page.
How can I prevent this.
-murugesan
--- End Message ---
--- Begin Message ---
Hey everyone,
I am writing an application to keep track of employee vacation leave. I have
two timestamp(14) database fields, lets call them start and end, signifying
when start and end of a vacation leave, respectively. What I am trying to do
is get the number of hours between start and end, for example if vacation
started at 12pm on wednesday and ended at 5 pm wednesday, then the total
should be 5 hours (Of course the date ranges are going to be alot more
complicated than that). I attempted to solve this problem in the query,
using the following:
FLOOR((end-start)/3600) as hours
but the values that I am getting are wrong. For example, on what should be a
5 hour span, I am getting back the value 13. Any ideas?
Christian
--- End Message ---
--- Begin Message ---
Well, IMHO it's better to use PHP. My reasoning is this: you want to hit the
db and get out of there as quick as possible since you have limited threads.
Plus, I try to keep my code as db agnostic as possible, so that it's
portable. Having said that, if it's a quick project or something simple, I'd
probably use the mysql version just for the ease of use factor.
If you really care, just make a program like this and do some MD5() calls in
both mysql and php to see which is faster. I'd be curious to know as well...
You'll have to modify appropriately, and only do a single MD5 check because
I think looping 10000 mysql MD5 calls will be slower automatically since
there is the connection to the db and stuff to contend with, so keep that in
mind.
Daevid Vincent
http://daevid.com
--- test ---
<?php
function getmicrotime(){
list($usec, $sec) = explode(" ",microtime());
return ((float)$usec + (float)$sec);
}
$ITERATIONS = 10000;
$time_start = getmicrotime();
for ($i = 1; $i < $ITERATIONS; $i++)
{
?>
blah <?=$i?>
<?php
}
$time_end = getmicrotime();
$time1 = $time_end - $time_start;
$time_start = getmicrotime();
$tf = TRUE;
for ($i = 1; $i < $ITERATIONS; $i++)
{
echo "blah ".$i."\n";
}
$time_end = getmicrotime();
$time2 = $time_end - $time_start;
echo "<P>version one: \t$time1 seconds<P>\n";
echo "version two: \t$time2 seconds<P>\n";
?>
> -----Original Message-----
> From: Sid [mailto:[EMAIL PROTECTED]
> Sent: Monday, August 25, 2003 1:25 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Use PHP or MySQL
>
>
> Hello,
>
> This question has been lingering in my mind for some time -
> Say we have a function such as MD5, which is available on
> both PHP and MySQL? Which is faster - the PHP version or the
> MySQL one. Have any benchmarks been made on this? We can use
> the same question for say... arithmetic operations, string
> contentation...
>
> Thanks in advance.
>
> - Sid
>
--- End Message ---
--- Begin Message ---
Can somebody tell me how to pass a value between two php pages within a
frameset.
I have a simple two column framset: navbar on the left, content on the
right.
I have two pages that are displayed in the content area. Both are PHP pages.
I would like to pass an ID value from the first page(a list page) to the
second (a detail page). I tried renaming the frameset page and associated
links with a php extention but that didn't work.
The link from the list page does contain the ID var in the querystring but
it is not recieved in the display page where I try to echo the querystring
var.
Any ideas?
Does the frameset page need to have a php extention?
Thanks.
Irvin <><
--- End Message ---
--- Begin Message ---
I don't suppose anybody has any HIPAA stuff implementing something like:
ASC X12N 270/271 (004010X092) or its subsequent standards in PHP?...
Email off-list if you have any idea what I'm talking about, since *I*
don't even want to really do this, so I doubt too many others are
interested...
What I *really* want is to just curl POST to their web-server, or
something similar, but I've been bounced through 4 different
departments/people, and am reduced to reading the 270/271 specs for "fun"
while waiting for them to give me a single straight answer.
--
Like Music?
http://l-i-e.com/artists.htm
--- End Message ---