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: Fri Oct 19 2001 - 14:37:46 CDT

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

    php-general Digest 19 Oct 2001 19:37:46 -0000 Issue 944

    Topics (messages 71554 through 71615):

    Re: Web portals
            71554 by: Daniel Masur

    Re: [PHP-DEV] 4.1.0RC1 out
            71555 by: Andrey Hristov
            71556 by: Andrey Hristov
            71557 by: Rasmus Lerdorf

    Q: How one can pass throught sessions arrays with no use of mysql or files ?
            71558 by: ArsenKirillov

    ask for help about php+mysql install: /usr/local/php-4.0.5/main/internal_functions.c:60: undefined reference to`mysql_module_entry', thanks in advance.
            71559 by: Harrison

    Re: How one can pass throught sessions arrays with no use of mysql or files ?
            71560 by: Kal Amry

    parse_str and parse_url
            71561 by: Olexandr Vynnychenko

    Undefined variable
            71562 by: Tshering Norbu
            71563 by: Boaz Yahav
            71564 by: Dimitris Kossikidis

    Delivering NAMED pdf files
            71565 by: George Pitcher
            71566 by: Rasmus Lerdorf
            71568 by: Arpad Tamas
            71575 by: George Pitcher
            71576 by: George Pitcher
            71577 by: Sebastian
            71579 by: speedboy
            71580 by: George Pitcher
            71581 by: George Pitcher
            71582 by: James Cox
            71584 by: George Pitcher
            71587 by: MrBaseball34
            71590 by: George Pitcher
            71605 by: James Cox

    Setting cache_expire at runtime
            71567 by: Anuradha Ratnaweera

    Call to undefined function: pfpro_init()
            71569 by: Kal Amry
            71571 by: Richard Baskett

    Dividing too integers...
            71570 by: Seb Frost
            71572 by: Richard Baskett
            71574 by: Seb Frost
            71608 by: R'twick Niceorgaw

    Mysql export
            71573 by: Roman
            71583 by: Andrey Hristov

    kindly help adding days on a date
            71578 by: Krushna Kumar R
            71586 by: _lallous

    session ID does not delete itself
            71585 by: Peter

    PHP for shell scripting: weird error.
            71588 by: Alexander Deruwe
            71592 by: Jon Farmer

    Re: sscanf() question...
            71589 by: Christian Reiniger

    Problems with get URL from script (post without forms)
            71591 by: Silvia Mahiques

    phpPgAdmin joins SourecForge
            71593 by: Dan Wilson

    How to convert text/html mail into readable thing ?
            71594 by: Rafa³ Zawadzki

    Re: Timestamp math and format
            71595 by: Alfredeen Johan K

    how to know if email sent
            71596 by: Alexander Jäger
            71600 by: David Pearson

    weird session problem
            71597 by: Ross Barefoot

    Searching for a word in a string
            71598 by: Brandon
            71599 by: Boget, Chris
            71615 by: Chris Lee

    array to string
            71601 by: René Fournier
            71602 by: Steve Werby
            71612 by: R'twick Niceorgaw

    how to move one element of an array to the end of the array
            71603 by: Tom Beidler
            71606 by: Mark Charette
            71607 by: Christopher William Wesley
            71613 by: Tom Beidler
            71614 by: Tom Beidler

    Re: mysql transactions/rollback
            71604 by: Heikki Tuuri

    Articles on OO apps in PHP, also Object-Relational mapping in PHP?
            71609 by: Chris Bailey

    html files with ext .php3 and upgrade to php4
            71610 by: sgibbs.vt.globalhealth.org
            71611 by: MINI2

    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:


    would intresst me too, cose i want to biuld my own portal

    <veberptt.yu>; <veberptt.yu> schrieb im Newsbeitrag
    news:20011018124135.17694.1001.qmailserver0021...
    >
    > Hi !
    >
    > I am looking for an efficient web portal, sutable for medium/big
    corporation
    > sites, with a searcable product catalog etc. The catalog is the main
    > emphasis of the site.
    >
    > One more thing :
    > Is there a tutorial or an article that covers the web portal building ?
    >
    > Thanks
    > Nikola
    >

    attached mail follows:


    ---------- Forwarded Message ----------

    Subject: [PHP-DEV] 4.1.0RC1 out
    Date: Fri, 19 Oct 2001 09:27:58 +0200
    From: "Stig S. Bakken" <ssballtheweb.com>
    To: php-devlists.php.net, php-qalists.php.net

    Hi,

    4.1.0RC1 is out, download it from
    http://www.php.net/~ssb/php-4.1.0RC1.tar.gz

     - Stig

    --
    PHP Development Mailing List <http://www.php.net/>
    To unsubscribe, e-mail: php-dev-unsubscribelists.php.net
    For additional commands, e-mail: php-dev-helplists.php.net
    To contact the list administrators, e-mail: php-list-adminlists.php.net
    

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

    attached mail follows:


    ---------- Forwarded Message ----------

    Subject: Re: [PHP-DEV] 4.1.0RC1 out Date: Fri, 19 Oct 2001 09:51:22 +0200 (CEST) From: Derick Rethans <derickphp.net> To: "Stig S. Bakken" <ssballtheweb.com> Cc: <php-devlists.php.net>, <php-qalists.php.net>

    Hello,

    RC1 doesn't compile if --with-zzip is used, I'm committing a fix to CVS shortly.

    Derick

    On Fri, 19 Oct 2001, Stig S. Bakken wrote: > Hi, > > 4.1.0RC1 is out, download it from > http://www.php.net/~ssb/php-4.1.0RC1.tar.gz > > - Stig > > -- > PHP Development Mailing List <http://www.php.net/> > To unsubscribe, e-mail: php-dev-unsubscribelists.php.net > For additional commands, e-mail: php-dev-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net

    Derick Rethans

    --------------------------------------------------------------------- PHP: Scripting the Web - www.php.net - derickphp.net SRM: Site Resource Manager - www.vl-srm.net ---------------------------------------------------------------------

    --
    PHP Development Mailing List <http://www.php.net/>
    To unsubscribe, e-mail: php-dev-unsubscribelists.php.net
    For additional commands, e-mail: php-dev-helplists.php.net
    To contact the list administrators, e-mail: php-list-adminlists.php.net
    

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

    attached mail follows:


    Andy, please stop forwarding these. If people on php-general were interested in the QA process they would be on the QA list, or if they were interested in -dev issues they would be on that list.

    -Rasmus

    On Fri, 19 Oct 2001, Andrey Hristov wrote:

    > > > ---------- Forwarded Message ---------- > > Subject: Re: [PHP-DEV] 4.1.0RC1 out > Date: Fri, 19 Oct 2001 09:51:22 +0200 (CEST) > From: Derick Rethans <derickphp.net> > To: "Stig S. Bakken" <ssballtheweb.com> > Cc: <php-devlists.php.net>, <php-qalists.php.net> > > Hello, > > RC1 doesn't compile if --with-zzip is used, I'm committing a fix to CVS > shortly. > > Derick > > On Fri, 19 Oct 2001, Stig S. Bakken wrote: > > Hi, > > > > 4.1.0RC1 is out, download it from > > http://www.php.net/~ssb/php-4.1.0RC1.tar.gz > > > > - Stig > > > > -- > > PHP Development Mailing List <http://www.php.net/> > > To unsubscribe, e-mail: php-dev-unsubscribelists.php.net > > For additional commands, e-mail: php-dev-helplists.php.net > > To contact the list administrators, e-mail: php-list-adminlists.php.net > > Derick Rethans > > --------------------------------------------------------------------- > PHP: Scripting the Web - www.php.net - derickphp.net > SRM: Site Resource Manager - www.vl-srm.net > --------------------------------------------------------------------- > > > -- > PHP Development Mailing List <http://www.php.net/> > To unsubscribe, e-mail: php-dev-unsubscribelists.php.net > For additional commands, e-mail: php-dev-helplists.php.net > To contact the list administrators, e-mail: php-list-adminlists.php.net > > ------------------------------------------------------- > >

    attached mail follows:


    How one can pass throught sessions arrays with no use of mysql or files ? help me to advance pls.

    attached mail follows:


    Hi there, I encounter the following problem when trying to build a LAMP Box with Mysql-4.0.0+PHP-4.0.5+Apache-1.3.22. 1. Mysql Installed ok 2. when trying to make php with "./configure --with-apache=/home/user/apache_1.3.22 --with-mysql=/usr/local/ db/mysql --with-config-file-path=/usr/local/apache/ini --enable-track-vars;m ake;make install", it response : /usr/local/php-4.0.5/main/internal_functions.c:60: undefined reference to`mysql_module_entry', and of course the same happend when trying to build apache.

    Any Help will be very appreciated, Thanks in advance.

    attached mail follows:


    The best way (to get around cookies) is to pass it on the URL

    <a href="phpFile.php?<?=SID?>">

    or

    <a href="phpFile.php?<? echo SID; ?>">

    Notice no $ before SID

    Kal

    "Arsenkirillov" <softmipm.lviv.ua> wrote in message news:MABBLMNCDFDLNBKIGAAACEJCCHAA.softmipm.lviv.ua... > How one can pass throught sessions arrays with no use of mysql or files ? > help me to advance pls.

    attached mail follows:


    Hello php-general,

    I need a function which is opposite to parse_str or parse_url, i.e. it makes string containing URL with passed variablenames and variablevalues. Did someone see such function? I can't find it in th manual. Thank's.

    -- 
    Best regards,
     Olexandr Vynnychenko                          mailto:supaboyi.com.ua
    

    attached mail follows:


    Dear list,

    I test the following script on local web server and it runs fine. But when I upload the script to the real web server I get the following error/message, but the script works fine. Do you know why?

    Here is the error/message I get:

    Undefined variable : id in test.php on line 6

    And here is the script file (test.php):

    <html> <body> <?php $db = mysql_connect("localhost", "root", "root"); mysql_select_db("penpal",$db); if ($id)

    $result = mysql_query("select * from penpal where id = $id",$db); $myrow = mysql_fetch_array($result); printf("<b>ID:</b> %s\n<br>", $myrow["id"]); printf("<b>Name:</b> %s\n<br>", $myrow["name"]); printf("<b>Age/Sex/Location:</b> %s\n<br>", $myrow["asl"]); printf("<b>Description:</b> %s\n<br>", $myrow["description"]); printf("<b>Email:</b> %s\n<br>", $myrow["email"]); } else { $result = mysql_query("select * from penpal order by id desc", $db); if ($myrow = mysql_fetch_array($result)) { do { printf("<a href = \"%s?id=%s\">%s %s</a><br>\n", $PHP_SELF, $myrow["id"], $myrow["name"], $myrow["asl"]); } while ($myrow = mysql_fetch_array($result)); } else { echo "Sorry, no records"; } } ?> </body> </html>

    The id field in my table has the attribute: id tinyint (4)

    Thanks in advance NOBBY

    attached mail follows:


    it's a warning, not an error... you should check if it is set before you use it :

    If(IsSet($id)) { Do something... }

    Sincerely

    berber

    Visit http://www.weberdev.com Today!!! To see where PHP might take you tomorrow.

    -----Original Message----- From: Tshering Norbu [mailto:norbudruknet.net.bt] Sent: Friday, October 19, 2001 11:23 AM To: php-generallists.php.net Subject: [PHP] Undefined variable

    Dear list,

    I test the following script on local web server and it runs fine. But when I upload the script to the real web server I get the following error/message, but the script works fine. Do you know why?

    Here is the error/message I get:

    Undefined variable : id in test.php on line 6

    And here is the script file (test.php):

    <html> <body> <?php $db = mysql_connect("localhost", "root", "root"); mysql_select_db("penpal",$db); if ($id)

    $result = mysql_query("select * from penpal where id = $id",$db); $myrow = mysql_fetch_array($result); printf("<b>ID:</b> %s\n<br>", $myrow["id"]); printf("<b>Name:</b> %s\n<br>", $myrow["name"]); printf("<b>Age/Sex/Location:</b> %s\n<br>", $myrow["asl"]); printf("<b>Description:</b> %s\n<br>", $myrow["description"]); printf("<b>Email:</b> %s\n<br>", $myrow["email"]); } else { $result = mysql_query("select * from penpal order by id desc", $db); if ($myrow = mysql_fetch_array($result)) { do { printf("<a href = \"%s?id=%s\">%s %s</a><br>\n", $PHP_SELF, $myrow["id"], $myrow["name"], $myrow["asl"]); } while ($myrow = mysql_fetch_array($result)); } else { echo "Sorry, no records"; } } ?> </body> </html>

    The id field in my table has the attribute: id tinyint (4)

    Thanks in advance NOBBY

    -- 
    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 should work ...

    if ( IsSet($id) ) { ..... sql statement }else{ ..... }

    ----- Original Message ----- From: "Tshering Norbu" <norbudruknet.net.bt> To: <php-generallists.php.net> Sent: Friday, October 19, 2001 12:22 PM Subject: [PHP] Undefined variable

    > Dear list, > > I test the following script on local web server and it runs fine. But when > I upload the script to the real web server I get the following > error/message, but the script works fine. Do you know why? > > Here is the error/message I get: > > Undefined variable : id in test.php on line 6 > > > And here is the script file (test.php): > > <html> > <body> > <?php > $db = mysql_connect("localhost", "root", "root"); > mysql_select_db("penpal",$db); > if ($id) > > $result = mysql_query("select * from penpal where id = $id",$db); > $myrow = mysql_fetch_array($result); > printf("<b>ID:</b> %s\n<br>", $myrow["id"]); > printf("<b>Name:</b> %s\n<br>", $myrow["name"]); > printf("<b>Age/Sex/Location:</b> %s\n<br>", $myrow["asl"]); > printf("<b>Description:</b> %s\n<br>", $myrow["description"]); > printf("<b>Email:</b> %s\n<br>", $myrow["email"]); > } else { > $result = mysql_query("select * from penpal order by id desc", $db); > if ($myrow = mysql_fetch_array($result)) { > do { > printf("<a href = \"%s?id=%s\">%s %s</a><br>\n", $PHP_SELF, $myrow["id"], > $myrow["name"], $myrow["asl"]); > } while ($myrow = mysql_fetch_array($result)); > } else { > echo "Sorry, no records"; > } > } > ?> > </body> > </html> > > > > The id field in my table has the attribute: id tinyint (4) > > Thanks in advance > NOBBY > > > -- > 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 all,

    I am delivering my PDF files from a non-internet directory. The file gets delivered but the filename is always changed to the name of the php script.

    Can anyone tell me how to get the file delivered so that the name stays as it was on the server?

    My PHP code. This is all the php code I use in my site (so far). ========== <?php $fp1 = "D:\\Pdf\\" . $fp; $len = filesize($fp1); header("Content-type: application/pdf"); header("Content-Disposition: inline; filename=$fp1"); header("Content-Length: $len"); readfile($fp1); ?> =============

    Regards

    George Pitcher, Edinburgh

    _________________________________________________________ Do You Yahoo!? Get your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    The obvious hack would be to simply make the link:

    http://your.domain.com/script.php/filename_you_want.pdf

    -Rasmus

    On Fri, 19 Oct 2001, George Pitcher wrote:

    > Hi all, > > I am delivering my PDF files from a non-internet directory. The file gets > delivered but the filename is always changed to the name of the php script. > > Can anyone tell me how to get the file delivered so that the name stays as > it was on the server? > > My PHP code. This is all the php code I use in my site (so far). > ========== > <?php > $fp1 = "D:\\Pdf\\" . $fp; > $len = filesize($fp1); > header("Content-type: application/pdf"); > header("Content-Disposition: inline; filename=$fp1"); > header("Content-Length: $len"); > readfile($fp1); > ?> > ============= > > Regards > > George Pitcher, Edinburgh > > > _________________________________________________________ > Do You Yahoo!? > Get your free yahoo.com address at http://mail.yahoo.com > > >

    attached mail follows:


    On Friday 19 October 2001 11:52, George Pitcher wrote: > Hi all, > > I am delivering my PDF files from a non-internet directory. The > file gets delivered but the filename is always changed to the name > of the php script. > > Can anyone tell me how to get the file delivered so that the name > stays as it was on the server? It works this way for me on many browsers (included ie):

    header("Content-Type: application/octectstream"); header("Content-Disposition: filename=$name"); header("Pragma: no-cache"); header("Expires: 0");

    Don't forget to double-check every capital letter, because it matters in http and for most browsers too (for example your Content-Type's capitals are wrong below). Arpi

    > ========== > <?php > $fp1 = "D:\\Pdf\\" . $fp; > $len = filesize($fp1); > header("Content-type: application/pdf"); > header("Content-Disposition: inline; filename=$fp1"); > header("Content-Length: $len"); > readfile($fp1); > ?> > ============= > > Regards > > George Pitcher, Edinburgh > > > _________________________________________________________ > Do You Yahoo!? > Get your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    Rasmus,

    Thanks for the suggestion but it didn't change anything.

    George ----- Original Message ----- From: "Rasmus Lerdorf" <rasmusphp.net> To: "George Pitcher" <fmdevyahoo.co.uk> Cc: <php-generallists.php.net> Sent: Friday, October 19, 2001 10:54 AM Subject: Re: [PHP] Delivering NAMED pdf files

    > The obvious hack would be to simply make the link: > > http://your.domain.com/script.php/filename_you_want.pdf > > -Rasmus > > On Fri, 19 Oct 2001, George Pitcher wrote: > > > Hi all, > > > > I am delivering my PDF files from a non-internet directory. The file gets > > delivered but the filename is always changed to the name of the php script. > > > > Can anyone tell me how to get the file delivered so that the name stays as > > it was on the server? > > > > My PHP code. This is all the php code I use in my site (so far). > > ========== > > <?php > > $fp1 = "D:\\Pdf\\" . $fp; > > $len = filesize($fp1); > > header("Content-type: application/pdf"); > > header("Content-Disposition: inline; filename=$fp1"); > > header("Content-Length: $len"); > > readfile($fp1); > > ?> > > ============= > > > > Regards > > > > George Pitcher, Edinburgh > > > > > > _________________________________________________________ > > Do You Yahoo!? > > Get your free yahoo.com address at http://mail.yahoo.com > > > > > >

    _________________________________________________________ Do You Yahoo!? Get your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    Arpi,

    Thanks for the suggestion but it didn't change anything.

    George

    ----- Original Message ----- From: "Arpad Tamas" <stsmail.xubion.hu> To: "George Pitcher" <fmdevyahoo.co.uk>; <php-generallists.php.net> Sent: Friday, October 19, 2001 11:13 AM Subject: Re: [PHP] Delivering NAMED pdf files

    > On Friday 19 October 2001 11:52, George Pitcher wrote: > > Hi all, > > > > I am delivering my PDF files from a non-internet directory. The > > file gets delivered but the filename is always changed to the name > > of the php script. > > > > Can anyone tell me how to get the file delivered so that the name > > stays as it was on the server? > It works this way for me on many browsers (included ie): > > header("Content-Type: application/octectstream"); > header("Content-Disposition: filename=$name"); > header("Pragma: no-cache"); > header("Expires: 0"); > > Don't forget to double-check every capital letter, because it matters > in http and for most browsers too (for example your Content-Type's > capitals are wrong below). > Arpi > > > ========== > > <?php > > $fp1 = "D:\\Pdf\\" . $fp; > > $len = filesize($fp1); > > header("Content-type: application/pdf"); > > header("Content-Disposition: inline; filename=$fp1"); > > header("Content-Length: $len"); > > readfile($fp1); > > ?> > > ============= > > > > Regards > > > > George Pitcher, Edinburgh > > > > > > _________________________________________________________ > > Do You Yahoo!? > > Get your free yahoo.com address at http://mail.yahoo.com

    _________________________________________________________ Do You Yahoo!? Get your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    Hi George

    I had the same problem a while ago. The only solution i found was to change the link to : www.blabla.com/pdffile/test.pdf test.pdf does not exist, but in /pdffile/ there is a .htaccess which redirects the 404 to the php script that reads/generates the pdfs. And for my purpose checks if user is authorized to get these files.

    sebastian

    > -----Ursprüngliche Nachricht----- > Von: George Pitcher [mailto:fmdevyahoo.co.uk] > Gesendet: Freitag, 19. Oktober 2001 12:55 > An: Arpad Tamas; php-generallists.php.net > Betreff: Re: [PHP] Delivering NAMED pdf files > > > Arpi, > > Thanks for the suggestion but it didn't change anything. > > George > > ----- Original Message ----- > From: "Arpad Tamas" <stsmail.xubion.hu> > To: "George Pitcher" <fmdevyahoo.co.uk>; <php-generallists.php.net> > Sent: Friday, October 19, 2001 11:13 AM > Subject: Re: [PHP] Delivering NAMED pdf files > > > > On Friday 19 October 2001 11:52, George Pitcher wrote: > > > Hi all, > > > > > > I am delivering my PDF files from a non-internet > directory. The file > > > gets delivered but the filename is always changed to the > name of the > > > php script. > > > > > > Can anyone tell me how to get the file delivered so that the name > > > stays as it was on the server? > > It works this way for me on many browsers (included ie): > > > > header("Content-Type: application/octectstream"); > > header("Content-Disposition: filename=$name"); > > header("Pragma: no-cache"); > > header("Expires: 0"); > > > > Don't forget to double-check every capital letter, because > it matters > > in http and for most browsers too (for example your Content-Type's > > capitals are wrong below). > > Arpi > > > > > ========== > > > <?php > > > $fp1 = "D:\\Pdf\\" . $fp; > > > $len = filesize($fp1); > > > header("Content-type: application/pdf"); > > > header("Content-Disposition: inline; filename=$fp1"); > > > header("Content-Length: $len"); > > > readfile($fp1); > > > ?> > > > ============= > > > > > > Regards > > > > > > George Pitcher, Edinburgh > > > > > > > > > _________________________________________________________ > > > Do You Yahoo!? > > > Get your free yahoo.com address at http://mail.yahoo.com > > > _________________________________________________________ > Do You Yahoo!? > Get your free yahoo.com address at http://mail.yahoo.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:


    > Thanks for the suggestion but it didn't change anything.

    It won't. Put them in a web accessible directory and don't use custom header calls because they do not work reliably.

    attached mail follows:


    Sebastian,

    Just tried it - it dosn't work for me.

    George ----- Original Message ----- From: "Sebastian" <sstadtl_phpmailgmx.de> To: "'George Pitcher'" <fmdevyahoo.co.uk>; "'Php-General" <php-generallists.php.net> Sent: Friday, October 19, 2001 12:19 PM Subject: AW: [PHP] Delivering NAMED pdf files

    Hi George

    I had the same problem a while ago. The only solution i found was to change the link to : www.blabla.com/pdffile/test.pdf test.pdf does not exist, but in /pdffile/ there is a .htaccess which redirects the 404 to the php script that reads/generates the pdfs. And for my purpose checks if user is authorized to get these files.

    sebastian

    > -----Ursprüngliche Nachricht----- > Von: George Pitcher [mailto:fmdevyahoo.co.uk] > Gesendet: Freitag, 19. Oktober 2001 12:55 > An: Arpad Tamas; php-generallists.php.net > Betreff: Re: [PHP] Delivering NAMED pdf files > > > Arpi, > > Thanks for the suggestion but it didn't change anything. > > George > > ----- Original Message ----- > From: "Arpad Tamas" <stsmail.xubion.hu> > To: "George Pitcher" <fmdevyahoo.co.uk>; <php-generallists.php.net> > Sent: Friday, October 19, 2001 11:13 AM > Subject: Re: [PHP] Delivering NAMED pdf files > > > > On Friday 19 October 2001 11:52, George Pitcher wrote: > > > Hi all, > > > > > > I am delivering my PDF files from a non-internet > directory. The file > > > gets delivered but the filename is always changed to the > name of the > > > php script. > > > > > > Can anyone tell me how to get the file delivered so that the name > > > stays as it was on the server? > > It works this way for me on many browsers (included ie): > > > > header("Content-Type: application/octectstream"); > > header("Content-Disposition: filename=$name"); > > header("Pragma: no-cache"); > > header("Expires: 0"); > > > > Don't forget to double-check every capital letter, because > it matters > > in http and for most browsers too (for example your Content-Type's > > capitals are wrong below). > > Arpi > > > > > ========== > > > <?php > > > $fp1 = "D:\\Pdf\\" . $fp; > > > $len = filesize($fp1); > > > header("Content-type: application/pdf"); > > > header("Content-Disposition: inline; filename=$fp1"); > > > header("Content-Length: $len"); > > > readfile($fp1); > > > ?> > > > ============= > > > > > > Regards > > > > > > George Pitcher, Edinburgh > > > > > > > > > _________________________________________________________ > > > Do You Yahoo!? > > > Get your free yahoo.com address at http://mail.yahoo.com > > > _________________________________________________________ > Do You Yahoo!? > Get your free yahoo.com address at http://mail.yahoo.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 > >

    _________________________________________________________ Do You Yahoo!? Get your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    Thanks for the [non] suggestion.

    I will not host these in a web-accessable directory. They are copyright materials.

    I've done this type of hosting previously using Frontier on a Mac and it worked fine.

    I thought that php was better than Frontier, though.

    George ----- Original Message ----- From: "speedboy" <speedboynomicrosoft.org> To: <php-generallists.php.net> Sent: Friday, October 19, 2001 12:27 PM Subject: Re: [PHP] Delivering NAMED pdf files

    > > Thanks for the suggestion but it didn't change anything. > > It won't. Put them in a web accessible directory and don't use custom header calls because they do not work reliably. > > > -- > 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 your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    can you paste the full text of the code as you have it? I don't see anywhere where you define the name of the file.

    James Cox

    . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Politicalia admin and editor e: jamespoliticalia.com :: w: http://www.politicalia.com/ Today's Discussion, Tomorrow's Agenda. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

    > -----Original Message----- > From: George Pitcher [mailto:fmdevyahoo.co.uk] > Sent: Friday, October 19, 2001 12:27 PM > To: speedboy; php-generallists.php.net > Subject: Re: [PHP] Delivering NAMED pdf files > > > Thanks for the [non] suggestion. > > I will not host these in a web-accessable directory. They are copyright > materials. > > I've done this type of hosting previously using Frontier on a Mac and it > worked fine. > > I thought that php was better than Frontier, though. > > George > ----- Original Message ----- > From: "speedboy" <speedboynomicrosoft.org> > To: <php-generallists.php.net> > Sent: Friday, October 19, 2001 12:27 PM > Subject: Re: [PHP] Delivering NAMED pdf files > > > > > Thanks for the suggestion but it didn't change anything. > > > > It won't. Put them in a web accessible directory and don't use custom > header calls because they do not work reliably. > > > > > > -- > > 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 your free yahoo.com address at http://mail.yahoo.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:


    James,

    I can. The text in square brackets is a pdf filename referenced in full from a Filemaker database using Lasso.

    <Form action="fileaccess.php" method="post"> <input type=hidden name="fp" value="[field:'Doc_filename']"> <input type="Submit" value="Download PDF file"> </form>

    And the php page which is fileaccess.php:

    <?php $fp1 = "D:\\Pdf\\" . $fp; $len = filesize($fp1); header("Content-Type: application/pdf"); header("Content-Disposition: inline; filename=$fp1"); header("Content-Length: $len"); readfile($fp1); ?>

    HTH

    George ----- Original Message ----- From: "James Cox" <jameswherewithal.com> To: "George Pitcher" <fmdevyahoo.co.uk>; "Php-GeneralLists. Php. Net" <php-generallists.php.net> Sent: Friday, October 19, 2001 12:45 PM Subject: RE: [PHP] Delivering NAMED pdf files

    > can you paste the full text of the code as you have it? I don't see anywhere > where you define the name of the file. > > James Cox > > . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . > . > Politicalia admin and editor > e: jamespoliticalia.com :: w: http://www.politicalia.com/ > Today's Discussion, Tomorrow's Agenda. > . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . > . > > > > -----Original Message----- > > From: George Pitcher [mailto:fmdevyahoo.co.uk] > > Sent: Friday, October 19, 2001 12:27 PM > > To: speedboy; php-generallists.php.net > > Subject: Re: [PHP] Delivering NAMED pdf files > > > > > > Thanks for the [non] suggestion. > > > > I will not host these in a web-accessable directory. They are copyright > > materials. > > > > I've done this type of hosting previously using Frontier on a Mac and it > > worked fine. > > > > I thought that php was better than Frontier, though. > > > > George > > ----- Original Message ----- > > From: "speedboy" <speedboynomicrosoft.org> > > To: <php-generallists.php.net> > > Sent: Friday, October 19, 2001 12:27 PM > > Subject: Re: [PHP] Delivering NAMED pdf files > > > > > > > > Thanks for the suggestion but it didn't change anything. > > > > > > It won't. Put them in a web accessible directory and don't use custom > > header calls because they do not work reliably. > > > > > > > > > -- > > > 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 your free yahoo.com address at http://mail.yahoo.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 > >

    _________________________________________________________ Do You Yahoo!? Get your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    > > And the php page which is fileaccess.php: > > <?php > $fp1 = "D:\\Pdf\\" . $fp; > $len = filesize($fp1); > header("Content-Type: application/pdf"); > header("Content-Disposition: inline; filename=$fp1"); > header("Content-Length: $len"); > readfile($fp1); > ?>

    Have you CHECKED the value of $fp?

    attached mail follows:


    Yes,

    If I download the file as it is named, it is the file I expected, only not named the way I wanted.

    George

    "MrBaseball34" <mrbaseball34hotmail.com> wrote in message news:MPG.1639e82085267290989683news.php.net... > > > > And the php page which is fileaccess.php: > > > > <?php > > $fp1 = "D:\\Pdf\\" . $fp; > > $len = filesize($fp1); > > header("Content-Type: application/pdf"); > > header("Content-Disposition: inline; filename=$fp1"); > > header("Content-Length: $len"); > > readfile($fp1); > > ?> > > Have you CHECKED the value of $fp? > > -- > 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 your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    George,

    your best bet is to have a table in your database which looks up the name of the file, based on a more friendly name.

    James

    . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Politicalia admin and editor e: jamespoliticalia.com :: w: http://www.politicalia.com/ Today's Discussion, Tomorrow's Agenda. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

    > -----Original Message----- > From: George Pitcher [mailto:fmdevyahoo.co.uk] > Sent: Friday, October 19, 2001 2:42 PM > To: MrBaseball34; php-generallists.php.net > Subject: Re: [PHP] Delivering NAMED pdf files > > > Yes, > > If I download the file as it is named, it is the file I expected, only not > named the way I wanted. > > George > > "MrBaseball34" <mrbaseball34hotmail.com> wrote in message > news:MPG.1639e82085267290989683news.php.net... > > > > > > And the php page which is fileaccess.php: > > > > > > <?php > > > $fp1 = "D:\\Pdf\\" . $fp; > > > $len = filesize($fp1); > > > header("Content-Type: application/pdf"); > > > header("Content-Disposition: inline; filename=$fp1"); > > > header("Content-Length: $len"); > > > readfile($fp1); > > > ?> > > > > Have you CHECKED the value of $fp? > > > > -- > > 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 your free yahoo.com address at http://mail.yahoo.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:


    Is it possible to set session.cache_expire with a php function in a similar manner to session_cache_limiter()?

    I can do a workaround using header() etc. but am just curious if there is a neater way.

    Regards,

    Anuradha

    -- 
    

    Debian GNU/Linux (kernel 2.4.12)

    Many receive advice, few profit by it. -- Publilius Syrus

    attached mail follows:


    Anyone knows how I can use pfpro_init();

    It is giving me an error right away saying:

    Fatal error: Call to undefined function: pfpro_init() in PATH_TO_FILE.php on line 3

    Where can I find a support for these functions?

    Thanks,

    attached mail follows:


    Did you check out?: http://www.php.net/manual/en/ref.pfpro.php

    These functions are only available if PHP has been compiled with the --with-pfpro[=DIR] option. You will require the appropriate SDK for your platform, which may be downloaded from within the manager interface once you have registered. If you are going to use this extension in an SSL-enabled webserver or with other SSL components (such as the CURL+SSL extension) you MUST get the beta SDK.

    Rick

    > Anyone knows how I can use pfpro_init(); > > It is giving me an error right away saying: > > Fatal error: Call to undefined function: pfpro_init() in PATH_TO_FILE.php on > line 3 > > Where can I find a support for these functions? > > Thanks, > > > > > > -- > 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:


    Sorry for the stupid question...

    I want to do

    $this=$foo/$bar; (All are integers.)

    where this is always rounded up.

    I tried the obvious

    $this = ceil($foo/$bar) but I just always get 0.

    cheers,

    - seb

    ---
    Outgoing mail is certified Virus Free.
    Checked by AVG anti-virus system (http://www.grisoft.com).
    Version: 6.0.282 / Virus Database: 150 - Release Date: 25/09/2001
    

    attached mail follows:


    I don't see why that doesnt work... I would echo your values first to make sure the values you want in $foo and $bar are the right ones... It looks to me that your expression is correct...

    Rick

    > Sorry for the stupid question... > > I want to do > > $this=$foo/$bar; (All are integers.) > > where this is always rounded up. > > I tried the obvious > > $this = ceil($foo/$bar) but I just always get 0. > > > cheers, > > - seb > --- > Outgoing mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.282 / Virus Database: 150 - Release Date: 25/09/2001 > > > -- > 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:


    Cheers Rich!

    I had $numrows instead of $num_rows - Doh!

    I said "too" instead of "two" - double Doh!

    - seb

    -----Original Message----- From: Richard Baskett [mailto:rickbaskettcase.com] Sent: 19 October 2001 11:30 To: Seb Frost; PHP General Subject: Re: [PHP] Dividing too integers...

    I don't see why that doesnt work... I would echo your values first to make sure the values you want in $foo and $bar are the right ones... It looks to me that your expression is correct...

    Rick

    > Sorry for the stupid question... > > I want to do > > $this=$foo/$bar; (All are integers.) > > where this is always rounded up. > > I tried the obvious > > $this = ceil($foo/$bar) but I just always get 0. > > > cheers, > > - seb > --- > Outgoing mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.282 / Virus Database: 150 - Release Date: 25/09/2001 > > > -- > 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 >

    ---
    Incoming mail is certified Virus Free.
    Checked by AVG anti-virus system (http://www.grisoft.com).
    Version: 6.0.282 / Virus Database: 150 - Release Date: 25/09/2001
    

    --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.282 / Virus Database: 150 - Release Date: 25/09/2001

    attached mail follows:


    try this.. $temp = ($foo%$bar); $this=$temp/$bar;

    ----- Original Message ----- From: "Seb Frost" <sebraceshoot.com> To: <php-generallists.php.net> Sent: Friday, October 19, 2001 6:20 AM Subject: [PHP] Dividing too integers...

    > Sorry for the stupid question... > > I want to do > > $this=$foo/$bar; (All are integers.) > > where this is always rounded up. > > I tried the obvious > > $this = ceil($foo/$bar) but I just always get 0. > > > cheers, > > - seb > --- > Outgoing mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.282 / Virus Database: 150 - Release Date: 25/09/2001 > > > -- > 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:


    Please help me, how to export mysql table to the xls table ? Thanks for all

    Roman

    attached mail follows:


    PhpMyAdmin (on http://www.phpwizard.net") has the capability to export mysql table ot CSV, then import the CSV or maybe this will help you too(on small tables, otherwise the HTML code is big) $dump=''; $separator=','; $the_query="select * from $table;"; $res=mysql_query($the_query); if ($res){ $num_rows=mysql_num_rows($res); for (;$numrows>=0;$num_rows--){ $arr=mysq_fetch_assoc($res); $line=''; foreach ($arr as $k => $v){ $line.=($v.$separator); } $line=substr($line,0,-strlen($separator)); $dump.=$line."\n"; } } if ($dump){ $fd=fopen("{$table}_dump.csv","w+"); frwite($fd,$dump); fclose($fd); echo "<pre>\n".$dump."\n</pre>"; }

    Hope this helps.

    -- 
    Andrey Hristov
    Web Developer
    Icygen Corporation
    BUILDING SOLUTIONS
    http://www.icygen.com
    

    On Friday 19 October 2001 06:33 am, you wrote: > Please help me, how to export mysql table to the xls table ? > Thanks for all > > Roman

    attached mail follows:


    Hi,

    I have 2 fields on a table as shown below

    1. period int - we enter no of days as number/integer 2. lastdate date - here i'll have to add period to todays(current) date and store in the table

    i used dateadd it was working on mysql prompt, but when i used it with PHP, it doesnt work

    Any help would be appreciated

    Regards Krushna Kumar

    attached mail follows:


    you can use it like that:

    see the mysql's date_add() usage:

    SELECT DATE_ADD(NOW(), INTERVAL 5 DAY) or 5 YEAR or n MONTH....

    "Krushna Kumar R" <mlists123hotmail.com> wrote in message news:OE66CNFnC8tuiuoZGMV0001302ahotmail.com... Hi,

    I have 2 fields on a table as shown below

    1. period int - we enter no of days as number/integer 2. lastdate date - here i'll have to add period to todays(current) date and store in the table

    i used dateadd it was working on mysql prompt, but when i used it with PHP, it doesnt work

    Any help would be appreciated

    Regards Krushna Kumar

    attached mail follows:


    Hi,

    I have been experimenting with PHP4 using sessions and one of my books says that session ID's are created in the /tmp directory so I take a look in there and I find are about 10 sessions that have not been deleted dated earliest to about being week old

    ie. sess_5b30ccebb1d098c37a5e46efd7708fef

    I have been experimenting with user authentication with sessions and just plain starting a session when a user accesses the site.

    Well, the site is still experimental and each time I logged myself out.

    But I thought sessions were supposed to wipe themselves out from the /tmp directory immediately after leaving the website.

    Appreciate if someone could shed the light on this issue for me.

    Thanks.

    Peter

    attached mail follows:


    Hey all,

    When running PHP scripts from the command line, I get this error:

    "Content type: text/html PHP Fatal error: Unable to start session mm module in Unknown on line 0"

    The script doesn't run, or so it seems. I also get this error when I run generic stuff such as 'php4 --help', or just 'php4 -q'.

    The script in question is this (though I hardly think it matters): #!/usr/bin/php4 -q <?php echo "Hello, World!\n"; ?>

    Does anyone know what is going on? Searching the archives for the error string turned up nothing.

    I'm running PHP v4.0.7RC3 (from package php4-cgi) on Linux 2.4.10-ac11. Distribution debian unstable.

    Thanks in advance,

    Alexander Deruwe

    attached mail follows:


    > I'm running PHP v4.0.7RC3 (from package php4-cgi) on Linux 2.4.10-ac11. > Distribution debian unstable.

    I would recommend 4.0.6 compiled from source. Thats what I use and its very stable.

    Regards

    jon

    --
    Jon Farmer
    Systems Programmer, Entanet www.enta.net
    Tel 01952 428969 Mob 07763 620378
    PGP Key available, send blank email to pgpkeybctech.co.uk
    

    attached mail follows:


    On Wednesday 17 October 2001 23:25, Uchendu Nwachukwu wrote: > I am trying to write a script to convert a MySQL timestamp > (YYYYMMDDhhmmss) to a unix timestamp.

    SELECT UNIX_TIMESTAMP(timefield) AS MyTime FROM xy

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

    "These are the people who proudly call themselves "hackers" -- not as the term is now abused by journalists to mean a computer criminal, but in its true and original sense of an enthusiast, an artist, a tinkerer, a problem solver, an expert."

    - ESR

    attached mail follows:


    Hi

    I´m interested in launching an HTML page directly from another page. The former has php code and I´d also like to pass some arguments to it. I´m using the getURL code to do this job but I had some problems:

    After launched, the page looks quite weird. When I look at the source code, the variable replacements in the php pieces is wrong. Instead of getting the contents of the variables, it looks as if everything was delated and backlashes were inserted within the quotes. For example, the following line in the php code

    <input type="text" name="name" value="<? echo $name; ?>" width="600" size="33" maxlength="80">

    was replace by

    <input type=\"text\" name=\"name\" value=\"\" width=\"600\" size=\"33\" maxlength=\"80\">

    Do you have any hint about the problem here? If getURL is not the appropriate way of doing what I want, what should I use?

    Thanks in advance,

    Silvia

    attached mail follows:


    For full story, please visit http://sourceforge.net/forum/forum.php?forum_id=117841

    It looks like a previous post didn't go through, so if this is a duplicate, please forgive me.

    -Dan killroyboyusers.sourceforge.net http://sourceforge.net/projects/phppgadmin

    attached mail follows:


    I am using PHP Red Hat. And i have got one big problem:

    I am writing interface for pop3 accounts. Everything is ok, when mail are normal, it means their has got attachments, or not. But when i am reading mail which has been written in html, and it has got also attachment, i got for example:

    ------=_NextPart_001_000B_01C158B1.7C25EB00 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable

    ----- Original Message -----=20 From: rafal=20 To: bluszczbluszcz.localdomain=20 Sent: Friday, October 19, 2001 2:01 PM Subject: buziak

    eretertetret

    ------=_NextPart_001_000B_01C158B1.7C25EB00 Content-Type: text/html; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable

    <here is html message>

    *** When mail has been written in html and hasnt got att. everything is ok.

    main fragment of my script:

    <? $mbox = imap_open ("{10.1.1.4:110/pop3}INBOX", $login, $pass); $mailik=imap_fetchstructure ($mbox,$mail); $czesci=$mailik->parts; echo htmlentities(imap_fetchbody ($mbox, $mail, 1)); $mailek=imap_fetchbody ($mbox, $mail, 1);

    /*

    Here is part script for list attachments.

    */

    imap_close($mbox); ?>

    Thanks for helps.

    -- 
    Rafal Zawadzki rafaelats.com.pl
     Linux registered user #232814
    

    attached mail follows:


    Thanks, That was just what I needed, ie: SELECT DATE_FORMAT(DATE_SUB(insert_date, INTERVAL 2 HOUR), '%b %e (%r)')

    Johan

    > On 17-Oct-2001 Alfredeen Johan K wrote: > > I store a timestamp in a database of when a record was > inserted. When I pull > > it out, I format it like this SELECT > DATE_FORMAT(insert_date,'%b %e (%r)') > > AS idate > > > > Now I would like to subtract 2 hours from the hour part of > the timestamp. > > What's the easiest way to do this, before or after the > formatting? In PHP or > > mySQL function? Can someone give me some code of how they > would do this. > > > > SELECT DATE_FORMAT(DATE_SUB(insert_date, INTERVAL 2 HOUR), > '%b %e (%r)') > > Regards, > -- > Don Read dreadtexas.net > -- It is necessary for me to learn from others' mistakes. I > will not live long enough to make them all by myself. >

    attached mail follows:


    hi everybody

    i'm making an automatic booking system in php. for the hotelier it's also possible to calculte offers and send them to his gasts. we send the email with mail and although we put in a right-formated (with in it etc.) but wrong email adress the function results true. so we tried to get an error-email from the server that send the mails but no success. does anybody has a solution for our problem

    thanx for every little help

    Alexander Jäger

    attached mail follows:


    By default you'll never know if the email you sent gets through.

    You could set up a bounced email tracking system. There is an "Errors-To" header in the email messages that you can have send to a specially set up account on your system. Then have a cron job process that looking for bounced emails you sent. You do have to be able to distinguish real bounces vs. informative warnings that delivery has been delayed. You may also need to track the Message Ids if you need to determine if a specific message that was sent bounces, otherwise you could harvest that special mailbox for known bad email addresses.

    We're building a similar system for our service, I'm trying to get that team to keep it generic enough to be able to be a standalone product.

    David

    -----Original Message----- From: Alexander Jäger [mailto:alexelite.at] Sent: Friday, October 19, 2001 8:09 AM To: php-generallists.php.net Subject: [PHP] how to know if email sent

    hi everybody

    i'm making an automatic booking system in php. for the hotelier it's also possible to calculte offers and send them to his gasts. we send the email with mail and although we put in a right-formated (with in it etc.) but wrong email adress the function results true. so we tried to get an error-email from the server that send the mails but no success. does anybody has a solution for our problem

    thanx for every little help

    Alexander Jäger

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


    Summary: when I write scripts using sessions and run them on my web host the session is created, a session file is opened, but the session file is 0 bytes and therefore the session variables are not being passed. When the tech support guys at the host run the same script they work, even when dialing out through an external isp. They run the same scripts and the session file is created with the session variables intact.

    When I run my scripts on a different hosting company, or using the Apache server on my local machine, they process fine.

    I set up two test scripts to try and resolve this, but after three days of trying, and many hours expended by both myself and the host's tech support, we find no reason. We have tested different browsers, locations, ISP's, OS's. We've ruled out a cookie problem, so no need to go there.

    Here are the two test scripts I've set up: http://www.flexiss.net/page1.php <? session_start(); session_register("test_var");

    $test_var = "Testing 1-2-3...";

    print "the content of \$test_var is $test_var<BR>"; ?>

    <A HREF="page2.php">Next Page</A>

    (end of page1.php)

    Here's page2.php <? session_start(); print "the content of \$test_var is $test_var<BR>";

    $count = count($HTTP_SESSION_VARS);

    print "the count of elements in \$HTTP_SESSION_VARS is $count";

    print "<BR>the session id is: " . $PHPSESSID;

    print "<BR>" . $HTTP_SESSION_VARS['test_var'] ; ?>

    If you run these scripts you may get correct results, but I and other test users at different locations using different machines get the session id, but a count of 0 elements in $HTTP_SESSION_VARS and therefore nothing is passed.

    If you want to look at how the php is set up, you can go to this link: http://www.flexiss.net/phpinfo.php

    Any help would really be appreciated. I've posted this on two PHP forums without a solution being found.

    Ross

    attached mail follows:


    Hello,

    How can I search for a certain word in a string?

    Thanks Brandon

    attached mail follows:


    > How can I search for a certain word in a string?

    strpos() ereg() preg() and similar functions.

    Chris

    attached mail follows:


    php.net/strstr

    if ( strstr($string, $search) ) echo "TRUE"; else echo "FALSE";

    --
    

    Chris Lee leemediawaveonline.com

    "Brandon" <ortherwebintellects.com> wrote in message news:001e01c158b3$91579170$5a52a040wi... > Hello, > > How can I search for a certain word in a string? > > Thanks > Brandon >

    attached mail follows:


    Just trying to convert an array to string before writing the whole thing back out to a file. (Trying to do a simple database-less database, using text files).

    $fcontents = file($name.".db"); // THE ENTIRE TABLE $fcontents[$update] = $updatedstring; // THE ROW TO BE UPDATED $fp = fopen($name.".db", "w+");

    But before the next line, I need to convert $fcontents to a string, else just "Array" gets written to the text file. I just can't seem to find the sure-to-be simple command to do this on php.net or phpbuilder.com, etc. Any ideas?

    fwrite($fp,$fcontents); fclose($fp);

    Thanks.

    ...Rene

    ---
    Rene Fournier
    renefournieryahoo.com
    

    _________________________________________________________ Do You Yahoo!? Get your free yahoo.com address at http://mail.yahoo.com

    attached mail follows:


    "René Fournier" <renefournieryahoo.com> wrote: > Just trying to convert an array to string before writing the whole thing > back out to a file. (Trying to do a simple database-less database, using > text files). > > $fcontents = file($name.".db"); // THE ENTIRE TABLE > $fcontents[$update] = $updatedstring; // THE ROW TO BE UPDATED > $fp = fopen($name.".db", "w+"); > > But before the next line, I need to convert $fcontents to a string, else > just "Array" gets written to the text file. I just can't seem to find the > sure-to-be simple command to do this on php.net or phpbuilder.com, etc. Any > ideas?

    See implode().

    $fcontents_string = implode( '', $fcontents );

    --
    Steve Werby
    President, Befriend Internet Services LLC
    http://www.befriend.com/
    

    attached mail follows:


    try this $fupdatecontents=''; while ( list($key,$value) = each($fcontents) ) { $fupdatecontents .=$value; } $fcontents = $fupdatecontents;

    or just write $fupdatecontents into the file. You may need to add a \n after each line ( which I'm not sure);. If you need you can change the

    $fupdatecontents .=$value;

    line to

    $fupdatecontents .=$value."\n";

    HTH R'twick ----- Original Message ----- From: "René Fournier" <renefournieryahoo.com> To: "Php-General" <php-generallists.php.net> Sent: Friday, October 19, 2001 12:05 PM Subject: [PHP] array to string

    > Just trying to convert an array to string before writing the whole thing > back out to a file. (Trying to do a simple database-less database, using > text files). > > $fcontents = file($name.".db"); // THE ENTIRE TABLE > $fcontents[$update] = $updatedstring; // THE ROW TO BE UPDATED > $fp = fopen($name.".db", "w+"); > > But before the next line, I need to convert $fcontents to a string, else > just "Array" gets written to the text file. I just can't seem to find the > sure-to-be simple command to do this on php.net or phpbuilder.com, etc. Any > ideas? > > fwrite($fp,$fcontents); > fclose($fp); > > Thanks. > > ...Rene > > --- > Rene Fournier > renefournieryahoo.com > > > _________________________________________________________ > Do You Yahoo!? > Get your free yahoo.com address at http://mail.yahoo.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'm running a query that pulls up automotive makes for a given year and orders them alphabetically. One of the options is "no make specified" which I would like to always move to the end of the mysql_fetch_array. So my while loop would pull up

    AMC Ford Volkswagon No make specified

    Instead of

    AMC Ford No make specified Volkswagon

    After looking over the php site it doesn't look like there is an easy way to do it. Should I take the array, remove the element and then add it to the end?

    The no make specified unique id in the make database is 1. I could order by id, use array_shift to pop off the first element, sort the array by asort, and then add it on the end using array_push.

    Is there a better way?

    Thanks, Tom

    attached mail follows:


    Don't bother with doing it in PHP, do it in MySQL with a functional ordering:

    Select Make from your_db order by if(left(Make,7)='no make','zzzzzzzz',Make)

    -----Original Message----- From: Tom Beidler [mailto:tomorbittechservices.com] Sent: Friday, October 19, 2001 11:53 AM To: php list Subject: [PHP] how to move one element of an array to the end of the array

    I'm running a query that pulls up automotive makes for a given year and orders them alphabetically. One of the options is "no make specified" which I would like to always move to the end of the mysql_fetch_array. So my while loop would pull up

    AMC Ford Volkswagon No make specified

    Instead of

    AMC Ford No make specified Volkswagon

    After looking over the php site it doesn't look like there is an easy way to do it. Should I take the array, remove the element and then add it to the end?

    The no make specified unique id in the make database is 1. I could order by id, use array_shift to pop off the first element, sort the array by asort, and then add it on the end using array_push.

    Is there a better way?

    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:


    Splice the array at the point in your result array where "No make specified" is, for one element, then append it back onto the result array. Here ...

    $noMake = array_splice( $resultArray, array_search( "No make specified", $resultArray ), 1); // This should be one line, sorry :)

    $newResults = array_merge( $resultArray, $noMake ); // Two lines total

    g.luck, ~Chris /"\ \ / September 11, 2001 X We Are All New Yorkers / \ rm -rf /bin/laden

    On Fri, 19 Oct 2001, Tom Beidler wrote:

    > I'm running a query that pulls up automotive makes for a given year and > orders them alphabetically. One of the options is "no make specified" which > I would like to always move to the end of the mysql_fetch_array. So my while > loop would pull up > > AMC > Ford > Volkswagon > No make specified > > Instead of > > AMC > Ford > No make specified > Volkswagon > > After looking over the php site it doesn't look like there is an easy way to > do it. Should I take the array, remove the element and then add it to the > end? > > The no make specified unique id in the make database is 1. I could order by > id, use array_shift to pop off the first element, sort the array by asort, > and then add it on the end using array_push. > > Is there a better way? > > 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:


    Trying to use the solution without positive results

    First need to clarify, I'm actually trying to order the model. Here's my original query;

    $make_query = "SELECT make.make, model.model, application.make_id, application.model_id FROM application INNER JOIN make ON make.id = application.make_id INNER JOIN model ON model.id = application.model_id WHERE application.year_in <= $value AND application.year_out >= $value AND application.make_id != 1 ORDER BY make.make, model.model";

    here's what I tried to change it too

    $make_query = "SELECT make.make, model.model, application.make_id, application.model_id FROM application INNER JOIN make ON make.id = application.make_id INNER JOIN model ON model.id = application.model_id WHERE application.year_in <= $value AND application.year_out >= $value AND application.make_id != 1 ORDER BY make.make, if(left(model.model,7)='No model specified','zzzzzzzz',model.model)";

    I get the same results with both. If you can, let me know where I strayed.

    Also, out of curiosity, is it faster to do it in MySQL rather then PHP?

    Thanks, Tom

    > From: "Mark Charette" <charettesneezy.org> > Date: Fri, 19 Oct 2001 12:34:24 -0500 > To: "Tom Beidler" <tomorbittechservices.com>, "php list" > <php-generallists.php.net> > Subject: RE: [PHP] how to move one element of an array to the end of the array > > if(left(Make,7)='no make','zzzzzzzz',Make)

    attached mail follows:


    Chris,

    Good solution but I should have mentioned we're running PHP 4.04 and I was getting an undeclared function with array_search. I tried using array_keys without luck. Here's as far as I got;

    while ($make_row = mysql_fetch_array ($make_result)) {

    if (in_array ("No model specified", $make_row)) { $make_row_keys = array_keys ($make_row, "No model specified"); reset($make_row); while (list($key,$value) = each($make_row_keys)) { $noMake = array_splice( $make_row, $value, 0); $newResults = array_merge( $make_row, $noMake ); } } else { $newResults = array_merge( $make_row, $noMake ); }

    To clarify, I have to sort on model, not make. I'm querying the database for make, model, make_id and model_id.

    Thanks for the good solution though, I should have been more specific.

    Tom

    > From: Christopher William Wesley <cwwesleyudlug.org> > Date: Fri, 19 Oct 2001 10:43:35 -0700 (PDT) > To: php list <php-generallists.php.net> > Cc: Tom Beidler <tomorbittechservices.com> > Subject: Re: [PHP] how to move one element of an array to the end of the array > > Splice the array at the point in your result array where "No make > specified" is, for one element, then append it back onto the result array. > Here ... > > $noMake = array_splice( $resultArray, array_search( "No make specified", > $resultArray ), 1); // This should be one line, sorry :) > > $newResults = array_merge( $resultArray, $noMake ); > // Two lines total > > g.luck, > ~Chris /"\ > \ / September 11, 2001 > X We Are All New Yorkers > / \ rm -rf /bin/laden > > On Fri, 19 Oct 2001, Tom Beidler wrote: > >> I'm running a query that pulls up automotive makes for a given year and >> orders them alphabetically. One of the options is "no make specified" which >> I would like to always move to the end of the mysql_fetch_array. So my while >> loop would pull up >> >> AMC >> Ford >> Volkswagon >> No make specified >> >> Instead of >> >> AMC >> Ford >> No make specified >> Volkswagon >> >> After looking over the php site it doesn't look like there is an easy way to >> do it. Should I take the array, remove the element and then add it to the >> end? >> >> The no make specified unique id in the make database is 1. I could order by >> id, use array_shift to pop off the first element, sort the array by asort, >> and then add it on the end using array_push. >> >> Is there a better way? >> >> 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:


    Hi!

    Job Miller wrote in message <20011018221811.44160.qmailweb10008.mail.yahoo.com>... >yes, thank you though. >not in MyISAM tables, which is what mine are, and >again according the manual, you slow things down >significantly for transaction support.

    Transactional InnoDB tables are actually faster in many simple benchmarks than MyISAM. Set

    innodb_flush_log_at_trx_commit=0

    to avoid disk write at each commit. See benchmarks at http://www.innodb.com/bench.html

    >is it worth it? instead of my previously suggested >method of handling it? or is there something better?

    Regards,

    Heikki Innobase Oy

    >--- CC Zona <cczonanospam.invalid> wrote: >> In article >> ><20011018201248.82069.qmailweb10002.mail.yahoo.com>, >> jobmilleryahoo.com (Job Miller) wrote: >> >> > without save points and rollback what is the best >> way >> > to replace all records for a user that might have >> been >> > edited with their new values. >> >> To clarify: are you aware that MySQL does have >> transaction support >> available, or is using it not an option for you >> here? >> >> -- >> CC >> >> -- >> 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!? >Make a great connection at Yahoo! Personals. >http://personals.yahoo.com

    attached mail follows:


    I'm wondering if there are any articles or other material describing how to design PHP web applications in a highly object oriented fashion? Specifically, object relational mapping, using classes for nearly everything (as appropriate), etc. The articles don't have to be PHP specific, but PHP's OO/class facilities leave a bit to be desired in comparison to say Java, so how this is done in PHP would be interesting.

    I've read a few PHP articles, a couple books, etc. on the "typical" (my impression) way of designing PHP web apps, where it's pretty much a 2 layer setup of UI and database, and there is no encapsulation/data hiding, and classes/objects aren't used much.

    Pointers to any material of this nature would be appreciated.

    ____ Chris Bailey mailto:chriscodeintensity.com Code Intensity http://www.codeintensity.com

    attached mail follows:


    We just upgraded to php4 but many of our html files end with the extension .php3 - will this be a problem?

    attached mail follows:


    No, just make sure you configure the .php3 extension as you would .php, .phtml, etc. You could make it .MyWierdExtension as long as Apache knows that files of that type are PHP and need to be processed.

    Cheers Casey Swenson Caseymini2.com

    -----Original Message----- From: sgibbsvt.globalhealth.org [mailto:sgibbsvt.globalhealth.org] Sent: Friday, October 19, 2001 1:18 PM To: php-generallists.php.net Cc: awelchvt.globalhealth.org Subject: [PHP] html files with ext .php3 and upgrade to php4

    We just upgraded to php4 but many of our html files end with the extension .php3 - will this be a problem?

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