php-general Digest 1 Jun 2004 10:56:40 -0000 Issue 2796

Topics (messages 187310 through 187334):

Secure login script
        187310 by: Ren� Fournier
        187317 by: Raj Shekhar

Re: shortcut if
        187311 by: Marek Kilimajer
        187312 by: John W. Holmes

compiling php with mysql ver3 or 4
        187313 by: Richard Kurth
        187314 by: Rachel Rodriguez

Re: Socket w/SSL Issues
        187315 by: Manuel Lemos

Re: Text Streaming in PHP
        187316 by: Manuel Lemos

kill a script...plz help
        187318 by: CurlyBraces Technologies \( Pvt \) Ltd
        187332 by: Jason Wong

Re: drop down menu populated from a directory
        187319 by: Dustin Krysak

Calender code help
        187320 by: Ryan A

Re: GD Library Upgrade
        187321 by: Ryan Schefke
        187331 by: Jason Wong

Cannot find MySQL header files under
        187322 by: Jough P
        187323 by: Curt Zirzow

zlib compatibility
        187324 by: Francis Mak

Cant right click
        187325 by: Brent Clark
        187326 by: Terence

Affiliates Programs
        187327 by: The Digital E
        187329 by: The Digital E

Re: Slightly OT Mysql question
        187328 by: Burhan Khalid

query-apache2.0.49 installation
        187330 by: rohit  mohta

R: [PHP] query-apache2.0.49 installation
        187333 by: Alessandro Vitale

Remember username and password
        187334 by: Phpu

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message --- The link I posted previously is causing me some grief, apparently because I don't know the first thing about object-oriented PHP or PEAR. Here's the thing: If I MUST learn these two things in order to copy the security of the sample script, I will, but is it really necessary in your opinion?

...Rene
--- End Message ---
--- Begin Message ---
On Mon, 31 May 2004 16:11:07 -0600, Ren� Fournier <[EMAIL PROTECTED]> wrote:
> If I MUST learn these two things in order to copy the
> security of the sample script, I will, but is it really necessary in
> your opinion?

Let me see. Will you let a surgeon who does not know how to handle a
scalpel to operate upon you ? It is good to know the tools you are
going to use . You can simply copy paste the code and it might or
might not work. However when some trouble crops up and you have no
idea where to look, you will be in real trouble.

Regards
Raj Shekhar

--- End Message ---
--- Begin Message --- Bob Lockie wrote:

No syntax error but this always returns 's'.


$add = $delete_count > 0 ? "s" : "x";


That means $delete_count is always greater than 0

--- End Message ---
--- Begin Message ---
Bob Lockie wrote:

No syntax error but this always returns 's'.

$add = $delete_count > 0 ? "s" : "x";

Hmm.. that's odd because

if(false)
{ return false; }

always returns false for me...

--
---John Holmes...

Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/

php|architect: The Magazine for PHP Professionals – www.phparch.com
--- End Message ---
--- Begin Message ---
Hello ,

  How can I compile PHP so that it does not mater what version of
  mysql is installed.
  If I compile it for mysql 3.X and then upgrade mysql to ver 4
  PHP will not install.
  I get error while loading shared libraries: libmysqlclient.so.12: cannot open shared 
object file

  this is how I am compiling php  It is being compiled into Apache not
  as a DSO

./configure --prefix=/usr/php --with-mysql=/usr/
--with-config-file-path=/usr/conf
 --with-exec-dir=/usr/apache/bin --disable-debug --enable-safe-mode
 --enable-magic-quotes --enable-debugger --enable-track-vars --with-ftp 
--enable-sockets
 --enable-ftp --with-apache=../apache
make
make install  

-- 
Best regards,
 Richard                          mailto:[EMAIL PROTECTED]

--- End Message ---
--- Begin Message ---
--- Richard Kurth <[EMAIL PROTECTED]> wrote:
> Hello ,
> 
>   How can I compile PHP so that it does not mater
> what version of
>   mysql is installed.
>   If I compile it for mysql 3.X and then upgrade
> mysql to ver 4
>   PHP will not install.
>   I get error while loading shared libraries:
> libmysqlclient.so.12: cannot open shared object file
> 
>   this is how I am compiling php  It is being
> compiled into Apache not
>   as a DSO
> 
> ./configure --prefix=/usr/php --with-mysql=/usr/
> --with-config-file-path=/usr/conf
>  --with-exec-dir=/usr/apache/bin --disable-debug
> --enable-safe-mode
>  --enable-magic-quotes --enable-debugger
> --enable-track-vars --with-ftp --enable-sockets
>  --enable-ftp --with-apache=../apache
> make
> make install  
> 

I don't have a Linux box where I can test out my
suggestion to you, but here is what you can try:

1. from your php directory:  rm config.cache
2. after that command, run: make clean

That should take care of the previous PHP
installation.

Now try running your ./configure, make, and make
install as you have listed above.  

By the way, your "--with-mysql=/usr/" does not look
like a complete path to your MySQL installation.  Of
course, I cannot say for sure... you know better than
I do where it is installed and what the directory is
called.



=====
~Rachel


        
                
__________________________________
Do you Yahoo!?
Friends.  Fun.  Try the all-new Yahoo! Messenger.
http://messenger.yahoo.com/ 

--- End Message ---
--- Begin Message ---
Hello,

On 05/31/2004 10:14 AM, Steve Douville wrote:
PHP is installed without openssl here at pair. I want to make a socket call
to port 443 on a server and I'm getting an error from fsocketopen() that no
ssl support is built in, of course. I thought that using "ssl://" might work
around this, but I guess not. Any ideas for me?

You can try using the support for CURL library or in the worst case try using a trusted HTTP proxy that forwards SSL HTTP connections.


You may want to try this class that can be used for what you and uses whatever support is available in your PHP environment to establish SSL connections:

http://www.phpclasses.org/httpclient



--

Regards,
Manuel Lemos

PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/

PHP Reviews - Reviews of PHP books and other products
http://www.phpclasses.org/reviews/

Metastorage - Data object relational mapping layer generator
http://www.meta-language.net/metastorage.html

--- End Message ---
--- Begin Message --- On 05/31/2004 04:28 PM, Stephen Lake wrote:
I know I asked this before a couple of weeks ago, but I need a good swift
kick in the right direction :D

I need to know how to do a text stream in PHP.
I have tried the following:

while loop with flush and sleep functions
HTTP/1.1 Connection: Stream (seems to work in the above while loop until you
post something then its like it stalls completely)

Are there any other ways?
I was looking at GTChat lastnight and it mentioned about sending a file
"line by line" to achieve a server push like effect....anyone know how to do
this?

Only way I will consider Java is if it will stream a HTML page and someone
can point me in a direction to grab one

Any help in the above questions would be greatly appreciated.

I think you just need to use Keep Alive connections and use PHP flush command to stream the text.


You may also want to try this class to create chat channels:

Class: Chat
http://www.phpclasses.org/mydbchat


--

Regards,
Manuel Lemos

PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/

PHP Reviews - Reviews of PHP books and other products
http://www.phpclasses.org/reviews/

Metastorage - Data object relational mapping layer generator
http://www.meta-language.net/metastorage.html

--- End Message ---
--- Begin Message ---
sorry for asking such questions , ...........
If u all don't have codings for such cases , could u plz direct me with some steps ?
 
Thank u  
 
#################################################

i used this script to run that abc.pl in command prompt. It is perfectly running.
 
<?php
 

//$ExhibitA = shell_exec('/root/whole/abc.pl');
 
// Perfect.
$ExhibitB = shell_exec('env -i /root/whole/abc.pl');
 
?>
* Actually i need to stop that as well ,
i got this result by ps -e
 
1182 pts/0    00:00:00 abc.pl
so , plz help for that ,
 
thank u
 
curlys

--- End Message ---
--- Begin Message ---
On Tuesday 01 June 2004 10:17, CurlyBraces Technologies \( Pvt \) Ltd wrote:
> sorry for asking such questions , ..........
> If u all don't have codings for such cases , could u plz direct me with
> some steps ?

Have a look at the 'kill' command.

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
------------------------------------------
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
------------------------------------------
/*
P-K4
*/

--- End Message ---
--- Begin Message ---
Ok - here is the relevant Quicktime code:

<!-- START QUICKTIME CONTENT -->
<object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" width="320" height="256" codebase="http://www.apple.com/qtactivex/qtplugin.cab";>
<param name="autoplay" value="true">
<param name="controller" value="true">
<param name="pluginspage" value="http://www.apple.com/quicktime/download/indext.html";>
<param name="target" value="myself">
<param name="type" value="video/quicktime">
<param name="src" value="../../../mov/THElostART.mov">
<embed src="../../../mov/THElostART.mov" width="320" height="256" autoplay="true" controller="true" border="0" pluginspage="http://www.apple.com/quicktime/download/indext.html"; target="myself"></embed>
</object>
<!-- END QUICKTIME CONTENT -->


Now I figure - getting the file name in there would be pretty easy (for the most part), but the thing is getting the dimensions of the movie in there... as it is possible that not all movies are the same dimensions. I am hoping to have just the one PHP that will change dynamically for the QT content - I would like to avoid having a php or html file for each QT movie.

d

PS - please CC me directly as I am subscribed in digest mode.. thanks much!







On 31-May-04, at 3:08 PM, [EMAIL PROTECTED] wrote:

"Dustin Krysak" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]
ok, I added brackets and made my code to:

<?php
if ($handle = opendir('../../../mov')) {
    while (false !== ($file = readdir($handle))) {

        if ($file != '.' && $file != '..') {

            $fileName = str_replace('.mov', '', $file);
            echo '<option value="../../../mov/' . $file . '">' .
$fileName . '</option>';
        }
    }
    closedir($handle);
}
?>

when viewing my page in a browser, it worked! Now what I am hoping to
do is put this menu on a PHP page, and have a qt movie placeholder and
when this menu is used - replace the placeholder with the selected qt
movie... I am just not sure how to do this.

This should be easy. Please post your QT placeholder (HTML) code. Then we
can help.


Regards, Torsten

--- End Message ---
--- Begin Message ---
Hey,
Thanks to you guys on the list I have started to tweak the simple calender
which I posted earlier...but have run into problems ;-)
(I didnt go with the PEAR one coz we don't have PEAR installed on all our
shared hosting accounts)


What I am trying to do is, have some dates be clickable (linked) while the
others be normal.
The clickable days will be passed as an array to the function, so far its
working but unfortunatly only the last part of the array is being taken and
all the ones before ignored.
eg:
$linkArray[0] = 3;
$linkArray[1] = 23;
in which case only 23 is being taken in the for loop...which is correct as
its overwring the one before...
(its a bit easier to understand when you see the code, the part enclosed
within the //Ryan and //Ryan is where I added my code...which is not working
;-D  )

You can download the file (around 3kb) from http://php-php.com/test/cal2.txt
and you can see it in action here: http://www.php-php.com/test/cal2.php

Any help appreciated.

Thanks,
-Ryan

--- End Message ---
--- Begin Message ---
Any thoughts on this?

 

I'm working with a host on a Linux box with PHP 4.2.2.  The version of GD
Library they have is 1.8.4.  I was uploading some pictures using a script
that leveraged GD Library 2+.  Using the php version with the newer GD
library seemed to produce a better quality image.  I have two questions:

 

1 - Can a newer version of GD Library (1.8.4 vs 2+) make a difference in
image quality?

2 - I'd like to upgrade the Linux box that has PHP 4.2.2 and GD Library
1.8.4 to the most recent version.  Is this easy?  Any guidance?  Do I need a
patch?

 

PS - I've been working off of this site: http://www.boutell.com/gd but
wanted to bounce this around with some experts first.

 


--- End Message ---
--- Begin Message ---
On Tuesday 01 June 2004 12:42, Ryan Schefke wrote:

> I'm working with a host on a Linux box with PHP 4.2.2.  The version of GD
> Library they have is 1.8.4.  I was uploading some pictures using a script
> that leveraged GD Library 2+.  Using the php version with the newer GD
> library seemed to produce a better quality image.  I have two questions:
>
>
>
> 1 - Can a newer version of GD Library (1.8.4 vs 2+) make a difference in
> image quality?

Possibly. You would have to read the changelog of GD to see.

> 2 - I'd like to upgrade the Linux box that has PHP 4.2.2 and GD Library
> 1.8.4 to the most recent version.  Is this easy?  Any guidance?  Do I need
> a patch?

You would normally have to recompile PHP to get it use a newer version of GD. 
If your host allowed you to do so then you might as well upgrade your version 
of PHP and use the bundled GD libs.

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
------------------------------------------
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
------------------------------------------
/*
Q:      Why did the programmer call his mother long distance?
A:      Because that was her name.
*/

--- End Message ---
--- Begin Message --- Greetings, when compiling PHP with the 'with-mysql' option I get an warning against using the built-in mysql support. So, I tried '--with-mysql=/path/to/mysql.so and got the following error:
Cannot find MySQL header files under...


What are the names of the mysql header files this message is talking about? If PHP warns against using the built-in support I'd rather use these header files.

Thanks!!
--- End Message ---
--- Begin Message ---
* Thus wrote Jough P ([EMAIL PROTECTED]):
> Greetings, when compiling PHP with the 'with-mysql' option I get an 
> warning against using the built-in mysql support.  So, I tried 
> '--with-mysql=/path/to/mysql.so and got the following error:
> Cannot find MySQL header files under...

The with option just takes a path, configure will do the rest and
find the header and the proper .so to load:

--with-mysql=/usr/local/mysql

The above may have a different path depending on where mysql was
installed.


Curt
-- 
"I used to think I was indecisive, but now I'm not so sure."

--- End Message ---
--- Begin Message ---
Hi,

        This is a resend of my previous question, since nobody answer my question.
Maybe I went to a wrong way of asking such question: "whenever you see it is
related to VB, just ignored"...
        Anyways, anybody has experience working with zlib and PHP?  is the text
compressed in zlib compatible with PHP gzuncompress?

        THANK YOU.

My previous post below:

    What I am trying to do:

    - in VB, compress a string
    - save it as a file
    - use php to open it, then gzuncompress it

    I am using a vb wrapper in:

http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=42297&ln
gWId=1

    I am sure that the above program works, since it can uncompress the
file.  Acutally this program is only an interface using the zlib

    I used the above demo, compressed a string then saved it as a file.
When I tried to use php to gzuncompress it, I got data error.  What is the
problem?  aren't they both using the zlib?

    I also tried  gzinflate, still the same 'gzinflate(): data error in...'
below is the php code:

$handle = fopen("/tmp/tmpCompress.txt", "r");
$contents = fread($handle, filesize("/tmp/tmpCompress.txt"));
fclose($handle);
echo(gzuncompress ($contents));
I also tried to use binary read in php(i.e. "rb"), but still got stucked in
gzuncompress.

just another question, what is the difference between gzuncompress and
gzdeflate  ??

Thank you very much!!

Francis Mak

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

--- End Message ---
--- Begin Message ---
Hi all 

On the link provided below, I noticed that you cant right click.
Therefore you cant get "View source code"
or "Copy link" etc (Depenind on the browser used of course)

http://www.full.xtremedl.com/6.htm

Would anyone know how to do this.
I see that you cant even right click on the pic

Weird

Kind Regards
Brent Clark

--- End Message ---
--- Begin Message ---
Under IE->View->Source and Bingo.

It's probably a javascript script. Easy to bypass.

PHP related...err no.

----- Original Message ----- 
From: "Brent Clark" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, June 01, 2004 2:49 PM
Subject: [PHP] Cant right click


Hi all 

On the link provided below, I noticed that you cant right click.
Therefore you cant get "View source code"
or "Copy link" etc (Depenind on the browser used of course)

http://www.full.xtremedl.com/6.htm

Would anyone know how to do this.
I see that you cant even right click on the pic

Weird

Kind Regards
Brent Clark

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

--- End Message ---
--- Begin Message --- Does anyone know of a good PHP affiliates program, I'm willing to spend some cash if I need to, I have to have one up in a week for a client and can't possibly write it from the ground up by then. A good free one that I can build on or a great package that costs $100 or less would be ideal.

Thanks,
Eric

--- End Message ---
--- Begin Message --- I ran across that one as well, it may be a bit more than I need though, and doesn't look very customizable. I'll look further into that one, though, thanks. If anyone has used it though... please let me know how your experience has been.
Thanks


On Jun 1, 2004, at 4:00 AM, Ryan A wrote:

Hey,

I came accross a great one a month back ...I remember that it was around 99$
coz I couldnt afford it ;-)


http://www.idevdirect.com/idevaffiliate.php

If you find this advise useful and do buy it, please consider "lending" a
copy to me till I can afford to buy my own copy...


Thanks,
-Ryan

On 6/1/2004 9:28:54 AM, The Digital E ([EMAIL PROTECTED]) wrote:
Does anyone know of a good PHP affiliates program,
I'm willing to spend
some cash if I need to, I have to have one up in a week for a client
and can't
possibly write it from the ground up by then. A good free one
that I can build on or a great package that costs $100 or less would be
ideal.


Thanks,
Eric

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



Eric Symbouras
thedigitale.com
347.613.9934

--- End Message ---
--- Begin Message --- Dave Carrera wrote:
Hi List,

Sorry for this question being slightly OT but its is to due with my Php
script in a way.

MySql has stopped adding rows since the db table hit 1mb...

Anyone know why ?

I have search mysql.com docs and other web resources but can not figure it
out.

Running FreeBSD 4.7 and MySql 3.23.58 if that helps

Thank you in advance for any help or guidance and once again sorry for being
a bit OT.

If you have an int auto-increment field that is the primary key, you could have reached the upper limit for int -- which would prevent new rows from being added.


1mb is not any limit for MySQL.
--- End Message ---
--- Begin Message ---
 �
whenever it try to manually start apache 2.0.49 from my system it throws the following 
error
only one useage of each socket address<network address/protocol/port>  is normally 
permitted :make sock could not bind to address 127.0.0.1:80
no listening sockets available ,shutting down
unable to open logs

when i enter localhost at the address bar of internet explorer the html page stating 
apache has been successfully installed.But when i try to run a testscript it throws an 
error stating that

html file not found

can any one please say me where i may be going wrong


--- End Message ---
--- Begin Message ---
check apache server version from the test page.
depending on your system, you may have another web server already running.
if you really wish to install and use version 2.0.49 make sure the installed
server is not conflicting with another one.

cheers,

A.

-----Messaggio originale-----
Da: rohit mohta [mailto:[EMAIL PROTECTED]
Inviato: marted� 1 giugno 2004 11.08
A: [EMAIL PROTECTED]
Oggetto: [PHP] query-apache2.0.49 installation


 �
whenever it try to manually start apache 2.0.49 from my system it throws the
following error
only one useage of each socket address<network address/protocol/port>  is
normally permitted :make sock could not bind to address 127.0.0.1:80
no listening sockets available ,shutting down
unable to open logs

when i enter localhost at the address bar of internet explorer the html page
stating apache has been successfully installed.But when i try to run a
testscript it throws an error stating that

html file not found

can any one please say me where i may be going wrong

--- End Message ---
--- Begin Message ---
Hi,

How can i make a registration form that will remember my username and password every 
time i login from the same computer?
I think i should set a cookie but i don't know how.

Thanks

--- End Message ---

Reply via email to