OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
From: php-general-digest-helplists.php.net
Date: Thu Jul 12 2001 - 01:38:38 CDT

  • Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

    php-general Digest 12 Jul 2001 06:38:38 -0000 Issue 750

    Topics (messages 57458 through 57548):

    Re: Running for loop and concat. variables...
            57458 by: Jeff Lewis
            57466 by: scott [gts]

    Re: Mail Bcc to a $variable?
            57459 by: Lasse
            57462 by: Reuben D Budiardja
            57503 by: Lasse

    Re: Variable Next To Variable?
            57460 by: scott [gts]

    Re: Averaging columns in two tables?
            57461 by: Chadwick, Russell

    Re: HTML tags in database fields
            57463 by: scott [gts]
            57464 by: Lasse
            57476 by: Michael J. Seely

    .htaccess php_value
            57465 by: Aaron Bennett
            57468 by: scott [gts]
            57505 by: Brian White

    Re: File Download IE behavior
            57467 by: Bill Rausch

    Cookie Problems with Netscape
            57469 by: david jarvis

    compiling 4.0.6 imap problem
            57470 by: Scott G Mcdaniel

    Back/Forward
            57471 by: Devin Atencio
            57473 by: scott [gts]
            57477 by: Matthew Loff
            57479 by: scott [gts]
            57487 by: Matthew Loff

    Variable next to variable question...
            57472 by: Jeff Lewis

    Re: Speed of loding PHP pages
            57474 by: Aral Balkan
            57519 by: Alex Black

    Fatal error: Call to undefined function: mysql_pconnect() in ...
            57475 by: Tom Beidler
            57478 by: Matthew Loff
            57480 by: scott [gts]
            57482 by: Francis Fillion
            57494 by: Tom Beidler
            57496 by: rm
            57497 by: Chris Anderson

    Trouble with php 4.06 and Apache
            57481 by: Heiko Maiwald
            57485 by: Tyler Longren

    Function? How to find if xy values are within a coordinates of polygon?
            57483 by: SED
            57502 by: Lasse
            57507 by: SED
            57525 by: David Robley

    using GetImageSize in a directory of images
            57484 by: Rory O'Connor
            57486 by: scott [gts]
            57488 by: Matthew Loff

    Where can I download GD 2.0 or later? (php_gd.dll for Win)
            57489 by: SED

    referring url
            57490 by: Joseph Bannon
            57491 by: Alexander Wagner
            57492 by: Boget, Chris

    Re: [correction] Where can I download GD 2.0 or later? (php_gd.dll for Win)
            57493 by: SED
            57495 by: Alexander Wagner

    Warning: mail() is not supported in this PHP build
            57498 by: Kyle
            57531 by: Kyle
            57532 by: Kurt Lieber
            57533 by: Francis Fillion
            57534 by: Kyle
            57537 by: Kent Sandvik
            57541 by: Matthew Loff

    Re: date change for unix platforms on sept 9th
            57499 by: Don Read

    php mail form with predefined subject
            57500 by: Ed Peddycoart
            57528 by: David Robley

    Popquiz...
            57501 by: Lasse

    I'm puzzled. TEXTAREA related.
            57504 by: Chris Cocuzzo
            57529 by: David Robley

    How do I get PHP's User-Agent?
            57506 by: Nathan
            57510 by: Philip Hallstrom
            57511 by: Francis Fillion
            57512 by: Philip Hallstrom
            57514 by: Francis Fillion

    Re: PHP Conference in California
            57508 by: Uri Even-Chen

    PHP Training Course available
            57509 by: Michael Kimsal

    mail() function 30minute delay??
            57513 by: Ben Rigby
            57522 by: Matthew Loff

    Re: Rename a File?
            57515 by: Alex Black
            57516 by: Jason Murray
            57517 by: Philip Hallstrom
            57520 by: Kent Sandvik
            57548 by: Adrian Ciutureanu

    Re: XSLT compiler for PHP
            57518 by: Alex Black

    Re: IE cookies don't expire!
            57521 by: Jason Murray

    Security and Cookies
            57523 by: Steph
            57524 by: Steph
            57526 by: Craig Vincent

    Re: Downloading Data from Database
            57527 by: David Robley

    Problems with mail() function
            57530 by: rodrigo

    php ad banner rotation
            57535 by: Jack
            57536 by: Kurt Lieber

    Alternative to phpMyAdmin
            57538 by: Steph
            57544 by: Andras Kende
            57545 by: Steph

    Journal.php
            57539 by: Joe Ace
            57546 by: zerosumzero.yahoo.com
            57547 by: zerosumzero.yahoo.com

    Re: What the heck is this
            57540 by: Christian Reiniger

    charset
            57542 by: Mark Lo
            57543 by: Mark Lo

    Administrivia:

    To subscribe to the digest, e-mail:
            php-general-digest-subscribelists.php.net

    To unsubscribe from the digest, e-mail:
            php-general-digest-unsubscribelists.php.net

    To post to the list, e-mail:
            php-generallists.php.net

    ----------------------------------------------------------------------

    attached mail follows:


    That gives the following error which is the isset line:

    Parse error: parse error, expecting `','' or `')''
    ----- Original Message -----
    From: "Matthew Luchak" <MLuchakKaydara.com>
    To: "Jeff Lewis" <jeffhyrum.net>; <php-generallists.php.net>
    Sent: Wednesday, July 11, 2001 2:14 PM
    Subject: RE: [PHP] Running for loop and concat. variables...

    I think using isset should do it. try:

    for ($i = 0; $i <= $ffromx; $i++) {
       if (isset($ffrom.$i)){
           echo $ffrom.$i."<BR>";}
    }

    ____________________________
    Matthew Luchak
    Webmaster
    Kaydara Inc.
    mluchakkaydara.com

    -----Original Message-----
    From: Jeff Lewis [mailto:jeffhyrum.net]
    Sent: Wednesday, July 11, 2001 2:15 PM
    To: php-generallists.php.net
    Subject: [PHP] Running for loop and concat. variables...

    I have a page with about 80 checkboxes on it. The values are names and
    my users are to select names. Now on the next step I want to be able to
    list all names processed. I thought a for loop would be best but am
    having problems. $ffromx is the number of checkboxes generated in the
    previous step. So I want to step through each to make sure that they
    were checked or not and then display them.

    for ($i = 0; $i <= $ffromx; $i++) {
       if ($ffrom.$i){
           echo $ffrom.$i."<BR>";}
    }

    attached mail follows:


    this is like the last post on form submissions with
    individually numbered elements...

    if you can use an array, you should... it'll
    make things easier for you in the long run.

    > -----Original Message-----
    > From: Jeff Lewis [mailto:jeffhyrum.net]
    > Sent: Wednesday, July 11, 2001 2:15 PM
    > To: php-generallists.php.net
    > Subject: [PHP] Running for loop and concat. variables...
    >
    >
    > I have a page with about 80 checkboxes on it. The values are names and my
    > users are to select names. Now on the next step I want to be able to list
    > all names processed. I thought a for loop would be best but am having
    > problems. $ffromx is the number of checkboxes generated in the previous
    > step. So I want to step through each to make sure that they were checked
    > or not and then display them.
    >
    > for ($i = 0; $i <= $ffromx; $i++) {
    > if ($ffrom.$i){
    > echo $ffrom.$i."<BR>";}
    > }
    >

    attached mail follows:


    I don't think variable substitution works within quotes when not used with
    echo...

    Try (I think you also a space after BCC:)

    > $headers = "From: Me <memy.com>\nBCC: ".$recipients;

    instead of

    > $headers = "From: Me <memy.com>\nBCC:$recipients";

    and you should be fine....

    Are $recipients ;-seperated properly?

    --
    Lasse
    

    "Marcus James Christian" <marcusmjchristianunlimited.com> wrote in message news:3B4C899D.558C198Bmjchristianunlimited.com... > Hello, > > Ok I've got a script going to a Bcc but can't seem to get it to work > when it's like this? > > <?php > include("mailinglist.inc"); > $recipients = "mailinglist.inc"; > $headers = "From: Me <memy.com>\nBCC:$recipients"; > > include("password.inc"); > if($mailusername == $username && $mailpassword == $password); > { > mail($to, $subject, $bodytext, $headers); > }; > > ?> > > > So how do I get mail to Bcc a variable like $recipients? Recipients > being a huge text file of hundreds of email addy's. > > -Marcus > > -- > Marcus James Christian - UNLIMITED - > Multimedia Internet Design > http://mjchristianunlimited.com > > Proudly presents the music of CHROMATICUS > at http://chromaticus.com > and http://artists.mp3s.com/artists/275/chromaticus.html > >

    attached mail follows:


    your $recipients only containt the string "mailinglist.inc", it does not contain the e-mail addresses, so the bcc is sent to the mailinglist.inc, which is a non-existent address.

    Basically, your header should looks like: From:memy.com\nBcc:me2my.com,me3my.com\n etc.

    echo your header in <PRE> to see it if you miss any new line, etc.

    Reuben D. Budiardja

    On Wednesday 11 July 2001 12:15 pm, Marcus James Christian wrote: > Hello, > > Ok I've got a script going to a Bcc but can't seem to get it to work > when it's like this? > > <?php > include("mailinglist.inc"); > $recipients = "mailinglist.inc"; > $headers = "From: Me <memy.com>\nBCC:$recipients"; > > include("password.inc"); > if($mailusername == $username && $mailpassword == $password); > { > mail($to, $subject, $bodytext, $headers); > }; > > ?> > > > So how do I get mail to Bcc a variable like $recipients? Recipients > being a huge text file of hundreds of email addy's. > > -Marcus > > -- > Marcus James Christian - UNLIMITED - > Multimedia Internet Design > http://mjchristianunlimited.com > > Proudly presents the music of CHROMATICUS > at http://chromaticus.com > and http://artists.mp3s.com/artists/275/chromaticus.html

    attached mail follows:


    "Reuben D Budiardja" <reubendbgoshen.edu> wrote in message news:01071113310201.15071devcorps2.goshen.edu... > your $recipients only containt the string "mailinglist.inc", it does not > contain the e-mail addresses, so the bcc is sent to the mailinglist.inc, > which is a non-existent address.

    DOH! Missed that one... :-)

    --
    Lasse
    

    attached mail follows:


    personally, that's what i would do.

    dealing with arrays usually makes the code a lot cleaner and easier to follow than using awkward constructs like ${$C_Last}{$i}

    and besides, if you ever wanted to expand your code, you could easily pass the entire array to a function like so: children( $C_Last );

    if you used individual variables, you could not do that in any easy or efficient way.

    > -----Original Message----- > From: Jeff Oien [mailto:jeffwebdesigns1.com] > Sent: Wednesday, July 11, 2001 1:29 PM > To: PHP > Subject: FW: [PHP] Variable Next To Variable? > > > What I'm doing is having a form page ask, "How many > children do you want to sign up?" Then it spits out form > fields for as many children as they asked for. So each > field has name="C_Last_Name$x" and $x in incremented > for each child. Should I make it name="C_Last_Name[$x]" ? > Jeff Oien > > > you should change the form field names to > > $Children_Last[1], $Children_Last[2] > > instead of hardcoding $Children_Last1 > > to make iteration thru the form easier > > and handling of the data easier... > > > > you can handle it all like this: > > > > $Number_Children = 5; > > $i = $Number_Children; > > while ($i--) { > > if (! $Children_Last[$i]) { > > // code > > } > > } > > > > > -----Original Message----- > > > From: Jeff Oien [mailto:jeffwebdesigns1.com] > > > Subject: [PHP] Variable Next To Variable? > > > > > > > > > Sorry if this has been brought up 100 times. > > > I want to do this: > > > > > > $y = "1"; > > > > > > while ($y <= "$Number_Children") { > > > if (!$C_Last_Name$y) { > > > error stuff; > > > $y++; > > > } > > > } > > > > > > The form submitting information to this code has field name like > > > C_Last_Name1 C_Last_Name2 depending on how many Children > > > are signing up for something. So I need $y to represent the number. > > > > > > Hope that makes sense. Thanks for any help. > > > Jeff Oien > > > > > > -- > > > PHP General Mailing List (http://www.php.net/) > > > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > > > For additional commands, e-mail: php-general-helplists.php.net > > > To contact the list administrators, e-mail: php-list-adminlists.php.net > > > > > > > -- > > PHP General Mailing List (http://www.php.net/) > > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > > For additional commands, e-mail: php-general-helplists.php.net > > To contact the list administrators, e-mail: php-list-adminlists.php.net > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    attached mail follows:


    SELECT round((hitters.age+pitchers.age) / 2) as avg_age ...

    -----Original Message----- From: Jeff Lewis [mailto:jeffhyrum.net] Sent: Wednesday, July 11, 2001 11:25 AM To: php-generallists.php.net Subject: [PHP] Averaging columns in two tables?

    Is it possible to get the average of two tables. I have an age column in two tables. I can get the age average for one table both can the average of both tables be found in one statement? One table is for hitters, the other for pitchers.

    Jeff

    attached mail follows:


    or throw in the needed number of closing tags at the end of that specific message...

    > -----Original Message----- > From: Matthew Luchak [mailto:MLuchakKaydara.com] > Sent: Wednesday, July 11, 2001 2:09 PM > To: php php > Subject: RE: [PHP] HTML tags in database fields > > > > sure. Quick and dirty is to count all the '<whatever>' tags and compare > this to the number of '</whatever>' tags. If the number doesn't match > up spit out a message saying "Sorry, I can't complete your request you > have $countopen - $countclose $whatever tags not closed". Also check > for the reverse; closed but not opened tags... > ____________________________ > Matthew Luchak > Webmaster > Kaydara Inc. > mluchakkaydara.com > > > > > > Hello. I wrote a comments application that allows the use of some HTML > tags for text formatting (<i><b>). I ran into a problem of users not > closing the tags (</i></b>), so when I display a page with all the > comments, if the user did not close the <b> tag then all the text in the > other comments is bold. > > Is there a solution to this? > > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    attached mail follows:


    "Rodrigo" <rodrigoshreve.net> wrote in message news:3B4C948D.A6F93013shreve.net... > Hello. I wrote a comments application that allows the use of some HTML > tags for text formatting (<i><b>). I ran into a problem of users not > closing the tags (</i></b>), so when I display a page with all the > comments, if the user did not close the <b> tag then all the text in the > other comments is bold. > > Is there a solution to this?

    I'd just check for open tags on form submit, and then bitch and moan about it if there are any... (e.g. leave it up to the user...)

    With a good contains_open_tags() function you'll also be able to accept more tags like TABLE and DIV (with some attribute filtering) since their (more or less) unlikely to cause trouble as long as their properly closed...

    --
    Lasse
    

    attached mail follows:


    HI I know this isn't elegant but it will work. Just put in extra close tags after the field input. </I></I></B></B></FONT> etc. Browsers will ignore the extra close tags.

    >Hello. I wrote a comments application that allows the use of some HTML >tags for text formatting (<i><b>). I ran into a problem of users not >closing the tags (</i></b>), so when I display a page with all the >comments, if the user did not close the <b> tag then all the text in the >other comments is bold. > >Is there a solution to this? >-- >************************************ >Ivan R. Quintero E.* (507)228-3477 >Aptdo 1263 * (507)228-9105 >Balboa, Ancon * 612-1103 >Republic of Panama * >************************************ > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, e-mail: php-general-unsubscribelists.php.net >For additional commands, e-mail: php-general-helplists.php.net >To contact the list administrators, e-mail: php-list-adminlists.php.net

    -- 
    

    _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ Michael Seely 408-777-9949

    attached mail follows:


    Hi There, I currently use .htaccess files to override the include path, which works great for me... One of my concerns was the portability of the code, and the possibility of not having control of http.conf....

    I'm now in the process of porting some of the sites onto a winnt architecure (but still using apache as my webserver...). The contents of some of these .htaccess files looks simelar to:

    php_value include_path ".:/home/www/htdocs/php-lib:/home/www/htdocs/includes"

    unfortunatly, apache for windows would prefer the format somewhat like:

    php_value include_path ".;c:\web\site\php-lib;c:\php\whatever\includes"

    (note the use of ';' rather than ':' as well)

    So my question, is whats the best way to make the site's as portable as can be? I assume that i could go thru _all_ the code and make include references relative rather than relying on the config to find include()'s.... Any suggestions?

    --
    Aaron Bennett
    abennettliquidstudio.com
    

    attached mail follows:


    making them relative is probably the best option for portability and maintainability...

    that way, you can change the underlying directory structure and not have to change any of the actual code... it's great if you ever have to change servers, or if the directory structure undergoes any structural changes in the future.

    > -----Original Message----- > From: Aaron Bennett [mailto:abennettliquidstudio.com] > Sent: Wednesday, July 11, 2001 2:33 PM > To: php > Subject: [PHP] .htaccess php_value > > > Hi There, > I currently use .htaccess files to override the include path, which works > great for me... One of my concerns was the portability of the code, and the > possibility of not having control of http.conf.... > > I'm now in the process of porting some of the sites onto a winnt architecure > (but still using apache as my webserver...). The contents of some of these > .htaccess files looks simelar to: > > php_value include_path > ".:/home/www/htdocs/php-lib:/home/www/htdocs/includes" > > unfortunatly, apache for windows would prefer the format somewhat like: > > php_value include_path ".;c:\web\site\php-lib;c:\php\whatever\includes" > > (note the use of ';' rather than ':' as well) > > So my question, is whats the best way to make the site's as portable as can > be? I assume that i could go thru _all_ the code and make include references > relative rather than relying on the config to find include()'s.... Any > suggestions? > > -- > Aaron Bennett > abennettliquidstudio.com > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    attached mail follows:


    I am still learning about .htaccess files - what you suggested could be useful to me.

    The approach I have taken is to use the auto_prepend feature, namely

    php_value auto_prepend_file "/path/to/autoprepend.php"

    This is then a single hook, and the contents of autoprepend.php can then be as complex as you like.

    Regs

    Brian

    At 11:33 11/07/2001 -0700, Aaron Bennett wrote: >Hi There, > I currently use .htaccess files to override the include path, which works >great for me... One of my concerns was the portability of the code, and the >possibility of not having control of http.conf.... > >I'm now in the process of porting some of the sites onto a winnt architecure >(but still using apache as my webserver...). The contents of some of these >.htaccess files looks simelar to: > >php_value include_path >".:/home/www/htdocs/php-lib:/home/www/htdocs/includes" > >unfortunatly, apache for windows would prefer the format somewhat like: > >php_value include_path ".;c:\web\site\php-lib;c:\php\whatever\includes" > >(note the use of ';' rather than ':' as well) > >So my question, is whats the best way to make the site's as portable as can >be? I assume that i could go thru _all_ the code and make include references >relative rather than relying on the config to find include()'s.... Any >suggestions? > >-- >Aaron Bennett >abennettliquidstudio.com > > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, e-mail: php-general-unsubscribelists.php.net >For additional commands, e-mail: php-general-helplists.php.net >To contact the list administrators, e-mail: php-list-adminlists.php.net

    ------------------------- Brian White Step Two Designs Pty Ltd - SGML, XML & HTML Consultancy Phone: +612-93197901 Web: http://www.steptwo.com.au/ Email: bwhitesteptwo.com.au

    attached mail follows:


    "Warren Vail" <warrenavailabletech.com> said: > >When generating a download file from PHP to IE (Netscape is not used by my >client base) the browser prompts with an option to download the file or open >the file where it is. Opening the file fails and I am forced to download >the file to my local drive before receiving another prompt to open the file >where the second Open works just fine. > >Is there a way to allow this first open to work, or cause the open option on >the first download window to be removed?

    I've spent time fiddled with this stuff a few months ago and came up with the following.

    The basic sequence of commands that I use is that I use look like: $x = array(); $x = stat( "simple.pdf" ); header( "Content-Length: " . $x[7] ); ^ header( "Accept-Ranges: bytes" ); header( "Connection: close" ); header( "Content-Type: application/pdf" ); readfile( "simple.pdf" );

    Also, a php.ini setting of interest is:

    session.cache_limiter =

    Depending on SSL, cookies, and other things you might need to set this to either nothing at all or to public.

    -- 
      Bill Rausch, Software Development, Unix, Mac, Windows
      Numerical Applications, Inc.  509-943-0861   billnumerical.com
    

    attached mail follows:


    Hi all, I have a line that deletes a previously set cookie: setcookie("membership","",time()-86400); That line works fine in IE, but doesn't delete the cookie in Netscape (both Mac and Linux).

    On a side note, both IE and Netscape do not pop up a warning when the cookie is being sent. Since it works in IE I guess it just doesn't warn you since its deleting a cookie not placing one, but maybe in Netscape its not working at all?

    attached mail follows:


    Dear Everyone,

    I'm sure you have already seen this problem a thousand times before; however, I can't find the answer.

    I'm trying to compile php 4.0.6 with imap support and get the module to work with apache. Everything compiles fine; however, a restart of apache gives... Starting httpd: Syntax error on line 260 of /etc/httpd/conf/httpd.conf: Cannot load /etc/httpd/modules/libphp4.so into server: /etc/httpd/modules/libphp4.so: undefined symbol: mxdriver

    The system is: Redhat 7.1 Intel with 'EVERYTHING' installed Redhat's Apache 1.3.19 (rpm installed) Redhat's IMAP-2000-9 (rpm installed) all Redhat RPM PHP rpms have been uninstalled When trying to compile php, I run ./configure --with-mysql --with-apxs --with-imap

    after doing the make ; make install, and try to reload apache, I get the error. If I leave Imap support out, php works excellent. Unfortunately, I really need the imap support for a web-mail application.

    Any assistance would be of great help! If I can keep the Redhat Apache, I would really like to since it already does everything I need.

    Sincerely, Scott

    ================------------------------- Scott McDaniel System Administrator E: scotteng.auburn.edu Engineering Network Services W: 334-844-2202 Auburn University IM: Penguin0600 ================-------------------------

    attached mail follows:


    I have a page that brings up the info on a rock, I wanted to add the functionality of doing like a <next> and <previous> option to go thru all the rocks in my database. I can't figure out how to exactly do this, could someone give me some help?

    attached mail follows:


    how do you have the data stored? by ID number?

    if you have it stored by ID number, just put next/back links something like this:

    <? // here, find out the max number of rocks $prev = (($id>0)? $id-1 : 0 ); $next = (($id<$max)? $id+1 : $max ); ?>

    <A HREF="rock.php?id=<?= $prev ?>">previous</A> <A HREF="rock.php?id=<?= $next ?>">next</A>

    > -----Original Message----- > From: Devin Atencio [mailto:dreamboyaros.net] > Sent: Wednesday, July 11, 2001 2:53 PM > To: php-generallists.php.net > Subject: [PHP] Back/Forward > > > > I have a page that brings up the info on a rock, I wanted to > add the functionality of doing like a <next> and <previous> option > to go thru all the rocks in my database. I can't figure out how > to exactly do this, could someone give me some help? > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    attached mail follows:


    Since IDs can disappear when records are delted, I think it's best to do a COUNT() first, then retrieve your listings with

    SELECT * FROM table WHERE blah LIMIT offset,number_to_retrieve;

    -----Original Message----- From: scott [gts] [mailto:scottgraphictype.com] Sent: Wednesday, July 11, 2001 2:55 PM To: php Subject: RE: [PHP] Back/Forward

    how do you have the data stored? by ID number?

    if you have it stored by ID number, just put next/back links something like this:

    <? // here, find out the max number of rocks $prev = (($id>0)? $id-1 : 0 ); $next = (($id<$max)? $id+1 : $max ); ?>

    <A HREF="rock.php?id=<?= $prev ?>">previous</A> <A HREF="rock.php?id=<?= $next ?>">next</A>

    > -----Original Message----- > From: Devin Atencio [mailto:dreamboyaros.net] > Sent: Wednesday, July 11, 2001 2:53 PM > To: php-generallists.php.net > Subject: [PHP] Back/Forward > > > > I have a page that brings up the info on a rock, I wanted to add the > functionality of doing like a <next> and <previous> option to go thru > all the rocks in my database. I can't figure out how to exactly do > this, could someone give me some help? > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    -- 
    PHP General Mailing List (http://www.php.net/)
    To unsubscribe, e-mail: php-general-unsubscribelists.php.net
    For additional commands, e-mail: php-general-helplists.php.net
    To contact the list administrators, e-mail: php-list-adminlists.php.net
    

    attached mail follows:


    ah yes... that was my quick-n-dirty way ;)

    you could also do it this way:

    file.php?id=1&act=next

    if ($act eq 'next') { $sql = "SELECT id FROM table WHERE id > '$id' LIMIT 1"; } elsif ($act eq 'prev') { $sql = "SELECT id FROM table WHERE id < '$id' LIMIT 1"; }

    but that's also a quick-n-dirty way, becuase it doesnt know when the first/last record is...

    however, that's less quick and less dirty than the original code i posted....

    TIMTOWTDI - there's more than one way to do it. :)

    > -----Original Message----- > From: Matthew Loff [mailto:mattwilletts.com] > Sent: Wednesday, July 11, 2001 3:59 PM > To: 'scott [gts]'; 'php' > Subject: RE: [PHP] Back/Forward > > > > > Since IDs can disappear when records are delted, I think it's best to do > a COUNT() first, then retrieve your listings with > > SELECT * FROM table WHERE blah LIMIT offset,number_to_retrieve; > > > -----Original Message----- > From: scott [gts] [mailto:scottgraphictype.com] > Sent: Wednesday, July 11, 2001 2:55 PM > To: php > Subject: RE: [PHP] Back/Forward > > > how do you have the data stored? > by ID number? > > if you have it stored by ID number, just > put next/back links something like this: > > <? > // here, find out the max number of rocks > $prev = (($id>0)? $id-1 : 0 ); > $next = (($id<$max)? $id+1 : $max ); > ?> > > <A HREF="rock.php?id=<?= $prev ?>">previous</A> > <A HREF="rock.php?id=<?= $next ?>">next</A> > > > > > -----Original Message----- > > From: Devin Atencio [mailto:dreamboyaros.net] > > Sent: Wednesday, July 11, 2001 2:53 PM > > To: php-generallists.php.net > > Subject: [PHP] Back/Forward > > > > > > > > I have a page that brings up the info on a rock, I wanted to add the > > functionality of doing like a <next> and <previous> option to go thru > > all the rocks in my database. I can't figure out how to exactly do > > this, could someone give me some help? > > > > > > -- > > PHP General Mailing List (http://www.php.net/) > > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > > For additional commands, e-mail: php-general-helplists.php.net > > To contact the list administrators, e-mail: > php-list-adminlists.php.net > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    attached mail follows:


    Oh! My mistake... I thought he was retrieving several listings at a time...

    If he's doing a single record each page, your method is definitely the best that I can think of. :)

    -----Original Message----- From: scott [gts] [mailto:scottgraphictype.com] Sent: Wednesday, July 11, 2001 3:58 PM To: php Subject: RE: [PHP] Back/Forward

    ah yes... that was my quick-n-dirty way ;)

    you could also do it this way:

    file.php?id=1&act=next

    if ($act eq 'next') { $sql = "SELECT id FROM table WHERE id > '$id' LIMIT 1"; } elsif ($act eq 'prev') { $sql = "SELECT id FROM table WHERE id < '$id' LIMIT 1"; }

    but that's also a quick-n-dirty way, becuase it doesnt know when the first/last record is...

    however, that's less quick and less dirty than the original code i posted....

    TIMTOWTDI - there's more than one way to do it. :)

    > -----Original Message----- > From: Matthew Loff [mailto:mattwilletts.com] > Sent: Wednesday, July 11, 2001 3:59 PM > To: 'scott [gts]'; 'php' > Subject: RE: [PHP] Back/Forward > > > > > Since IDs can disappear when records are delted, I think it's best to > do a COUNT() first, then retrieve your listings with > > SELECT * FROM table WHERE blah LIMIT offset,number_to_retrieve; > > > -----Original Message----- > From: scott [gts] [mailto:scottgraphictype.com] > Sent: Wednesday, July 11, 2001 2:55 PM > To: php > Subject: RE: [PHP] Back/Forward > > > how do you have the data stored? > by ID number? > > if you have it stored by ID number, just > put next/back links something like this: > > <? > // here, find out the max number of rocks > $prev = (($id>0)? $id-1 : 0 ); > $next = (($id<$max)? $id+1 : $max ); > ?> > > <A HREF="rock.php?id=<?= $prev ?>">previous</A> > <A HREF="rock.php?id=<?= $next ?>">next</A> > > > > > -----Original Message----- > > From: Devin Atencio [mailto:dreamboyaros.net] > > Sent: Wednesday, July 11, 2001 2:53 PM > > To: php-generallists.php.net > > Subject: [PHP] Back/Forward > > > > > > > > I have a page that brings up the info on a rock, I wanted to add the > > functionality of doing like a <next> and <previous> option to go thru > > all the rocks in my database. I can't figure out how to exactly do > > this, could someone give me some help? > > > > > > -- > > PHP General Mailing List (http://www.php.net/) > > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > > For additional commands, e-mail: php-general-helplists.php.net To > > contact the list administrators, e-mail: > php-list-adminlists.php.net > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    -- 
    PHP General Mailing List (http://www.php.net/)
    To unsubscribe, e-mail: php-general-unsubscribelists.php.net
    For additional commands, e-mail: php-general-helplists.php.net
    To contact the list administrators, e-mail: php-list-adminlists.php.net
    

    attached mail follows:


    Looks like I should have been keeping a close eye on that thread... I am pulling fields from a database and displaying them on my page. I am adding a checkbox next to the name and storing the name in the checkbox value. Anyway, on submission I want to process them but am having problems...

    <? $tox=0; $fromx=0; while(($row = mysql_fetch_object($to_bat_result))){ $to_bat_position=$row->position; $to_bat_name=$row->name; $to_bat_ch=$row->ch; $to_bat_ph=$row->ph; $to_bat_sp=$row->sp; $to_bat_age=$row->age; $tox=$tox+1; echo '<tr><td><input type="checkbox" name="$to['.$tox.']" value="'.$to_bat_name.'"></td><td>'.$to_bat_position.'</td><td>'.$to_bat_name.'</td><td>'.$to_bat_ch.'</td><td>'.$to_bat_ph.'</td><td>'.$to_bat_sp.'</td><td>'.$to_bat_age.'</td></tr>'; }

    attached mail follows:


    >> Netscape is notoriously slug-like when it comes to loading large tables (i.e. the output of phpinfo()).

    A way around this is to break up large tables into numerous smaller ones (or at least have one table at the top that displays something so that the user doesn't think that things have gone awry).

    Personally, I couldn't be happier that Netscape won't be making browsers anymore and I wish that trouble-some bug of an excuse for a browser would just go away :)

    Aral ______________________________ (aralkismia.com) New Media Producer, Kismia, Inc. (aralamerican.edu) Adj. Prof., American University ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ

    attached mail follows:


    that has nothing to do with php.

    it's that netscape is crap at rendering large tables, whereas IE is amazingly good. :)

    -a

    in article 3B4C8334.1640698Alclcan.com, Don at donlclcan.com wrote on 7/11/01 9:47 AM:

    > Hi, > > Has anyone tries any test loading PHP pages into IE 5.x and Netscape > 4.7x? > > As an experiment, I have a page that issues a phpinfo(). WIth I.E. 5.5, > it takes about 3 seconds. With Netscape 4.77, it takes almost 20 > seconds. > > Thanks, > Don >

    attached mail follows:


    I'm working with an new ISP and I'm having trouble connecting to MySQL through PHP 4.

    Here's some server specifics; PHP Version 4.0.4pl1 Apache/1.3.14

    DBA support enabled Supported handlers gdbm db2 db3

    I'm getting the following error;

    Fatal error: Call to undefined function: mysql_pconnect() in /home/... on line 5

    Line 5 is;

    $connection = mysql_pconnect("localhost","myuserid","mypass")

    It's a new box so I'm assuming it's something in the configuration. I don't have access to the server so I'm trying to troubleshoot for the ISP. Any help would be greatly appreciated.

    Thanks, Tom

    attached mail follows:


    Have you tried a non-persistant connection? Does that work?

    mysql_connect()?

    -----Original Message----- From: Tom Beidler [mailto:tomorbittechservices.com] Sent: Wednesday, July 11, 2001 3:12 PM To: php list Subject: [PHP] Fatal error: Call to undefined function: mysql_pconnect() in ...

    I'm working with an new ISP and I'm having trouble connecting to MySQL through PHP 4.

    Here's some server specifics; PHP Version 4.0.4pl1 Apache/1.3.14

    DBA support enabled Supported handlers gdbm db2 db3

    I'm getting the following error;

    Fatal error: Call to undefined function: mysql_pconnect() in /home/... on line 5

    Line 5 is;

    $connection = mysql_pconnect("localhost","myuserid","mypass")

    It's a new box so I'm assuming it's something in the configuration. I don't have access to the server so I'm trying to troubleshoot for the ISP. Any help would be greatly appreciated.

    Thanks, Tom

    -- 
    PHP General Mailing List (http://www.php.net/)
    To unsubscribe, e-mail: php-general-unsubscribelists.php.net
    For additional commands, e-mail: php-general-helplists.php.net To
    contact the list administrators, e-mail: php-list-adminlists.php.net
    

    attached mail follows:


    perhaps they didnt compile PHP with mysql support...

    > -----Original Message----- > From: Matthew Loff [mailto:mattwilletts.com] > Subject: RE: [PHP] Fatal error: Call to undefined function: > mysql_pconnect() in ... > > Have you tried a non-persistant connection? Does that work? > > mysql_connect()? > > > -----Original Message----- > From: Tom Beidler [mailto:tomorbittechservices.com] > Sent: Wednesday, July 11, 2001 3:12 PM > To: php list > Subject: [PHP] Fatal error: Call to undefined function: mysql_pconnect() > in ... > > > I'm working with an new ISP and I'm having trouble connecting to MySQL > through PHP 4. > > Here's some server specifics; > PHP Version 4.0.4pl1 > Apache/1.3.14 > > DBA support enabled > Supported handlers gdbm db2 db3 > > I'm getting the following error; > > Fatal error: Call to undefined function: mysql_pconnect() in /home/... > on line 5 > > Line 5 is; > > $connection = mysql_pconnect("localhost","myuserid","mypass") > > It's a new box so I'm assuming it's something in the configuration. I > don't have access to the server so I'm trying to troubleshoot for the > ISP. Any help would be greatly appreciated. > > Thanks, > Tom

    attached mail follows:


    Did you try a <?php phpinfo(); ?>

    to see if mysql is compiled in

    Matthew Loff wrote: > > Have you tried a non-persistant connection? Does that work? > > mysql_connect()? > > -----Original Message----- > From: Tom Beidler [mailto:tomorbittechservices.com] > Sent: Wednesday, July 11, 2001 3:12 PM > To: php list > Subject: [PHP] Fatal error: Call to undefined function: mysql_pconnect() > in ... > > I'm working with an new ISP and I'm having trouble connecting to MySQL > through PHP 4. > > Here's some server specifics; > PHP Version 4.0.4pl1 > Apache/1.3.14 > > DBA support enabled > Supported handlers gdbm db2 db3 > > I'm getting the following error; > > Fatal error: Call to undefined function: mysql_pconnect() in /home/... > on line 5 > > Line 5 is; > > $connection = mysql_pconnect("localhost","myuserid","mypass") > > It's a new box so I'm assuming it's something in the configuration. I > don't have access to the server so I'm trying to troubleshoot for the > ISP. Any help would be greatly appreciated. > > Thanks, > Tom > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net To > contact the list administrators, e-mail: php-list-adminlists.php.net > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net

    -- 
    Francis Fillion, BAA SI
    Broadcasting live from his linux box.
    And the maintainer of http://www.windplanet.com
    

    attached mail follows:


    I have tried mysql_connect() with the same result "Fatal error: Call to undefined function: mysql_connect()..."

    > From: "Matthew Loff" <mattwilletts.com> > Organization: Willetts Systems > Date: Wed, 11 Jul 2001 16:01:13 -0400 > To: "'Tom Beidler'" <tomorbittechservices.com>, "'php list'" > <php-generallists.php.net> > Subject: RE: [PHP] Fatal error: Call to undefined function: mysql_pconnect() > in ... > > > Have you tried a non-persistant connection? Does that work? > > mysql_connect()?

    attached mail follows:


    use phpinfo to see if they even compiled php with mysql support, probably didn't

    --- Tom Beidler <tomorbittechservices.com> wrote: > I'm working with an new ISP and I'm having trouble > connecting to MySQL > through PHP 4. > > Here's some server specifics; > PHP Version 4.0.4pl1 > Apache/1.3.14 > > DBA support enabled > Supported handlers gdbm db2 db3 > > I'm getting the following error; > > Fatal error: Call to undefined function: > mysql_pconnect() in /home/... on > line 5 > > Line 5 is; > > $connection = > mysql_pconnect("localhost","myuserid","mypass") > > It's a new box so I'm assuming it's something in the > configuration. I don't > have access to the server so I'm trying to > troubleshoot for the ISP. Any > help would be greatly appreciated. > > Thanks, > Tom > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: > php-general-unsubscribelists.php.net > For additional commands, e-mail: > php-general-helplists.php.net > To contact the list administrators, e-mail: > php-list-adminlists.php.net >

    __________________________________________________ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail http://personal.mail.yahoo.com/

    attached mail follows:


    Is php compiled with mysql support? ----- Original Message ----- From: "Tom Beidler" <tomorbittechservices.com> To: "Matthew Loff" <mattwilletts.com>; "php list" <php-generallists.php.net> Sent: Wednesday, July 11, 2001 5:22 PM Subject: Re: [PHP] Fatal error: Call to undefined function:mysql_pconnect() in ...

    > I have tried mysql_connect() with the same result "Fatal error: Call to > undefined function: mysql_connect()..." > > > > > > From: "Matthew Loff" <mattwilletts.com> > > Organization: Willetts Systems > > Date: Wed, 11 Jul 2001 16:01:13 -0400 > > To: "'Tom Beidler'" <tomorbittechservices.com>, "'php list'" > > <php-generallists.php.net> > > Subject: RE: [PHP] Fatal error: Call to undefined function: mysql_pconnect() > > in ... > > > > > > Have you tried a non-persistant connection? Does that work? > > > > mysql_connect()? > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    attached mail follows:


    Hi,

    I am trying to install PHP 4.0.6 as a DSO with Apache 1.3.x. I get thru the configuration and installation without any error messages, but when I try to restart Apache with the new configuration, I get this erroe message:

    Cannot load /usr/local/apache/libexec/libphp4.so into server: ld.so.1: /usr/local/apache/bin/httpd: fatal: relocation error: file /usr/local/apache/libexec/libphp4.so: symbol ap_block_alarms: referenced symbol not found /usr/local/apache/bin/apachectl start: httpd could not be started

    I am running on Solaris 2.6. Ideas, please.

    Thanks Heiko

    attached mail follows:


    I would also like to know what's going on with that error. I have gotten that while compiling on FreeBSD.

    Tyler

    ----- Original Message ----- From: "Heiko Maiwald" <hmaiwaldhns.com> To: <php-generallists.php.net> Sent: Wednesday, July 11, 2001 3:06 PM Subject: [PHP] Trouble with php 4.06 and Apache

    > Hi, > > I am trying to install PHP 4.0.6 as a DSO with Apache 1.3.x. > I get thru the configuration and installation without any error > messages, but > when I try to restart Apache with the new configuration, I get this > erroe message: > > Cannot load /usr/local/apache/libexec/libphp4.so into server: ld.so.1: > /usr/local/apache/bin/httpd: fatal: relocation error: file > /usr/local/apache/libexec/libphp4.so: symbol ap_block_alarms: referenced > symbol not found > /usr/local/apache/bin/apachectl start: httpd could not be started > > I am running on Solaris 2.6. > Ideas, please. > > Thanks > Heiko > >

    ----------------------------------------------------------------------------

    ----
    

    > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net

    attached mail follows:


    I'm making a map (image) which you can click on and the script finds the area-code based on where you click on the map.

    Before I spend time on writing my own code to find if xy values are within a certain coordinates of a polygon, do you know of any build in function to do it? I have browsed lightly through the PHP-manual but not found any.

    Thanks,

    SED

    attached mail follows:


    "Sed" <sedsed.is> wrote in message news:009301c10a46$3db4eba0$0100a8c0mamma... > I'm making a map (image) which you can click on and the script finds the > area-code based on where you click on the map. > > Before I spend time on writing my own code to find if xy values are > within a certain coordinates of a polygon, do you know of any build in > function to do it? I have browsed lightly through the PHP-manual but not > found any.

    http://www.google.com/search?sourceid=navclient&q=point+inside+polygon

    #1 match is

    http://www.dfanning.com/tips/point_in_polygon.html

    --
    Lasse
    

    attached mail follows:


    Thanks to Lasse I found a good solution, you can view it here:

    http://softlab.od.ua/algo/other/alg/node158.html

    Thanks!

    SED

    -----Original Message----- From: Lasse [mailto:lmnospam.dk] Sent: 11. júlí 2001 22:02 To: php-generallists.php.net Subject: [PHP] Re: Function? How to find if xy values are within a coordinates of polygon?

    "Sed" <sedsed.is> wrote in message news:009301c10a46$3db4eba0$0100a8c0mamma... > I'm making a map (image) which you can click on and the script finds > the area-code based on where you click on the map. > > Before I spend time on writing my own code to find if xy values are > within a certain coordinates of a polygon, do you know of any build in

    > function to do it? I have browsed lightly through the PHP-manual but > not found any.

    http://www.google.com/search?sourceid=navclient&q=point+inside+polygon

    #1 match is

    http://www.dfanning.com/tips/point_in_polygon.html

    --
    Lasse
    

    -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribelists.php.net For additional commands, e-mail: php-general-helplists.php.net To contact the list administrators, e-mail: php-list-adminlists.php.net

    attached mail follows:


    On Thu, 12 Jul 2001 05:45, SED wrote: > I'm making a map (image) which you can click on and the script finds > the area-code based on where you click on the map. > > Before I spend time on writing my own code to find if xy values are > within a certain coordinates of a polygon, do you know of any build in > function to do it? I have browsed lightly through the PHP-manual but > not found any. > > Thanks, > > SED

    If you use the image as a submit button (<INPUT TYPE=image NAME=map SOURCE="whatever.gif"> then you can read the x and y co-ords of the mouse as $map_x and $map_y

    -- 
    David Robley      Techno-JoaT, Web Maintainer, Mail List Admin, etc
    CENTRE FOR INJURY STUDIES      Flinders University, SOUTH AUSTRALIA  
    

    NEWS! Survivor of siamese twins joins parents

    attached mail follows:


    recent posts introduced me to the handy GetImageSize, and it's just what I need! What I want to do is write a script that will go through a directory of images and write [image name];[image dimensions] to a file so I can query that into my products database for dynamic use on my site.

    BUT, i'm a super-duper PHP newbie and i'm unfamiliar with the syntax for looping thru all fils in a given directory. Can anyone point me in the right direction?

    Thanks so much!

    providing the finest in midget technology

    attached mail follows:


    try this:

    $files = opendir($dir) or die("Cannot opendir $dir"); while ($file = readdir($files)) { // do whatever }

    > -----Original Message----- > From: Rory O'Connor [mailto:midgetelaris.com] > Sent: Wednesday, July 11, 2001 3:09 PM > To: php-generallists.php.net > Subject: [PHP] using GetImageSize in a directory of images > > > recent posts introduced me to the handy GetImageSize, and it's just what > I need! What I want to do is write a script that will go through a > directory of images and write [image name];[image dimensions] to a file > so I can query that into my products database for dynamic use on my > site. > > BUT, i'm a super-duper PHP newbie and i'm unfamiliar with the syntax for > looping thru all fils in a given directory. Can anyone point me in the > right direction? > > Thanks so much! > > > > providing the finest in midget technology > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    attached mail follows:


    (This is assuming you'll have all images in the directory, and no other file types...)

    $directory = opendir("./");

    $dirEntry = readdir($directory); // Skip "." $dirEntry = readdir($directory); // Skip ".."

    while($dirEntry = readdir($directory)) { // GetImageSize Code for Each $dirEntry Goes Here }

    closedir($directory);

    If you may have other types of files besides images, you could easily check each filename with strstr() or a regex.

    -----Original Message----- From: Rory O'Connor [mailto:midgetelaris.com] Sent: Wednesday, July 11, 2001 3:09 PM To: php-generallists.php.net Subject: [PHP] using GetImageSize in a directory of images

    recent posts introduced me to the handy GetImageSize, and it's just what I need! What I want to do is write a script that will go through a directory of images and write [image name];[image dimensions] to a file so I can query that into my products database for dynamic use on my site.

    BUT, i'm a super-duper PHP newbie and i'm unfamiliar with the syntax for looping thru all fils in a given directory. Can anyone point me in the right direction?

    Thanks so much!

    providing the finest in midget technology

    -- 
    PHP General Mailing List (http://www.php.net/)
    To unsubscribe, e-mail: php-general-unsubscribelists.php.net
    For additional commands, e-mail: php-general-helplists.php.net To
    contact the list administrators, e-mail: php-list-adminlists.php.net
    

    attached mail follows:


    Where can I download GD 2.0 or later? (php_gd.dll for Win)

    SED

    attached mail follows:


    Is there a way in PHP to get the referring url when a link is click to get to that page?

    Thanks.

    J

    attached mail follows:


    Joseph Bannon wrote: > Is there a way in PHP to get the referring url when a link is click > to get to that page?

    $HTTP_REFERER getenv('HTTP_REFERER')

    regards Wagner

    -- 
    Madness takes its toll. Please have exact change.
    

    attached mail follows:


    > > Is there a way in PHP to get the referring url when a link is click > > to get to that page? > $HTTP_REFERER > getenv('HTTP_REFERER')

    Note that this isn't supported on all browsers and can be turned off or faked/munged.

    Chris

    attached mail follows:


    What I really wanted ask about was if any knows about GD 2.x version with build in GIF-support (I need both GIF-support and all the new GD-JPEG function to work on the same time).

    SED

    -----Original Message-----

    Where can I download GD 2.0 or later? (php_gd.dll for Win)

    SED

    -- 
    PHP General Mailing List (http://www.php.net/)
    To unsubscribe, e-mail: php-general-unsubscribelists.php.net
    For additional commands, e-mail: php-general-helplists.php.net To
    contact the list administrators, e-mail: php-list-adminlists.php.net
    

    attached mail follows:


    SED wrote: > What I really wanted ask about was if any knows about GD 2.x version > with build in GIF-support (I need both GIF-support and all the new > GD-JPEG function to work on the same time).

    This is probably impossible, for legal reasons. Gif-Support had to be dropped from GDlib because of a changed license. Old releases of gd did support GIFs, but don't expect any more official releases of GD including GIF-Support.

    You could try to hack GIF-support into GD yourself. There is a "patched" version of GD 1.8x which supports GIF-functions as well as these for PNG, but it is illegal. In the USA it is, at least. I'm not sure about other countries.

    regards Wagner

    -- 
    Madness takes its toll. Please have exact change.
    

    attached mail follows:


    Warning: mail() is not supported in this PHP build in testmail.php on line 1

    I don't remember disabling it when I compiled, and I can't find anything to specifically enable it when compiling. I'm running PHP 4.0.6. My sendmail_path is correct in my php.ini.

    I tried recompiling php4 and apache but it seems that it isn't overwriting the php modules. What files are used? I tried deleting the <apache 1.3.20 src>/src/modules/php4 folder.

    Any help would be greatly appreciated.

    attached mail follows:


    Somebody mentioned that PHP checks to see if sendmail was installed when it was installing.

    Just I have another question, does anyone know where PHP puts everything when it installs? I keep recompiling PHP and Apache, and every time I run phpinfo() it still has the original build date. I tried deleting:

    /usr/local/lib/php

    /usr/local/include/php

    <apache src>/src/modules/php4/

    - Kyle

    "Kyle" <nitrowi.rr.com> wrote in message news:20010711213544.84218.qmailpb1.pair.com... > Warning: mail() is not supported in this PHP build in testmail.php on line 1 > > I don't remember disabling it when I compiled, and I can't find anything to > specifically enable it when compiling. I'm running PHP 4.0.6. My > sendmail_path is correct in my php.ini. > > I tried recompiling php4 and apache but it seems that it isn't overwriting > the php modules. What files are used? I tried deleting the <apache 1.3.20 > src>/src/modules/php4 folder. > > Any help would be greatly appreciated. > >

    attached mail follows:


    I believe it varies depending on distribution and install parameters. However, try:

    find / -name php

    and that should show you all the places with php files squirreled away.

    --kurt ----- Original Message ----- From: "Kyle" <nitrowi.rr.com> To: <php-generallists.php.net> Sent: Wednesday, July 11, 2001 7:43 PM Subject: [PHP] Re: Warning: mail() is not supported in this PHP build

    > Somebody mentioned that PHP checks to see if sendmail was installed when it > was installing. > > Just I have another question, does anyone know where PHP puts everything > when it installs? I keep recompiling PHP and Apache, and every time I run > phpinfo() it still has the original build date. I tried deleting: > > /usr/local/lib/php > > /usr/local/include/php > > <apache src>/src/modules/php4/ > > - Kyle > > "Kyle" <nitrowi.rr.com> wrote in message > news:20010711213544.84218.qmailpb1.pair.com... > > Warning: mail() is not supported in this PHP build in testmail.php on line > 1 > > > > I don't remember disabling it when I compiled, and I can't find anything > to > > specifically enable it when compiling. I'm running PHP 4.0.6. My > > sendmail_path is correct in my php.ini. > > > > I tried recompiling php4 and apache but it seems that it isn't overwriting > > the php modules. What files are used? I tried deleting the <apache 1.3.20 > > src>/src/modules/php4 folder. > > > > Any help would be greatly appreciated. > > > > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net > >

    attached mail follows:


    Did you restart your web server? If he is not, it will be they old build that will show, because it will be they old server that will be running.

    Kyle wrote: > > Somebody mentioned that PHP checks to see if sendmail was installed when it > was installing. > > Just I have another question, does anyone know where PHP puts everything > when it installs? I keep recompiling PHP and Apache, and every time I run > phpinfo() it still has the original build date. I tried deleting: > > /usr/local/lib/php > > /usr/local/include/php > > <apache src>/src/modules/php4/ > > - Kyle > > "Kyle" <nitrowi.rr.com> wrote in message > news:20010711213544.84218.qmailpb1.pair.com... > > Warning: mail() is not supported in this PHP build in testmail.php on line > 1 > > > > I don't remember disabling it when I compiled, and I can't find anything > to > > specifically enable it when compiling. I'm running PHP 4.0.6. My > > sendmail_path is correct in my php.ini. > > > > I tried recompiling php4 and apache but it seems that it isn't overwriting > > the php modules. What files are used? I tried deleting the <apache 1.3.20 > > src>/src/modules/php4 folder. > > > > Any help would be greatly appreciated. > > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net

    -- 
    Francis Fillion, BAA SI
    Broadcasting live from his linux box.
    And the maintainer of http://www.windplanet.com
    

    attached mail follows:


    Tried both of those. Tommorrow I'll try to redownload the source to another directory and install.

    "Kyle" <nitrowi.rr.com> wrote in message news:20010712024405.67115.qmailpb1.pair.com... > Somebody mentioned that PHP checks to see if sendmail was installed when it > was installing. > > Just I have another question, does anyone know where PHP puts everything > when it installs? I keep recompiling PHP and Apache, and every time I run > phpinfo() it still has the original build date. I tried deleting: > > /usr/local/lib/php > > /usr/local/include/php > > <apache src>/src/modules/php4/ > > - Kyle > > "Kyle" <nitrowi.rr.com> wrote in message > news:20010711213544.84218.qmailpb1.pair.com... > > Warning: mail() is not supported in this PHP build in testmail.php on line > 1 > > > > I don't remember disabling it when I compiled, and I can't find anything > to > > specifically enable it when compiling. I'm running PHP 4.0.6. My > > sendmail_path is correct in my php.ini. > > > > I tried recompiling php4 and apache but it seems that it isn't overwriting > > the php modules. What files are used? I tried deleting the <apache 1.3.20 > > src>/src/modules/php4 folder. > > > > Any help would be greatly appreciated. > > > > > >

    attached mail follows:


    > > Just I have another question, does anyone know where PHP > puts everything > > when it installs? I keep recompiling PHP and Apache, and > every time I run > > phpinfo() it still has the original build date. I tried deleting:

    If installed as RPM package: $ rpm -ql php

    This gives the paths to the installed php files.

    If installed by hand, then try to do a find: $find / -name '*php*' -print

    That should catch a lot related to php, php.ini, php directories, the php binary, a possible libphp4.so apache module, and so forth. --Kent

    attached mail follows:


    The build date in phpinfo() is the date that configure was run from scratch on the build...

    Try deleting config.cache in the PHP directory, then rerun configure.

    -----Original Message----- From: Kyle [mailto:nitrowi.rr.com] Sent: Wednesday, July 11, 2001 10:44 PM To: php-generallists.php.net Subject: [PHP] Re: Warning: mail() is not supported in this PHP build

    Somebody mentioned that PHP checks to see if sendmail was installed when it was installing.

    Just I have another question, does anyone know where PHP puts everything when it installs? I keep recompiling PHP and Apache, and every time I run phpinfo() it still has the original build date. I tried deleting:

    /usr/local/lib/php

    /usr/local/include/php

    <apache src>/src/modules/php4/

    - Kyle

    "Kyle" <nitrowi.rr.com> wrote in message news:20010711213544.84218.qmailpb1.pair.com... > Warning: mail() is not supported in this PHP build in testmail.php on > line 1 > > I don't remember disabling it when I compiled, and I can't find > anything to > specifically enable it when compiling. I'm running PHP 4.0.6. My > sendmail_path is correct in my php.ini. > > I tried recompiling php4 and apache but it seems that it isn't > overwriting the php modules. What files are used? I tried deleting > the <apache 1.3.20 > src>/src/modules/php4 folder. > > Any help would be greatly appreciated. > >

    -- 
    PHP General Mailing List (http://www.php.net/)
    To unsubscribe, e-mail: php-general-unsubscribelists.php.net
    For additional commands, e-mail: php-general-helplists.php.net To
    contact the list administrators, e-mail: php-list-adminlists.php.net
    

    attached mail follows:


    On 11-Jul-01 scott [gts] wrote: > Has anybody heard if this will affect PHP in any way? > > Copied from the "Unix Guru mailing list": > > -=-=-=-=-=-=-=-=-=-=-=- > The unix time() value becomes > 10 digits for the first time on > Sun Sep 9 01:46:40 2001 > > For the first time in modern > computer history, the timestamp > will be something besides 9 digits. > That could break things. > -=-=-=-=-=-=-=-=-=-=-=- >

    Only for the ijits that think time_t is a string.

    Regards,

    -- 
    Don Read                                       dreadtexas.net
    -- It's always darkest before the dawn. So if you are going to 
       steal the neighbor's newspaper, that's the time to do it.
    

    attached mail follows:


    I am in need of a mail form script which has the subject line filled in for the user....Here's what I mean....

    Let's say I have a webpage.

    On the web page is a picture of a truck, maybe a 1999 Ford F150.

    If the user clicks the pic, he/she is taken to a brief description of the truck.

    On the description page is a button which says "email for more info".

    If the user clicks this button he/she is taken to a page which is a mail form, with the subject being something like, "Requesting information on 1999 Ford F150"

    I guess what you could say, in a way, is that I want to have a mail form, with the subject set according to where the user is coming from...sort of, I guess...

    Can anyone point me to some example code on how to do this? Or an archive of php mailform scripts?

    Thanks, Ed

    attached mail follows:


    On Thu, 12 Jul 2001 09:17, Ed Peddycoart wrote: > I am in need of a mail form script which has the subject line filled in > for the user....Here's what I mean.... > > Let's say I have a webpage. > > On the web page is a picture of a truck, maybe a 1999 Ford F150. > > If the user clicks the pic, he/she is taken to a brief description of > the truck. > > On the description page is a button which says "email for more info". > > If the user clicks this button he/she is taken to a page which is a > mail form, with the subject being something like, "Requesting > information on 1999 Ford F150" > > I guess what you could say, in a way, is that I want to have a mail > form, with the subject set according to where the user is coming > from...sort of, I guess... > > Can anyone point me to some example code on how to do this? Or an > archive of php mailform scripts? > > Thanks, > Ed

    Sounds like you are using a form to allow a submit button - so you could add a hidden field containing the subject?

    <FORM ACTION="mail.php" METHOD="POST> <INPUT TYPE="hidden" NAME=subject VALUE="Your inquiry about a Kenworth"> <INPUT TYPE=submit NAME=summit VALUE="email for more info"> </FORM>

    And no PHP to be seen :-)

    -- 
    David Robley      Techno-JoaT, Web Maintainer, Mail List Admin, etc
    CENTRE FOR INJURY STUDIES      Flinders University, SOUTH AUSTRALIA  
    

    Junk: stuff we throw away. Stuff: junk we keep.

    attached mail follows:


    ...Or call it a riddle.. Whatever... :-)

    What did the following code look like in it's original form?

    function bitdef($prefix, $name, $bitnum) { define($prefix."B_".$name, $bitnum); define($prefix."F_".$name, 1 << $bitnum); }

    --
    Lasse
    

    attached mail follows:


    hey-

    i have a page containing a form with a textarea field. The first part of the page is a quick IP check to make sure the request is coming from my computer. Here's the code I'm confused about:

    <textarea rows="25" cols="80" name="news_info" style="BACKGROUND-COLOR: rgb(31,31,31); BORDER-BOTTOM: rgb(0,0,0) 1px solid; BORDER-LEFT: rgb(0,0,0) 1px solid; BORDER-RIGHT: rgb(0,0,0) 1px solid; BORDER-TOP: rgb(0,0,0) 1px solid; COLOR: rgb(255,255,255); FLOAT: none; FONT-FAMILY: verdana; FONT-SIZE: 8pt; LETTER-SPACING: normal; LINE-HEIGHT: normal; MARGIN-LEFT: 0px; PADDING-BOTTOM: 1px; PADDING-TOP: 1px; TEXT-ALIGN: left; TEXT-INDENT: 0px; VERTICAL-ALIGN: middle">

    <?php readfile("lib/news_file.dat"); ?> </textarea> <br><br> <input type="submit" name="submit">&nbsp;&nbsp; <input type="reset" name="reset"><br>

    -this part above reads in data from the news file and it's put in between the textarea tags, so editing it is easier, then there is this part:

    <?php }

    if($submit) { $fileh = fopen("lib/news_file.dat", "w"); fwrite($fileh, $news_info); fclose($fileh); } ?>

    - that checks if the submit button was pressed, and if so, it writes the data from the textarea to the file - the problem I noticed was that if I submit with something in the textarea, it doesn't display when the page loads again, which is weird, because the action of the form is directed to the same page. but, if I press submit an addditional time, the data I entered in the first time comes up...I don't understand why it's not immediately showing up, since it does write to the file when submit is pressed

    please help!

    attached mail follows:


    On Thu, 12 Jul 2001 08:09, Chris Cocuzzo wrote: > hey- > > i have a page containing a form with a textarea field. The first part > of the page is a quick IP check to make sure the request is coming from > my computer. Here's the code I'm confused about: > > > <textarea rows="25" cols="80" name="news_info" style="BACKGROUND-COLOR: > rgb(31,31,31); BORDER-BOTTOM: rgb(0,0,0) 1px solid; BORDER-LEFT: > rgb(0,0,0) 1px solid; BORDER-RIGHT: rgb(0,0,0) 1px solid; BORDER-TOP: > rgb(0,0,0) 1px solid; COLOR: rgb(255,255,255); FLOAT: none; > FONT-FAMILY: verdana; FONT-SIZE: 8pt; LETTER-SPACING: normal; > LINE-HEIGHT: normal; MARGIN-LEFT: 0px; PADDING-BOTTOM: 1px; > PADDING-TOP: 1px; TEXT-ALIGN: left; TEXT-INDENT: 0px; VERTICAL-ALIGN: > middle"> > > <?php > readfile("lib/news_file.dat"); > ?> > </textarea> > <br><br> > <input type="submit" name="submit">&nbsp;&nbsp; > <input type="reset" name="reset"><br> > > -this part above reads in data from the news file and it's put in > between the textarea tags, so editing it is easier, then there is this > part: > > <?php > } > > if($submit) > { > $fileh = fopen("lib/news_file.dat", "w"); > fwrite($fileh, $news_info); > fclose($fileh); > } > ?> > > - that checks if the submit button was pressed, and if so, it writes > the data from the textarea to the file > - the problem I noticed was that if I submit with something in the > textarea, it doesn't display when the page loads again, which is weird, > because the action of the form is directed to the same page. but, if I > press submit an addditional time, the data I entered in the first time > comes up...I don't understand why it's not immediately showing up, > since it does write to the file when submit is pressed > > please help!

    You aren't setting a value for submit, so you might be better checking for either isset($submit) or !empty($submit) rather than if($submit). Otherwise try assigning a value to submit in the <input> tag.

    -- 
    David Robley      Techno-JoaT, Web Maintainer, Mail List Admin, etc
    CENTRE FOR INJURY STUDIES      Flinders University, SOUTH AUSTRALIA  
    

    Avoid temporary variables and strange women.

    attached mail follows:


    I need to create an authentication hash based on the user agent, to connect to a server but I need PHP’s User Agent, which is usually something like PHP/4.0.X. Is there a variable or way to get this? Thank you.

    attached mail follows:


    You could have PHP open a URL that contained the phpinfo(); function and then just look through that...

    -philip

    On Wed, 11 Jul 2001, Nathan wrote:

    > I need to create an authentication hash based on the user agent, to > connect to a server but I need PHP’s User Agent, which is usually > something like PHP/4.0.X. Is there a variable or way to get this? Thank > you. >

    attached mail follows:


    Just that: $HTTP_USER_AGENT

    Philip Hallstrom wrote: > > You could have PHP open a URL that contained the phpinfo(); function and > then just look through that... > > -philip > > On Wed, 11 Jul 2001, Nathan wrote: > > > I need to create an authentication hash based on the user agent, to > > connect to a server but I need PHP?s User Agent, which is usually > > something like PHP/4.0.X. Is there a variable or way to get this? Thank > > you. > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net

    -- 
    Francis Fillion, BAA SI
    Broadcasting live from his linux box.
    And the maintainer of http://www.windplanet.com
    

    attached mail follows:


    No... that would give you your own browser (say Netscape or IE). He wants what PHP uses...

    On my system it's: PHP/4.0.4pl1

    See http://www.adhesivemedia.com/~philip/bar.php which is just "phpinfo();"

    and http://www.adhesivemedia.com/~philip/foo.php which is just "readfile('http://www/~philip/bar.php');"

    So it looks like it's "PHP/" followed by your version.

    -philip

    On Wed, 11 Jul 2001, Francis Fillion wrote:

    > Just that: $HTTP_USER_AGENT > > > > Philip Hallstrom wrote: > > > > You could have PHP open a URL that contained the phpinfo(); function and > > then just look through that... > > > > -philip > > > > On Wed, 11 Jul 2001, Nathan wrote: > > > > > I need to create an authentication hash based on the user agent, to > > > connect to a server but I need PHP?s User Agent, which is usually > > > something like PHP/4.0.X. Is there a variable or way to get this? Thank > > > you. > > > > > > > -- > > PHP General Mailing List (http://www.php.net/) > > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > > For additional commands, e-mail: php-general-helplists.php.net > > To contact the list administrators, e-mail: php-list-adminlists.php.net > > -- > Francis Fillion, BAA SI > Broadcasting live from his linux box. > And the maintainer of http://www.windplanet.com >

    attached mail follows:


    Oops, I mean get php to open a page that get $HTTP_USER_AGENT and to send it back to you, or to show it to you.

    Nathan wrote: > > I need to create an authentication hash based on the user agent, to > connect to a server but I need PHP?s User Agent, which is usually > something like PHP/4.0.X. Is there a variable or way to get this? Thank > you.

    -- 
    Francis Fillion, BAA SI
    Broadcasting live from his linux box.
    And the maintainer of http://www.windplanet.com
    

    attached mail follows:


    It looks like the Microsoft vs RedHat Open Source Debate is part of the summit (http://conferences.oreillynet.com/cs/os2001/pub/w/os2001/sessions_summit.html), in this case the price can be something around $1495 ($1295 if you have already registered early). Looks like Mr. O'Reilly is going to make a fortune!

    Uri. -------------------------------------------------------- Uri Even-Chen Speedy Software Raanana, Israel. E-mail: webmasterspeedy.co.il ICQ Number: 7461268 Phone Number: 09-7710730 -------------------------------------------------------- Welcome to Speedy Net (In Hebrew): http://www.speedy.co.il/ Speedy Dating (In Hebrew): http://dating.speedy.co.il/ Speedy Composer (In English): http://www.speedy.co.il/composer/ --------------------------------------------------------

    attached mail follows:


    Hello all,

    I wanted to pass the word about our PHP Training Course to those of you on this list.

    Our most recent class, in June, was quite successful - our participants came away with a solid grounding in PHP, and those who were already familiar with PHP learned new techniques and concepts.

    Anyone who is interested in attending our next class, October 1-5, 2001, should visit our website and/or contact me for more information. Our class is located in Ypsilanti, Michigan, just outide Ann Arbor (15 minutes from airport, 40 minutes outside Detroit).

    This is 'hands-on' - each student gets their own workstation, and the class is limited to 14 students. We have a minimum of 2 instructors on hand at all times (often 3), to maximize personal attention and interaction. The course is 5 days, 8 hours each day - you *will* learn a lot.

    I already know that some reading this will object to its 'commercial' nature, and I apologize if I've offended any sensibilities. However, we view this as an opportunity to help 'legitimize' PHP in some way to those organizations that may view lack of 'formal' training as an obstacle to corporate acceptance.

    More info can be found at http://www.tapinternet.com/php/

    Thanks for your time!

    Michael Kimsal Director, Tap Internet 734-480-9961 1-866-745-3660 (toll free in US)

    attached mail follows:


    hi. i'm using the mail() function to send email from a PHP script on a UNIX system. sample code is:

    $result=mail ($mail_to, $mail_subject, $mail_body, $mail_headers);

    and it seems to be placing the mail in the sendmail queue which gets sent every 30 mintues. is there a PHP mail() option or another mailing command that can speed up this time?

    or, does this sound like a sendmail setting?

    thanks for any help! ben

    attached mail follows:


    Sendmail should (by default) attempt to send the mail immediately... If it can't deliver it on that attempt, then it should be queued to send again later (30 mins?)...

    Unless you've configured sendmail differently, it should attempt to deliver as soon as the mail is sent from PHP.

    You can reduce the queue time of sendmail when you run it... For example, on my system, it's:

    # /usr/sbin/sendmail -bd -q15m

    -bd --- Tells sendmail to enter daemon mode -q15m --- Tells sendmail to processes the queue every 15 minutes.

    If you can't fix sendmail, your alternatives are:

    1) Connect to an SMTP server directly using fsockopen() and send the mail that way (I don't recommend it) 2) Reconfigure php.ini to use a different MTA (mail transport agent)

    Anyone else have additional suggestions?

    -----Original Message----- From: Ben Rigby [mailto:benakimbodesign.com] Sent: Wednesday, July 11, 2001 7:54 PM To: php-generallists.php.net Subject: [PHP] mail() function 30minute delay??

    hi. i'm using the mail() function to send email from a PHP script on a UNIX system. sample code is:

    $result=mail ($mail_to, $mail_subject, $mail_body, $mail_headers);

    and it seems to be placing the mail in the sendmail queue which gets sent every 30 mintues. is there a PHP mail() option or another mailing command that can speed up this time?

    or, does this sound like a sendmail setting?

    thanks for any help! ben

    -- 
    PHP General Mailing List (http://www.php.net/)
    To unsubscribe, e-mail: php-general-unsubscribelists.php.net
    For additional commands, e-mail: php-general-helplists.php.net To
    contact the list administrators, e-mail: php-list-adminlists.php.net
    

    attached mail follows:


    in article MABBJGIMGGJKHJLPJGBHAEAPCMAA.programmerjennybug.com, Randy Johnson at programmerjennybug.com wrote on 7/13/01 10:53 AM:

    > How do I rename a file on Linux in PHP? > > Thanks > > Randy

    $err = `mv moo.php foo.php`

    _a

    attached mail follows:


    > > How do I rename a file on Linux in PHP? > > $err = `mv moo.php foo.php`

    Or, to be safe:

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

    ... `` doesn't work in Safe Mode.

    Jason

    attached mail follows:


    You can also do

    rename("moo.php", "foo.php");

    provided that both are on the same filsystem.

    On Wed, 11 Jul 2001, Alex Black wrote:

    > in article MABBJGIMGGJKHJLPJGBHAEAPCMAA.programmerjennybug.com, Randy > Johnson at programmerjennybug.com wrote on 7/13/01 10:53 AM: > > > How do I rename a file on Linux in PHP? > > > > Thanks > > > > Randy > > > $err = `mv moo.php foo.php` > > _a > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net >

    attached mail follows:


    > rename("moo.php", "foo.php");

    Also, works cross-platform. In most cases try to find a function that is part of PHP rather than using the shell, especially if you are interested in making sure the code works across platforms. There's also most likely a performance hit when starting a shell versus issuing system level calls. --Kent

    attached mail follows:


    http://php.net/rename

    > -----Original Message----- > From: Randy Johnson [mailto:programmerjennybug.com] > Sent: 13 iulie 2001 20:53 > To: Randy Johnson; Chris Lambert - WhiteCrown Networks; > php-generallists.php.net > Subject: [PHP] Rename a File? > > > How do I rename a file on Linux in PHP? > > Thanks > > Randy > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribelists.php.net > For additional commands, e-mail: php-general-helplists.php.net > To contact the list administrators, e-mail: > php-list-adminlists.php.net > >

    attached mail follows:


    I know that someone is working on an xslt->c compiler, which you could construct hooks in php for.

    but I know of no xslt->php compiler (though that would be groovy, bigtime groovy)

    :)

    _a

    in article LNBBINKNLNGMJDJNNGKOEEBIILAA.srousseynetwork54.com, Steven Roussey at srousseynetwork54.com wrote on 7/11/01 10:25 AM:

    > Hi all, > > I was curious if anyone was aware of a XSLT compiler that outputs PHP > source? XSLTC which Sun donated to Apache Foundation creates Java source and > is part of the Xalan project. Java is slow and we are all PHP here. > > Thanks! > > Sincerely, > > Steven Roussey > Network54.com > http://network54.com/?pp=e >

    attached mail follows:


    > ... but when the page expires, IE simply reloads it!

    IE is probably loading it from its cache.

    Try setting these:

    <? // Cache Control header ("Expires: Mon, 6 Nov 2000 05:00:00 GMT"); // Date in the past header ("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); // always modified header ("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 header ("Pragma: no-cache"); // HTTP/1.0 ?>

    This should force IE to reload it properly.

    Jason

    -- 
    Jason Murray
    jasonmmelbourneit.com.au
    Web Developer, Melbourne IT
    "Work now, freak later!"
    

    attached mail follows:


    A friend of mine needs help, we are both PHP newbies. Here's her prob:

    I have user authentication program that uses mySQL to store the username/password and other information that they entered when they registered. The secured pages use ?userid=$userid at the end of the page name to designate who the user is. (example: main.php?userid=admin) I want to make this more secure so that you can't just type the example in and have access to the admin files (or type in someone's username and have access to their files). I'm using a cookie right now but I'm having troubles with it because you have to refresh the main page every time you login or it says that you're not a valid user.

    Steph

    attached mail follows:


    Addendum: to original post

    I can change the ?userid=$userid if there's an easier way to do it but I haven't been able to figure that out yet. ----- Original Message ----- From: Steph To: php-generallists.php.net Sent: Wednesday, July 11, 2001 5:45 PM Subject: Security and Cookies

    A friend of mine needs help, we are both PHP newbies. Here's her prob:

    I have user authentication program that uses mySQL to store the username/password and other information that they entered when they registered. The secured pages use ?userid=$userid at the end of the page name to designate who the user is. (example: main.php?userid=admin) I want to make this more secure so that you can't just type the example in and have access to the admin files (or type in someone's username and have access to their files). I'm using a cookie right now but I'm having troubles with it because you have to refresh the main page every time you login or it says that you're not a valid user.

    Steph

    attached mail follows:


    A more secure choice would be using a basic authentication scheme. If you're using apache there are several apache based modules for MySQL username/password authentication. With a little finess a similar scheme can be done for PHP.

    However if that's not an option my recommended PHP choice is to use sessions (needs 4.x+)....when a person logs in they get assigned a session ID. If you use PHP's session functionality the codes should be more than distinct enough that no one could "guess" another person's session ID. A second benefit is that only users who have been online prior to the session expiring could be accessed. Plus since the ID would be unique every login it would prevent people from bookmarking the member pages and would need to relog back in every time they wish to access the site.

    As for being afraid people can access the admin files...the best solution is to move the admin files to an area a normal individual could access... (ie another domain or subfolder protected by username/password, or IP or both).

    Sincerely,

    Craig Vincent

    -----Original Message----- From: Steph [mailto:stephgoamerica.net] Sent: Wednesday, July 11, 2001 8:45 PM To: php-generallists.php.net Subject: [PHP] Security and Cookies

    A friend of mine needs help, we are both PHP newbies. Here's her prob:

    I have user authentication program that uses mySQL to store the username/password and other information that they entered when they registered. The secured pages use ?userid=$userid at the end of the page name to designate who the user is. (example: main.php?userid=admin) I want to make this more secure so that you can't just type the example in and have access to the admin files (or type in someone's username and have access to their files). I'm using a cookie right now but I'm having troubles with it because you have to refresh the main page every time you login or it says that you're not a valid user.

    Steph

    attached mail follows:


    On Sat, 14 Jul 2001 00:40, Randy Johnson wrote: > I am adding a feature to my site where members can download their > information from the database. What is the best way to accomplish > this? > > Create a text file every time a member wants to download their info? > I thought about this ..how would I handle deleting the text files when > I was finished and what would prevent others from downloading the file? > > > I read somewhere that files can be created on the fly or dynamically > anytime a download takes place. This sounds like a good idea cause > there wouldn't be any files on the server. Any idea where I can get > more info on that? > > Thanks > > Randy

    try this:

    header("Content-disposition: filename=maillist.dat"); header("Content-type: application/octetstream"); header("Pragma: no-cache"); header("Expires: 0"); //query database //echo results required //end

    -- 
    David Robley      Techno-JoaT, Web Maintainer, Mail List Admin, etc
    CENTRE FOR INJURY STUDIES      Flinders University, SOUTH AUSTRALIA  
    

    [incredibly rude and childish comments deleted]

    attached mail follows:


    Hello. I wrote a routine that queries a table (Mysql) to pull about 300 records and record their emails. I iterate over this recorset invoking the mail() function to send an email for each record in this recordset.

    The problem is that on my providers server, there is a big delay before the script end execution. When it takes too long I hit the "stop" button on the browser, but when I do this the users receive the same email twice.

    Why is this happening?

    -- 
    ************************************
    Ivan R. Quintero E.* (507)228-3477	
    Aptdo 1263	   * (507)228-9105
    Balboa, Ancon	   * 612-1103
    Republic of Panama * 
    ************************************
    

    attached mail follows:


    All folks, Is there anyone out there can advice me about the php ad banner rotation module ( especially the free one) ? If there is anyone is using it now and recommend it to me, would be nice. Jack jackyactivelifestyle.com "Love your enemies, it will drive them nuts"

    attached mail follows:


    There's quite a few ad banner systems over at sourceforge. Might give them a look.

    http://sourceforge.net/

    (just search for php ad banner)

    --kurt ----- Original Message ----- From: "Jack" <jackyactivelifestyle.com> To: <php-generallists.php.net> Sent: Thursday, July 12, 2001 8:17 AM Subject: [PHP] php ad banner rotation

    All folks, Is there anyone out there can advice me about the php ad banner rotation module ( especially the free one) ? If there is anyone is using it now and recommend it to me, would be nice. Jack jackyactivelifestyle.com "Love your enemies, it will drive them nuts"

    attached mail follows:


    Hi all! I love phpMyAdmin, just makes life so easy :) But I just moved my site, and phpMyAdmin isnt working on my server yet, so does any one have any solid alternatives that I can install??

    Thanks, Steph

    attached mail follows:


    Steph,

    This one is cgi based and works well too.. http://www.gossamer-threads.com/scripts/mysqlman/index.htm

    Why phpMyAdmin doesn't work on the new server? maybe you need newer development versions?

    Andras

    ----- Original Message ----- From: "Steph" <stephgoamerica.net> To: <php-generallists.php.net> Sent: Wednesday, July 11, 2001 9:00 PM Subject: [PHP] Alternative to phpMyAdmin

    Hi all! I love phpMyAdmin, just makes life so easy :) But I just moved my site, and phpMyAdmin isnt working on my server yet, so does any one have any solid alternatives that I can install??

    Thanks, Steph

    attached mail follows:


    Andrea ,

    Thanks for the feedback. Actually it doesnt work as far as how my host set it up. I just get page cannot be displayed, and have been told by my host that they dont have it working on the server yet. But Chris Lott (fellow PHP lister) suggested I install it myself, which I may just go ahead and try. <thanks Chris>

    Steph

    ----- Original Message ----- From: "Andras Kende" <infokende.com> To: "Steph" <stephgoamerica.net>; <php-generallists.php.net> Sent: Wednesday, July 11, 2001 10:52 PM Subject: Re: [PHP] Alternative to phpMyAdmin

    > Steph, > > This one is cgi based and works well too.. > http://www.gossamer-threads.com/scripts/mysqlman/index.htm > > Why phpMyAdmin doesn't work on the new server? maybe you need newer > development versions? > > > Andras > > ----- Original Message ----- > From: "Steph" <stephgoamerica.net> > To: <php-generallists.php.net> > Sent: Wednesday, July 11, 2001 9:00 PM > Subject: [PHP] Alternative to phpMyAdmin > > > Hi all! I love phpMyAdmin, just makes life so easy :) But I just moved my > site, and phpMyAdmin isnt working on my server yet, so does any one have any > solid alternatives that I can install?? > > Thanks, Steph > >

    attached mail follows:


    www.dbzlegends.net/journal.php

    I made that script, but it doesn't seem to be working. I was at www.devshed.com learning PHP, when I came to the tutorial PHP101_5/page4.html. I wanted to make my own files with a form instead of pre-determining the filename and what its going to say, I figured that would be pretty much the same thing. I get no errors, however no file is made. What am I doing wrong?

    --
    -Joe Ace
    <a href="http://www.dbzlegends.net">Webmaster of Otaku Empire</a> and
    <a href="http://rpg.dbzlegends.net">Dragonball Z Legends RPG</a>
    

    attached mail follows:


    on 7/12/01 12:17 AM, Joe Ace at joe.acedbzlegends.net wrote:

    > I made that script, but it doesn't seem to be working. I was at > www.devshed.com learning PHP, when I came to the tutorial > PHP101_5/page4.html. I wanted to make my own files with a form instead of > pre-determining the filename and what its going to say, I figured that would > be pretty much the same thing. I get no errors, however no file is made. > What am I doing wrong?

    Could you send me a small swatch of code or the link to dev shed? then maybe we can help you out! I couldn't find PHP101_5/page4.html at dev shed...

    -- 
    susanfuturebird.com
    http://futurebird.diaryland.com
    

    attached mail follows:


    on 7/12/01 12:17 AM, Joe Ace at joe.acedbzlegends.net wrote:

    > I made that script, but it doesn't seem to be working. I was at > www.devshed.com learning PHP, when I came to the tutorial > PHP101_5/page4.html. I wanted to make my own files with a form instead of > pre-determining the filename and what its going to say, I figured that would > be pretty much the same thing. I get no errors, however no file is made. > What am I doing wrong?

    Could you send me a small swatch of code or the link to dev shed? then maybe we can help you out! I couldn't find PHP101_5/page4.html at dev shed...

    -- 
    susanfuturebird.com
    http://futurebird.diaryland.com
    

    attached mail follows:


    On Wednesday 11 July 2001 08:20, Chris Anderson wrote: > The way you have it leads me to believe you are talking about for..each > loops

    That would be "=>", not "->" :)

    > ----- Original Message ----- > From: "Brian White" <bwhitesteptwo.com.au> > To: "Adam" <adamwangallery.com>; <php-generallists.php.net> > Sent: Wednesday, July 11, 2001 2:12 AM > Subject: Re: [PHP] What the heck is this > > > That's a classy question ..... > > > > At 23:11 10/07/2001 -0700, Adam wrote: > > >I've seen this around alot ($a->$z) and i'm woundering what it is > > > and

    -- 
    Christian Reiniger
    LGDC Webmaster (http://lgdc.sunsite.dk/)
    

    "Software is like sex: the best is for free" -- Linus Torvalds

    attached mail follows:


    Hi,

    What will the problem if i don't specific what charset to use in the metal tag. And also, what is the CHARSET of "UTF-8". What charset to use if i want my web page to display chinese and english.

    Thank you

    Mark

    attached mail follows:


    Hi,

    What will the problem if i don't specific what charset to use in the metal tag. And also, what is the CHARSET of "UTF-8". What charset to use if i want my web page to display chinese and english.

    Thank you

    Mark