php-general Digest 7 Aug 2003 14:48:55 -0000 Issue 2222

Topics (messages 158592 through 158651):

parallelport interfacing
        158592 by: Michael P. Carel

Installer Software
        158593 by: Joe Harman
        158595 by: John W. Holmes
        158596 by: Rodney Green

Re: bug in code - can't find it!
        158594 by: John W. Holmes
        158646 by: Marek Kilimajer

Re: Hitler and Recent Threads
        158597 by: Mark
        158615 by: Robert Cummings
        158650 by: Mark

Re: PHP & P2P File sharing
        158598 by: Chris Shiflett
        158600 by: Joe Harman

Re: Stop neurotic posting
        158599 by: John Manko
        158601 by: daniel.electroteque.org

Problem execucting nusoap.php
        158602 by: Daniel Ke

Re: Convert GIF to JPG with or without GD
        158603 by: Daniel Ward

PHP Newbie needs assistance to highlight a specific item in a frame window
        158604 by: Mary D. Taffet

Re: Persistent connection extension not freeing connections until server is restarted
        158605 by: Curt Zirzow

on specific time in the month do script!!
        158606 by: Nabil
        158612 by: Bobby Patel
        158629 by: Nabil
        158634 by: Jason Wong
        158635 by: Justin French

error: cannot redeclare ()
        158607 by: Martin Towell
        158609 by: Joe Harman
        158613 by: Martin Towell
        158649 by: John W. Holmes

moderator: has anything on this list changed?
        158608 by: Justin French
        158614 by: Curt Zirzow
        158616 by: Curt Zirzow
        158640 by: Juan Nin

[EMAIL PROTECTED]
        158610 by: Joe Harman
        158611 by: Martin Towell
        158632 by: Ben

Re: greedy preg
        158617 by: SLanger.spirit21.de
        158624 by: skate
        158644 by: skate
        158645 by: Marek Kilimajer
        158647 by: skate
        158651 by: Marek Kilimajer

php help
        158618 by: Dipesh khacharia

Re: Insidious!
        158619 by: Nicholas Robinson

perl to php converter
        158620 by: Louie Miranda

Re: logging of mail() function?
        158621 by: Nicholas Robinson

on the fly picture problem
        158622 by: Benoit LEFEVRE

static method and $this
        158623 by: messju mohr
        158626 by: messju mohr

Can't Pass variable to other page
        158625 by: Jack
        158628 by: Ben
        158631 by: Kae Verens

Re: mail() function
        158627 by: photogames.net
        158633 by: Jason Wong

Re: More command line php
        158630 by: Pascal Miquet

php help : configuring freetds with php
        158636 by: Dipesh khacharia

Re: ImageCreateTrueColor
        158637 by: Kai Poppe

Re: [PHP-WIN] Re: Can't Pass variable to other page
        158638 by: Miha Nedok

problem while executing php with thttpd server
        158639 by: Amarnath R
        158642 by: Marek Kilimajer

Re: shell_exec
        158641 by: David Robley

Re: for the love of god, remove me
        158643 by: David Robley

Re: Class Design Question...
        158648 by: Dan Joseph

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 ---
Hi to all,

Just want to ask if PHP is capable of Parallel port interfacing?
If ever , can anyone give me  a good tutorial or samples  about this.

Thanks in advance.



Mike

--- End Message ---
--- Begin Message ---
Hello, 
 
I am making an application in PHP, but I want it to run on a user's
local computer... but I need to find someway to bundle this so that when
it is distributed, the installer installs PHP for windows... then copys
the PHP files to the correct directory, then puts a short cut on the
desktop... can anyone recommend anything out there.. preferably that is
free
 
Respectfully,
Joe Harman


 

--- End Message ---
--- Begin Message --- Joe Harman wrote:

I am making an application in PHP, but I want it to run on a user's
local computer... but I need to find someway to bundle this so that when
it is distributed, the installer installs PHP for windows... then copys
the PHP files to the correct directory, then puts a short cut on the
desktop... can anyone recommend anything out there.. preferably that is
free

Are you planning on installing a web server, also, or run it from the command line?


--
---John Holmes...

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

PHP|Architect: A magazine for PHP Professionals – www.phparch.com





--- End Message ---
--- Begin Message ---
> I am making an application in PHP, but I want it to run on a user's
> local computer... but I need to find someway to bundle this so that when
> it is distributed, the installer installs PHP for windows... then copys
> the PHP files to the correct directory, then puts a short cut on the
> desktop... can anyone recommend anything out there.. preferably that is
> free

Check out the Nullsoft Install System. It's free..

http://www.nullsoft.com/free/nsis/



--- End Message ---
--- Begin Message --- AciD wrote:

just a little point; u can replace
<?echo $search_result2[a.retired_flag]?>
by <?=$search_result2[a.retired_flag]?>
which is better imho.

and you're entitled to it, but it's not better. Shorter isn't always better.


Your code will break if enable_short_open_tags is disabled in php.ini or an .htaccess file. Sure, it's on by default, but some people turn it off, especially when dealing with XML a lot.

--
---John Holmes...

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

PHP|Architect: A magazine for PHP Professionals – www.phparch.com





--- End Message ---
--- Begin Message --- Is it realy so? I remember someone noting on this list it also work if short tags are off.
I have never tested it and I'm not going to restart our server now, but I will try it at home.


John W. Holmes wrote:

AciD wrote:

just a little point; u can replace
<?echo $search_result2[a.retired_flag]?>
by <?=$search_result2[a.retired_flag]?>
which is better imho.


and you're entitled to it, but it's not better. Shorter isn't always better.

Your code will break if enable_short_open_tags is disabled in php.ini or an .htaccess file. Sure, it's on by default, but some people turn it off, especially when dealing with XML a lot.



--- End Message ---
--- Begin Message ---
I believe according to Godwin's Law, Mr. Cummings has now lost the
argument.

> > > > That kind of thinking leads to things like Hitler :|


=====
Mark Weinstock
[EMAIL PROTECTED]
***************************************
You can't demand something as a "right" unless you are willing to fight to death to 
defend everyone else's right to the same thing.
***************************************

__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

--- End Message ---
--- Begin Message ---
Godwin's law in no way states that that the argument has been lost. Only
that the thread has outlived it's usefulness. Unfortunately your
invocation of Godwin's law forces it to fall under Quirk's exception
which generally makes you the fool.

Cheers,
Rob.


On Wed, 2003-08-06 at 23:11, Mark wrote:
> I believe according to Godwin's Law, Mr. Cummings has now lost the
> argument.
> 
> > > > > That kind of thinking leads to things like Hitler :|
> 
> 
> =====
> Mark Weinstock
> [EMAIL PROTECTED]
> ***************************************
> You can't demand something as a "right" unless you are willing to fight to death to 
> defend everyone else's right to the same thing.
> ***************************************
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site design software
> http://sitebuilder.yahoo.com
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 
-- 
.---------------------------------------------.
| Worlds of Carnage - http://www.wocmud.org   |
:---------------------------------------------:
| Come visit a world of myth and legend where |
| fantastical creatures come to life and the  |
| stuff of nightmares grasp for your soul.    |
`---------------------------------------------'

--- End Message ---
--- Begin Message ---
As much as I'd like to get into the details of Godwin's Law and
Quirk's Exception, I'll leave it with a minor explanation. Quirk's
exception essentially says that you can't say "Hilter! There, the
threads over." It doesn't say anything about invoking Godwin's Law.

Quirk's Exception: Intentional invocation of this so-called "Nazi
Clause" is ineffectual.

Perhaps you could do a bit more reading on it. But the bottom line
is, the thread HAS outlived its usefulness (if it ever had any) and,
like discussions about religion or politics, is not going to change
anyone's mind. And as they say, "Never argue with a fool. People will
not be able to tell the differnce."



--- Robert Cummings <[EMAIL PROTECTED]> wrote:
> Godwin's law in no way states that that the argument has been lost.
> Only
> that the thread has outlived it's usefulness. Unfortunately your
> invocation of Godwin's law forces it to fall under Quirk's
> exception
> which generally makes you the fool.
> 
> Cheers,
> Rob.
> 
> 
> On Wed, 2003-08-06 at 23:11, Mark wrote:
> > I believe according to Godwin's Law, Mr. Cummings has now lost
> the
> > argument.
> > 
> > > > > > That kind of thinking leads to things like Hitler :|
> > 
> > 
> > =====
> > Mark Weinstock
> > [EMAIL PROTECTED]
> > ***************************************
> > You can't demand something as a "right" unless you are willing to
> fight to death to defend everyone else's right to the same thing.
> > ***************************************
> > 
> > __________________________________
> > Do you Yahoo!?
> > Yahoo! SiteBuilder - Free, easy-to-use web site design software
> > http://sitebuilder.yahoo.com
> > 
> > -- 
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> > 
> > 
> -- 
> .---------------------------------------------.
> | Worlds of Carnage - http://www.wocmud.org   |
> :---------------------------------------------:
> | Come visit a world of myth and legend where |
> | fantastical creatures come to life and the  |
> | stuff of nightmares grasp for your soul.    |
> `---------------------------------------------'
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 


=====
Mark Weinstock
[EMAIL PROTECTED]
***************************************
You can't demand something as a "right" unless you are willing to fight to death to 
defend everyone else's right to the same thing.
***************************************

__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

--- End Message ---
--- Begin Message ---
--- Joe Harman <[EMAIL PROTECTED]> wrote:
> I curious if anyone knows of a PHP based Peer-to-Peer file sharing
> program out there! I have a friend that wants to implement this
> with his web server..

P2P isn't exactly something you do with PHP anymore than you would write a Web
server with PHP (which has been done, however, but I hope you can still see my
point). A better approach, in my opinion, is to think of ways to allow your
users to interact with a P2P network while using your Web application. There is
a command-line client for Overnet (http://www.overnet.com/), for example, and
PHP can interact with this to perform whatever tasks you want to expose to your
Web users. Most every P2P protocol I am familiar with does not fit well within
the Web paradigm (HTTP transactions, etc.). So, you have to be creative and
make your Web application provide the layer that interprets your users'
desires, executes the appropriate tasks using a P2P client, and displays the
results in a way that can fit into the Web paradigm (downloads will probably
take longer than you want to wait before responding to users, for example).

That's my perspective anyway (and I've been faced with this same task). Hope it
helps.

Chris

=====
Become a better Web developer with the HTTP Developer's Handbook
http://httphandbook.org/

--- End Message ---
--- Begin Message ---
Hey Chris.. Thanks for the insite... I was basically trying to provide a
way for a community of graphic/3D artist to share their files... Like
clothes and hair for poser... It would be great to take advantage of a
network like the Gnuetella one... I will look into the overnet site... I
may just make a file locker type app for them

Joe

> -----Original Message-----
> From: Chris Shiflett [mailto:[EMAIL PROTECTED] 
> Sent: Wednesday, August 06, 2003 11:28 PM
> To: Joe Harman; [EMAIL PROTECTED]
> Subject: Re: [PHP] PHP & P2P File sharing
> 
> 
> --- Joe Harman <[EMAIL PROTECTED]> wrote:
> > I curious if anyone knows of a PHP based Peer-to-Peer file sharing 
> > program out there! I have a friend that wants to implement 
> this with 
> > his web server..
> 
> P2P isn't exactly something you do with PHP anymore than you 
> would write a Web server with PHP (which has been done, 
> however, but I hope you can still see my point). A better 
> approach, in my opinion, is to think of ways to allow your 
> users to interact with a P2P network while using your Web 
> application. There is a command-line client for Overnet 
(http://www.overnet.com/), for example, and PHP can interact with this
to perform whatever tasks you want to expose to your Web users. Most
every P2P protocol I am familiar with does not fit well within the Web
paradigm (HTTP transactions, etc.). So, you have to be creative and make
your Web application provide the layer that interprets your users'
desires, executes the appropriate tasks using a P2P client, and displays
the results in a way that can fit into the Web paradigm (downloads will
probably take longer than you want to wait before responding to users,
for example).

That's my perspective anyway (and I've been faced with this same task).
Hope it helps.

Chris

=====
Become a better Web developer with the HTTP Developer's Handbook
http://httphandbook.org/



--- End Message ---
--- Begin Message ---
I tend to think that PHP will take over the world....
Just my $0.02.


Robert Cummings wrote:


Hitler began his conquest by taking a country here, a country there
while other countries sat around saying to each other oh he won't keep
doing it. Let's DO NOTHING! Obviously that plan was flawed -- and that
is what I was referring to -- not that by being quiet suddenly the world
will be plunged into war again (not that it isn't already).

Cheers,
Rob.

On Wed, 2003-08-06 at 17:11, Chris Sherwood wrote:


Hitler is it?

why is it everytime someone mentions a proper ettiquette, or some common
sense thing that it is immeadiately taken to an extreme..

is this reasonable behaviour? does it portray us as adults, maybe adults who
have a major chip on our shoulders... all I am saying is if you feel nasty
... keep it to yourself

now how does that equate to being like or bringing back hitler?


----- Original Message ----- From: "Robert Cummings" <[EMAIL PROTECTED]> To: "Chris Sherwood" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Wednesday, August 06, 2003 2:04 PM Subject: Re: [PHP] Stop neurotic posting




On Wed, 2003-08-06 at 16:36, Chris Sherwood wrote:


or what does it take to actually give a reasonable answer... if I am


gonna


be rude I wont say anything... doesnt any one remember their mother


telling


them if you dont have anything nice to say dont say anything at all?



That kind of thinking leads to things like Hitler :| If we never say
anything then it becomes the norm for people to continue their
behaviour. Currently the question being debated is what constitutes poor
behaviour/etiquette within this mailing list. While I agree that this
forum is primarily for answering questions -- I disagree that it is for
answering silly little questions that would be common knowledge if the
asker had bothered to read any tutorials or documentation -- most
especially when it appears that the poster didn't even bother to do any
kind of searching for themselves. I mean really, questions like "does X
do Y" is often as simple as writing 1 to 5 lines of test code which is
probably shorter than the email itself and doesn't pollute the mailing
list with 5 to 10 replies of "yes" or "no".

Cheers,
Rob.
--
.---------------------------------------------.
| Worlds of Carnage - http://www.wocmud.org   |
:---------------------------------------------:
| Come visit a world of myth and legend where |
| fantastical creatures come to life and the  |
| stuff of nightmares grasp for your soul.    |
`---------------------------------------------'

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









--- End Message ---
--- Begin Message ---
obviously our asp windoze counterparts look over us as inferior, but i dont
see it that way, but how about java , looking into the future how inferior
or superior comparing php and java ?

> I tend to think that PHP will take over the world....
> Just my $0.02.
>
>
> Robert Cummings wrote:
>
>>Hitler began his conquest by taking a country here, a country there
>>while other countries sat around saying to each other oh he won't keep
>>doing it. Let's DO NOTHING! Obviously that plan was flawed -- and that
>>is what I was referring to -- not that by being quiet suddenly the
>>world will be plunged into war again (not that it isn't already).
>>
>>Cheers,
>>Rob.
>>
>>On Wed, 2003-08-06 at 17:11, Chris Sherwood wrote:
>>
>>
>>>Hitler is it?
>>>
>>>why is it everytime someone mentions a proper ettiquette, or some
>>>common sense thing that it is immeadiately taken to an extreme..
>>>
>>>is this reasonable behaviour? does it portray us as adults, maybe
>>>adults who have a major chip on our shoulders... all I am saying is if
>>>you feel nasty ... keep it to yourself
>>>
>>>now how does that equate to being like or bringing back hitler?
>>>
>>>
>>>----- Original Message -----
>>>From: "Robert Cummings" <[EMAIL PROTECTED]>
>>>To: "Chris Sherwood" <[EMAIL PROTECTED]>
>>>Cc: <[EMAIL PROTECTED]>
>>>Sent: Wednesday, August 06, 2003 2:04 PM
>>>Subject: Re: [PHP] Stop neurotic posting
>>>
>>>
>>>
>>>
>>>>On Wed, 2003-08-06 at 16:36, Chris Sherwood wrote:
>>>>
>>>>
>>>>>or what does it take to actually give a reasonable answer... if I am
>>>>>
>>>>>
>>>gonna
>>>
>>>
>>>>>be rude I  wont say anything... doesnt any one remember their mother
>>>>>
>>>>>
>>>telling
>>>
>>>
>>>>>them if you dont have anything nice to say dont say anything at all?
>>>>>
>>>>>
>>>>>
>>>>That kind of thinking leads to things like Hitler :| If we never say
>>>>anything then it becomes the norm for people to continue their
>>>>behaviour. Currently the question being debated is what constitutes
>>>>poor behaviour/etiquette within this mailing list. While I agree that
>>>>this forum is primarily for answering questions -- I disagree that it
>>>>is for answering silly little questions that would be common
>>>>knowledge if the asker had bothered to read any tutorials or
>>>>documentation -- most especially when it appears that the poster
>>>>didn't even bother to do any kind of searching for themselves. I mean
>>>>really, questions like "does X do Y" is often as simple as writing 1
>>>>to 5 lines of test code which is probably shorter than the email
>>>>itself and doesn't pollute the mailing list with 5 to 10 replies of
>>>>"yes" or "no".
>>>>
>>>>Cheers,
>>>>Rob.
>>>>--
>>>>.---------------------------------------------.
>>>>| Worlds of Carnage - http://www.wocmud.org   |
>>>>:---------------------------------------------:
>>>>| Come visit a world of myth and legend where |
>>>>| fantastical creatures come to life and the  |
>>>>| stuff of nightmares grasp for your soul.    |
>>>>`---------------------------------------------'
>>>>
>>>>--
>>>>PHP General Mailing List (http://www.php.net/)
>>>>To unsubscribe, visit: http://www.php.net/unsub.php
>>>>
>>>>
>>>>
>>>>
>>>
>>>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php




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

I am new to php and tried to test googlesearch.php file (as attachment) from Chris Petersen. Which invokes nusoap.php file. I have all the necessary class files that nusoap.php included and put in the same directory with googlesearch.php and nusoap.php file. Also I have Google's licence key as well. But when executed googlesearch.php. It only displays the documentation of class.soapclinet.php and nothing else. Could anybody tell me what is the problem? Please help. Thanks,


Daniel


_________________________________________________________________
Get 10Mb extra storage for MSN Hotmail. Subscribe Now! http://join.msn.com/?pgmarket=en-hk
<?
/*

Google API


*/ require_once("nusoap.php");

class GoogleSearchResults {
   var $estimatedTotalCount;
   var $searchTime;
   var $startIndex;
   var $endIndex;
   var $results;
   var $directories;
}
class GoogleSearchResult {
   var $cachedSize;
   var $hostName;
   var $snippet;
   var $summary;
   var $title;
   var $url;
}

function googleSearch($query, $startIndex) {
   $soapclient = new soapclient("GoogleSearch.wsdl", "wsdl");
   $proxy = $soapclient->getProxy();
   $result = $proxy->doGoogleSearch(    "wzMXCPhQFHIoNdE1l1x/hsudArv9AceZ",
                       $query,
                       $startIndex,
                       10,
                       "false",
                       "",
                       "false",
                       "",
                       "latin1",
                       "latin1");

   $returnVal = new GoogleSearchResults();
   $returnVal->estimatedTotalCount = $result["estimatedTotalResultsCount"];
   $returnVal->searchTime = $result["searchTime"];
   $returnVal->startIndex = $result["startIndex"];
   $returnVal->endIndex = $result["endIndex"];
   $rerurnVal->results = array();

   $resultElements = $result["resultElements"];
   for($i=0; $i<count($resultElements); $i++) {
       $entry = new GoogleSearchResult();
       $entry->cachedSize = $resultElements[$i]["cachedSize"];
       $entry->hostName = $resultElements[$i]["hostName"];
       $entry->snippet = $resultElements[$i]["snippet"];
       $entry->summary = $resultElements[$i]["summary"];
       $entry->title = $resultElements[$i]["title"];
       $entry->url = $resultElements[$i]["URL"];
       $returnVal->results[$i] = $entry;
   }
   return $returnVal;
}

?>
--- End Message ---
--- Begin Message ---
The following code works on Win2K, Apache 1.3.27, PHP 4.3.2

$gif = imagecreatefromgif('image.gif');
$w = imagesx($gif);
$h = imagesy($gif);
$jpg = imagecreate($w, $h);
// or $jpg = imagecreatetruecolor($w, $h); but colors are off
imagecopy($pic, $im, 0, 0, 0, 0, $w, $h);
// or imagecopyresampled($jpg, $gif, 0, 0, 0, 0, $w, $h, $w, $h);
imagejpeg($jpg); // also works with imagepng()
imagedestroy($gif);
imagedestroy($jpg);
exit;

don't have 4.3 on my linux box yet so I haven't tested it there

--- End Message ---
--- Begin Message ---
While I am technically capable, having worked with COBOL and perl
extensively (but not at the same time <g>!), I am a newbie to PHP.

I have the basics for a survey application up and running, but need to
be able to highlight one specific piece of text in each of the two main
frame windows, and I'm not entirely sure how to accomplish this with
PHP.

Both frame windows are pulling in HTML documents from a pool of over
14,000 pre-prepared documents, all of which have specific ID values
incorporated as part of the NAME anchor element, for example:

<A NAME="J145-37" ID="IDJ145-37">Thomas Jefferson</A>

<A NAME="W169-157" ID="IDW169-157">George Washington</A>

I have a mysql table that I am using to tell me, at any one point in
time, which specific NAME value should be pointed to in each frame. 
They may or may not be within the same physical HTML document.

If it were the case that I were pointing to Thomas Jefferson in the left
frame and George Washington in the right frame, I would like to be able
to highlight each name so that it is immediately visible within the
surrounding document context.  I would like to minimally use a different
color for the specific name in each frame that I am pointing to.

Because each document is filled with multiple NAME values, each with
it's own separate ID value, theoretically it should be possible to
highlight only the one speicific NAME value I am interested in at a
particular point -- leaving all the other NAME values the same color as
the surrounding text.  Hopefully this is even possible when I am pulling
in the same physical document twice, once in each frame (using separate
PHP programs for the left and right frames).  If the two snippets of
text above were found in the same sentence in the same physical HTML
document, I would want one highlighted in the left frame and the other
highlighted in the right frame.

The mysql table will tell me at any one point which specific ID value
should be highlighted in each frame, but only through a variable name (I
am currently using $resource_nameid_left and $resource_nameid_right for
these two values).  I am already incorporating these values in the URL
pulled into each frame as each URL points to the specified NAME anchor
specifically. 

But I also need to be able to use the ID Selector property of CSS
through PHP, pointing to a variable name.  This is the part that I don't
have any examples for.  Can I do this easily?  Will it require the use
of Javascript?

If anybody has some sample code that will do this, or can point me to
sample code that does this, I would appreciate it very much.

If I have not explained fully what I am seeking, please let me know and
I can elaborate further.

-- Thanks,
   Mary D. Taffet
   Syracuse University
   Ph.D. Student/School of Information Studies
   E-mail:      [EMAIL PROTECTED]
   Web:         http://web.syr.edu/~mdtaffet/

--- End Message ---
--- Begin Message ---
* Thus wrote Matt Anderson ([EMAIL PROTECTED]):
> Hi all,
> 
> I have a fairly advanced question regarding writting modules that create
> persistent resources:
> 
You might want to ask this over in php-dev, most people here dont
deal with the internals of php. 

> I've written a module very similar to the 'de-facto standard' mysql
> implementation, however its developed a strange bug.  Occasionally,
> after working with a persistent connection for a few page calls, php
> seems to 'forget' that its there, without calling the resources' cleanup
> handler.  The eventual result, sence the resource opens a socket
> connection to another server (my module binds another API into php), the
> connections will pile up needlessly.

I think it might have to do with this:

  hashed_identifier_len = strlen("evopvr___") + strlen(user) +
            strlen(passwd) + strlen(host);
  hashed_identifier = (char*) emalloc(hashed_identifier_len);
  sprintf(hashed_identifier, "evopvr_%s_%s_%s", user, passwd, host); 

  your emalloc() needs to add +1 to the allocated memory for the \0 at the
  end of the string of hashed_identifier.   So the next emalloc
  call will allocate the spot where your \0 is so you just lost the
  end of your string of hashed_identifier.


HTH,

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

--- End Message ---
--- Begin Message ---
HI all;
how can i run somthing or a function that only run on every month from the
first untill the second on a specific time:

in other word :
the first two day of every month but it end on like 2pm of the second..

if ( today is 1/of any month untill 2/ of the same month at XX hour )
{ return true}
else
{return false}


thanks
Nabil



--- End Message ---
--- Begin Message ---
look into executing your php script through cron. (Cron is a Unix schedular
and nothing to do with PHP). Or you can use Tash Schedular (on windows
servers, I guess).

Also, check the archives but I think this issue was answered as above.

"Nabil" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> HI all;
> how can i run somthing or a function that only run on every month from the
> first untill the second on a specific time:
>
> in other word :
> the first two day of every month but it end on like 2pm of the second..
>
> if ( today is 1/of any month untill 2/ of the same month at XX hour )
> { return true}
> else
> {return false}
>
>
> thanks
> Nabil
>
>



--- End Message ---
--- Begin Message ---
No i think you get me wrong ...
i have already in my web page some articles that i don't want to desplay on
the first and second of every month at a specific hours...

Please comment


"Nabil" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> HI all;
> how can i run somthing or a function that only run on every month from the
> first untill the second on a specific time:
>
> in other word :
> the first two day of every month but it end on like 2pm of the second..
>
> if ( today is 1/of any month untill 2/ of the same month at XX hour )
> { return true}
> else
> {return false}
>
>
> thanks
> Nabil
>
>



--- End Message ---
--- Begin Message ---
On Thursday 07 August 2003 17:35, Nabil wrote:
> No i think you get me wrong ...
> i have already in my web page some articles that i don't want to desplay on
> the first and second of every month at a specific hours...

Have you looked at the "Date and Time functions"?

-- 
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
------------------------------------------
/*
Ray's Rule of Precision:
        Measure with a micrometer.  Mark with chalk.  Cut with an axe.
*/


--- End Message ---
--- Begin Message ---
Specific Day:
<?
$today = date('j');             // eg  1 - 31
if($today > 2)
        {
        // show
        }
else
        {
        // don't show
        }
?>

Addition of specific time frame of 12noon - 4pm

<?
$today = date('j');             // eg  1 - 31
$hour = date('G');              // eg 0 - 23
if( ($today > 2) && ($hour >= 12 && $hour <= 16) )
        {
        // show
        }
else
        {
        // don't show
        }
?>


Tweak to suit your needs


Justin






On Thursday, August 7, 2003, at 07:35 PM, Nabil wrote:


No i think you get me wrong ...
i have already in my web page some articles that i don't want to desplay on
the first and second of every month at a specific hours...


Please comment


"Nabil" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]
HI all;
how can i run somthing or a function that only run on every month from the
first untill the second on a specific time:


in other word :
the first two day of every month but it end on like 2pm of the second..


if ( today is 1/of any month untill 2/ of the same month at XX hour )
{ return true}
else
{return false}


thanks Nabil





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

---
[This E-mail scanned for viruses]




--- End Message ---
--- Begin Message ---
I'm getting the following error:

PHP Fatal error:  Cannot redeclare () (previously declared in
/path/to/file/functions.inc:19) in /path/to/file/functions.inc on line 0

Anyone have any ideas how a no-name function could be generated?
Line 19 contains:
        function idb_exec_deadlock($sql,$count=0)

There are only two lines before this that contain code (the rest are
comments) and they are:
        if (!$__GEN_HIR_FUNCTIONS_INCLUDE){
        $__GEN_HIR_FUNCTIONS_INCLUDE=1;

TIA
Martin

--- End Message ---
--- Begin Message ---
Hi Martin... I am guessing you have a nested function that is being
redeclared, your error would come from there... Just a guess anyhow...

Joe

> -----Original Message-----
> From: Martin Towell [mailto:[EMAIL PROTECTED] 
> Sent: Thursday, August 07, 2003 2:11 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP] error: cannot redeclare ()
> 
> 
> I'm getting the following error:
> 
> PHP Fatal error:  Cannot redeclare () (previously declared in
> /path/to/file/functions.inc:19) in 
> /path/to/file/functions.inc on line 0
> 
> Anyone have any ideas how a no-name function could be 
> generated? Line 19 contains:
>       function idb_exec_deadlock($sql,$count=0)
> 
> There are only two lines before this that contain code (the rest are
> comments) and they are:
>       if (!$__GEN_HIR_FUNCTIONS_INCLUDE){
>         $__GEN_HIR_FUNCTIONS_INCLUDE=1;
> 
> TIA
> Martin
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 
> 


--- End Message ---
--- Begin Message ---
thnx - I'll see if this help..

-----Original Message-----
From: Joe Harman [mailto:[EMAIL PROTECTED]
Sent: Thursday, 7 August 2003 4:38 PM
To: 'Martin Towell'; [EMAIL PROTECTED]
Subject: RE: [PHP] error: cannot redeclare ()


Hi Martin... I am guessing you have a nested function that is being
redeclared, your error would come from there... Just a guess anyhow...

Joe

> -----Original Message-----
> From: Martin Towell [mailto:[EMAIL PROTECTED] 
> Sent: Thursday, August 07, 2003 2:11 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP] error: cannot redeclare ()
> 
> 
> I'm getting the following error:
> 
> PHP Fatal error:  Cannot redeclare () (previously declared in
> /path/to/file/functions.inc:19) in 
> /path/to/file/functions.inc on line 0
> 
> Anyone have any ideas how a no-name function could be 
> generated? Line 19 contains:
>       function idb_exec_deadlock($sql,$count=0)
> 
> There are only two lines before this that contain code (the rest are
> comments) and they are:
>       if (!$__GEN_HIR_FUNCTIONS_INCLUDE){
>         $__GEN_HIR_FUNCTIONS_INCLUDE=1;
> 
> TIA
> Martin
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 
> 
__________ Information from NOD32 1.468 (20030725) __________

This message was checked by NOD32 for Exchange e-mail monitor.
http://www.nod32.com




--- End Message ---
--- Begin Message ---
From: "Martin Towell" <[EMAIL PROTECTED]>
> I'm getting the following error:
>
> PHP Fatal error:  Cannot redeclare () (previously declared in
> /path/to/file/functions.inc:19) in /path/to/file/functions.inc on line 0
>
> Anyone have any ideas how a no-name function could be generated?
> Line 19 contains:
> function idb_exec_deadlock($sql,$count=0)

Make sure you're not including/requiring functions.inc more than once. This
is usually what causes these kind of errors.

Also, I hope you are denying access to .inc files on your server, otherwise
your PHP code will be served up as plain text.

---John Holmes...


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

For over a year now, I've been subscribed to this list through my main email account. My ISP has anti-spam stuff on the server which prepends the subject of anything it considers spam with 'SPAM: '.

As of 4am this morning (Melb, Australia), EVERY message to this list has been flagged as spam.

Not good. It permanently screws up the subject lines of all emails, and becomes a pain in the ass for threading, replying, forwarding, etc.


Whilst I'm currently grilling the ISP to see if anything has changed at their end, I'm also wondering if anything has changed on the lists.php.net mail server, or DNS, or anything like that in the last 12 hours which would cause such a problem.



FWIW, I haven't noticed any other lists or emails being wrongly flagged, just this one.



TIA, Justin


--- End Message ---
--- Begin Message ---
* Thus wrote Justin French ([EMAIL PROTECTED]):
> Hi,
> 
> For over a year now, I've been subscribed to this list through my main 
> email account.  My ISP has anti-spam stuff on the server which prepends 
> the subject of anything it considers spam with 'SPAM: '.
> 
> As of 4am this morning (Melb, Australia), EVERY message to this list 
> has been flagged as spam.

hm.. intersting you brought this up. 'Ryan A' had mentioned that
the list is Black listed at spam cop.  I think the problem has to
do with that person from @hanmir.com. 

there is a person subscribe to the list (from hanmir.com), of whom
had spammed the list, who's mailbox is full. And every post that
gets sent to php-general is returned, to the user that posted the
message, from [EMAIL PROTECTED] saying the mailbox is full.

My theory is that the administrator of the domain/email/system has
no clue what he is doing and has reported everyone that has sent
mail as a spammer.

This is rather disturbing!

I, as well as others, have tried to get the attention of someone who
has control over this list about this '@hanmir.com' person that is
subscribed to the list to remove him.  This has been going on for
several weeks now.

I'm bcc'ing this to [EMAIL PROTECTED], hopefully someone over there
can help the list out with this issue.

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

--- End Message ---
--- Begin Message ---
* Thus wrote Curt Zirzow ([EMAIL PROTECTED]):
> 
> I'm bcc'ing this to [EMAIL PROTECTED], hopefully someone over there
> can help the list out with this issue.

well, I guess we are on are own, the bcc bounced :/


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

--- End Message ---
--- Begin Message ---
From: "Curt Zirzow" <[EMAIL PROTECTED]>

> well, I guess we are on are own, the bcc bounced :/

what about [EMAIL PROTECTED] or [EMAIL PROTECTED] ?

regards,

Juan

--- End Message ---
--- Begin Message ---
Hey is every one getting a returned message from
[EMAIL PROTECTED]
 
Joe Harman


 

--- End Message ---
--- Begin Message ---
Yep - I did with me previous email
And I guess I'll get one with this email too :/

-----Original Message-----
From: Joe Harman [mailto:[EMAIL PROTECTED]
Sent: Thursday, 7 August 2003 4:43 PM
To: [EMAIL PROTECTED]
Subject: [PHP] [EMAIL PROTECTED]


Hey is every one getting a returned message from
[EMAIL PROTECTED]
 
Joe Harman


 
__________ Information from NOD32 1.468 (20030725) __________

This message was checked by NOD32 for Exchange e-mail monitor.
http://www.nod32.com




--- End Message ---
--- Begin Message ---
I just got two,
Expecting two more now....

"Joe Harman" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hey is every one getting a returned message from
> [EMAIL PROTECTED]
>
> Joe Harman
>
>
>
>



--- End Message ---
--- Begin Message ---
> preg_replace("|<item>.*?$file.*?</item>|si","",$contents)
> <news>
>  <item>
>   <title>fhh</title>
>   <date>1060205191</date>
>   <text>hhh</text>
>   <file>xml/news/1060205191.xml</file>
>  </item>
>  <item>
>   <title>fgjghjh</title>
>   <date>1060205186</date>
>   <text>fgjh</text>
>   <file>xml/news/1060205186.xml</file>
>  </item>
>  <item>
>   <title>fgjhh</title>
>   <date>1060205182</date>
>   <text>fghh</text>
>   <file>xml/news/1060205182.xml</file>
>  </item>
> </news>
Not sure if I understand you correct but
the way you wrote your replace pattern the result should be 
<news></news>.
If you want just the file to be replaced you have to use something like
preg_replace("|<item>.*?($file).*?</item>|si",'\\1',$contents)

Regards
Stefan Langer

--- End Message ---
--- Begin Message ---
> Not sure if I understand you correct but
> the way you wrote your replace pattern the result should be
> <news></news>.
> If you want just the file to be replaced you have to use something like
> preg_replace("|<item>.*?($file).*?</item>|si",'\\1',$contents)
>

no, i want just the whole <item></item> replaced for that particular file.
the pattern i wrote shouldn't... doesn't touch the <news> section at all.

wouldn't the pattern you wrote replace the whole <item></item> with the file
tho?



--- End Message ---
--- Begin Message ---
$contents = preg_replace( "|<item>.*?".$file.".*?</item>|si", "",
$contents );

okay, so i figured out that it's matching the first occurence of <item>
which will always be the first record and then going on to match the $file
and deleting everything between. obviously not what i want.

without giving <item> a unique attribute and without preg_match_all and
looping through them all, is there any other way to do this? make it find
the first occurence of <item> previous to $file, rather than from the start?

i hope this makes sense, and is a little clearer than i've been so far...



--- End Message ---
--- Begin Message --- Do you need to use ".*?"? If there will be only white characters, use \s* instead.

skate wrote:

$contents = preg_replace( "|<item>.*?".$file.".*?</item>|si", "",
$contents );

okay, so i figured out that it's matching the first occurence of <item>
which will always be the first record and then going on to match the $file
and deleting everything between. obviously not what i want.

without giving <item> a unique attribute and without preg_match_all and
looping through them all, is there any other way to do this? make it find
the first occurence of <item> previous to $file, rather than from the start?

i hope this makes sense, and is a little clearer than i've been so far...





--- End Message ---
--- Begin Message ---

> Do you need to use ".*?"? If there will be only white characters, use
> \s* instead.
>


unfortunately there's some content either side of $file before <item></item>
this content is different for each item, so i can't define it in the
pattern.



--- End Message ---
--- Begin Message --- And what about [^>]* -if there are no html tags

skate wrote:


Do you need to use ".*?"? If there will be only white characters, use
\s* instead.




unfortunately there's some content either side of $file before <item></item> this content is different for each item, so i can't define it in the pattern.





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

 I am Dipesh from BG Broadband, India.. I have configured freetds with php
as well as apache.

I am also able to connect to the sql server 2000 server through the tsql
utility of the freetds. But when I am connecting with the php script by the
mssql_connect or sybase_connect function then the error log shows that the
connection is refused or the user is denied permission.

The same thing done manually works but via php doesn't

Can u help me

Thanx in advance

Regards,
Dipesh


--- End Message ---
--- Begin Message ---
Could this have anything to do with our being registered as spammers?

On Wednesday 06 Aug 2003 9:59 am, [EMAIL PROTECTED] wrote:
> Do you recall during the height of the War in March?
> I posted a simple joke - got one (positive) reply before getting kicked off
> the list by Mr Lerdorf himself.
>
> Now all of a sudden my inbox is FILLED with JUNK!  How many of you flamers
> are getting kicked off the (*&%^$^%&% list?
>
> At least I made a few people laugh!
>
> Oh - Apache vs. IIS, in case you forgot.
>
> Go ahead and kick me off the list again, moron


--- End Message ---
--- Begin Message ---
is there such a thing? perl to php converter?
i will try to convert movabletype to php, if ever.

--
Thank you,
Louie Miranda ([EMAIL PROTECTED])




--- End Message ---
--- Begin Message ---
I use a bcc to a specific email account. Not pretty but it works.

Here's a snippet:

        /* To send HTML mail, you can set the Content-type header. */
        $headers  = "MIME-Version: 1.0\r\n";
        $headers .= "Content-type: text/html; charset=iso-8859-15\r\n";

        /* additional headers */
        $headers .= "From: $COMPANY_INFORMAL_NAME <$COMPANY_SALES_EMAIL>\r\n";

        // Keep a copy";
        $headers .= "Bcc: $COMPANY_SALES_EMAIL\r\n";

        /* and now mail it */
        return ( mail($to, $subject, $message, $headers) );

HTH

Nick

On Sunday 03 Aug 2003 9:46 pm, RiGe wrote:
> Is there possible to log outgoing mails sent via mail() function? I need to
> know, when, which script (can be path to php file on server) and receipt of
> mail that was sent.
>
> Is there possible?
>
> Thanx.
>
> RiGe


--- End Message ---
--- Begin Message ---
I'm using jpgraph or GD for charts making, and the picture is correctly made
in cache or in directory and there is no error log but when I use it in php
page ( <IMG src=graph.php >, I have a no-pict icon instead of my graph.



For information the graph.php script :

<%

$sitename="scafoot"; include("/var/www/jpgraph/src/jpgraph.php");

include("/var/www/jpgraph/src/jpgraph_line.php");

require("./connect.php");



$graph = new Graph(400,250,"auto"); $graph->SetScale("textlin");
$graph->img->SetMargin(40,20,20,40);



$sql="select idstat,week(date) as week,count(*) as count from pages where
host like '%$sitename%' group by week"; condb($sql,$result);
$ydata=array(0); $xdata=array(0);

while($row=mysql_fetch_array($result))

{

      array_push($xdata,$row[week])

      array_push($ydata,$row[count])

}

$graph->yaxis->title->Set("freq");

$graph->xaxis->title->Set("semaine");



$graph->xaxis->SetTrickLabels($xdata);

$lineplot=new LinePlot($ydata);

$lineplot->SetColor("blue");



$graph->Add($lineplot);

Header("Content-type: image/png");

$graph->Stroke();

%>









--- End Message ---
--- Begin Message ---
hello php-general,

i found this thread in the mailing-list archive:
http://marc.theaimsgroup.com/?l=php-general&m=104182777004472&w=2

to summarize: if you call a static method FooClass::foo() from within
an object-method (for example:

class BarClass {

  function bar() {
    Foo::foo();
  }
  
}
$obj = new BarClass;
$obj->bar();

)


FooClass::foo() will have a reference "$this" defined that is a
reference to $obj.


i noticed recently that this still works in the beta1 of php5.

my question: does anybody have a clue if this is a well-known and
supported feature? or is it just a side-effect and using it can be a
bad design-decision in the long run?

greetings
messju


--- End Message ---
--- Begin Message ---
On Thu, Aug 07, 2003 at 03:57:16AM -0500, Daryl Meese wrote:
> $this->_____ is a well known reference method supported in a large number of
> languages: php, javascript, and java for example.  Feel free to use it
> without reservation (IMHO) because it should be there forever.

i know that. i mean the special case:

$a = FooClass::foo();  // inside foo() there is no $this
[there is no $this in nearly any languange on this planet in a *static* method]

but in php, if i do the same call:
$a = FooClass::foo();

from inside a method of an object that is not necessarily a member of
the FooClass, nontheless FooClass::foo() knows $this as a reference to
an object (the calling object).

that *is* special. and i don't know a language that behaves in that
way except of php. but i know this way can have it's merits, though,
that's why i asked.

greetings
messju
 
> Daryl
> 
> -----Original Message-----
> From: messju mohr [mailto:[EMAIL PROTECTED]
> Sent: Thursday, August 07, 2003 3:42 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP] static method and $this
> 
> 
> hello php-general,
> 
> i found this thread in the mailing-list archive:
> http://marc.theaimsgroup.com/?l=php-general&m=104182777004472&w=2
> 
> to summarize: if you call a static method FooClass::foo() from within
> an object-method (for example:
> 
> class BarClass {
> 
>   function bar() {
>     Foo::foo();
>   }
> 
> }
> $obj = new BarClass;
> $obj->bar();
> 
> )
> 
> 
> FooClass::foo() will have a reference "$this" defined that is a
> reference to $obj.
> 
> 
> i noticed recently that this still works in the beta1 of php5.
> 
> my question: does anybody have a clue if this is a well-known and
> supported feature? or is it just a side-effect and using it can be a
> bad design-decision in the long run?
> 
> greetings
> messju
> 
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php

--- End Message ---
--- Begin Message ---
Dear all
I had write a script like this :

$link = "page.php?day=$day&month=$month&year=$year";

when i click on the link, it should pass the parameter to "page.php" with
$month and $year variables.
It actually works fine in php4.2.1, but when i went to other office which
got php5.0 above installed, using the same script, but it won't pass any
parameters to page.php! How come?

I heard there is something to set in the php5.0's php.ini before i can do
so, is that right?

Please could anyone give me a hand on this?

Thx alot

Jack



--- End Message ---
--- Begin Message ---
I had the same problem a couple of weeks ago.

register_globals=On
magic_quotes_runtime=Off

Ben


"Jack" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Dear all
> I had write a script like this :
>
> $link = "page.php?day=$day&month=$month&year=$year";
>
> when i click on the link, it should pass the parameter to "page.php" with
> $month and $year variables.
> It actually works fine in php4.2.1, but when i went to other office which
> got php5.0 above installed, using the same script, but it won't pass any
> parameters to page.php! How come?
>
> I heard there is something to set in the php5.0's php.ini before i can do
> so, is that right?
>
> Please could anyone give me a hand on this?
>
> Thx alot
>
> Jack
>
>



--- End Message ---
--- Begin Message --- Jack wrote:
Dear all
I had write a script like this :

$link = "page.php?day=$day&month=$month&year=$year";

when i click on the link, it should pass the parameter to "page.php" with
$month and $year variables.
It actually works fine in php4.2.1, but when i went to other office which
got php5.0 above installed, using the same script, but it won't pass any
parameters to page.php! How come?

I heard there is something to set in the php5.0's php.ini before i can do
so, is that right?

Please could anyone give me a hand on this?

IIRC, a default installation does not automatically make global variable ou of GET parameters.

try:
<?
echo $_GET['day'].'<br />';
echo $_GET['month'].'<br />';
echo $_GET['year'].'<br />';
?>

I think it's called GPC in the php config file.

Kae


--- End Message ---
--- Begin Message ---
hello,
i have a very short question. The function mail() stopped working suddenly. It returns 
true, reports no error, but the e-mail message is not sent to any e-address. Our 
provider has no idea. There were not made any changes in PHP and Apache config, the 
function just stopped working another day. Do you have any idea, what could be the 
problem?
PHP config. is available here.

Thanks for any help.

Milan Introvic

--- End Message ---
--- Begin Message ---
On Thursday 07 August 2003 17:20, photogames.net wrote:

> i have a very short question. The function mail() stopped working suddenly.
> It returns true, reports no error, but the e-mail message is not sent to
> any e-address. Our provider has no idea. There were not made any changes in
> PHP and Apache config, the function just stopped working another day. Do
> you have any idea, what could be the problem? PHP config. is available
> here.

Ask your provider to check the mail logs. Or find a replacement for mail() 
from www.phpclasses.org.

-- 
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
------------------------------------------
/*
Reality does not exist -- yet.
*/


--- End Message ---
--- Begin Message ---
You should have a look to the widget where you display the field.
Sometimes an option is display stars.
HTH
Pascal Miquet

Le mer 06/08/2003 à 18:34, John Nichel a écrit :
> Is it possible to 'star out' the standard input (STDIN)?  I'm having 
> users enter a password in, and would like it to display ****** as they 
> are typing it in.  Right now, I'm using....
> 
> $pass = rtrim ( fgets ( STDIN ) );
> 
> And it just displays what they are typing.
> 
> -- 
> By-Tor.com
> It's all about the Rush
> http://www.by-tor.com
> 



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

        I am Dipesh from Iqara Broadband. I am just now trying to configure the
Freetds with PHP on Red Hat Linux 7.2

        I have configured PHP with all options including Sybase as it is shown
below;

'./configure' '--with-apxs=/usr/local/apache/bin/apxs'
'--with-sybase=/usr/local/freetds0.53/' '--with-odbc' '--with-mysql'
'--with-ldap' '--with-pgsql'
'--with-oci8=/home/oracle/m01/app/oracle/product/8.1.7/' '--with-gbdm'
'--enable-dbase' '--enable-calendar' '--enable-bcmath' '--enable-filepro'
'--enable-track-vars' '--enable-force-cgi-redirect'

        as it should be.

        All other databases like mysql, Oracle and pgsql are successfully tested
from php. but the problem is with MS SQL server.

        Through the utility tsql provided by freetds we can manually connect to the
SQL server by providing the user name and password

        But when I am writing a php script like

        $connect = mssql_connect("172.16.3.36","dips","dips") or die("\ncant
connect");

        then it can't connect and the error in the log is saying that Connection is
refused.

        Kindly help if u know anyting regarding this.


Regards,
Dipesh


--- End Message ---
--- Begin Message ---
Hello NG !

I am using php-4.3.2 and gd-2.0.15 and when using ImageCreateTrueColor, my
server cowardly refuses the show any image, instead he tells me, that the
image dimensions were invalid ... anyone any idea ?

please answer to ng or ia mail, need help !!!

Greetings

Kai



--- End Message ---
--- Begin Message ---

Or access you variables via $_GET.

$varname = $_GET['varname'];

-Mike


On Thu, 7 Aug 2003, Ben wrote:

> Date: Thu, 7 Aug 2003 10:25:57 +0100
> From: Ben <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED], [EMAIL PROTECTED]
> Subject: [PHP-WIN] Re: Can't Pass variable to other page
>
> I had the same problem a couple of weeks ago.
>
> register_globals=On
> magic_quotes_runtime=Off
>
> Ben
>
>
> "Jack" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > Dear all
> > I had write a script like this :
> >
> > $link = "page.php?day=$day&month=$month&year=$year";
> >
> > when i click on the link, it should pass the parameter to "page.php" with
> > $month and $year variables.
> > It actually works fine in php4.2.1, but when i went to other office which
> > got php5.0 above installed, using the same script, but it won't pass any
> > parameters to page.php! How come?
> >
> > I heard there is something to set in the php5.0's php.ini before i can do
> > so, is that right?
> >
> > Please could anyone give me a hand on this?
> >
> > Thx alot
> >
> > Jack
> >
> >
>
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>

--- End Message ---
--- Begin Message ---
Hi all,
           I have integerated php-4.3.2 with thttpd-2.21b and made a final
executable.After running thttpd sever
Iam  trying to access some of files residing in /home/data dir.
While trying to access there exception is thrown in my browser.

"Warning: Unknown(/home/amar/data/html/test.php): failed to open stream:
Permission denied in Unknown on line 0

Warning: (null)(): Failed opening '/home/amar/data/html/test.php' for
inclusion (include_path='.:/usr/local/lib/php') in Unknown on line 0"
(I have also included ".:/usr/local/lib/php" in the php.ini file also)

After making those changes also i am facing this problem.
Can some help me in this.
Thanks
Regards
Amarnath R






--- End Message ---
--- Begin Message --- Does the thttpd process have pemissions to read /home/amar/data/html/test.php ?

Amarnath R wrote:

Hi all,
           I have integerated php-4.3.2 with thttpd-2.21b and made a final
executable.After running thttpd sever
Iam  trying to access some of files residing in /home/data dir.
While trying to access there exception is thrown in my browser.

"Warning: Unknown(/home/amar/data/html/test.php): failed to open stream:
Permission denied in Unknown on line 0

Warning: (null)(): Failed opening '/home/amar/data/html/test.php' for
inclusion (include_path='.:/usr/local/lib/php') in Unknown on line 0"
(I have also included ".:/usr/local/lib/php" in the php.ini file also)

After making those changes also i am facing this problem.
Can some help me in this.
Thanks
Regards
Amarnath R








--- End Message ---
--- Begin Message ---
In article <[EMAIL PROTECTED]>, 
[EMAIL PROTECTED] says...
> 
> 
> 
> > Shell side:
> > - must be readable and executable by user (apache or perhaps everyone)
> > - suid bit work only for programs, not scripts I think
> > - shell can only execute cmds for which it's effective user has
> > sufficient permissions
> >
> > Try this (as root on webserver), if you can login as apache.
> > If you can't login as apache, log as a normal user (not root)
> > # su - apache
> > $ cd /path/to/script
> > $ ./myscript.sh
> > You will probably see errors here.
> 
> 
> As Juan suggested I checked /var/log/messages. The shell script I'm trying
> to run is a script that restarts our web content filter. In the script it
> removes the pid file so it will be recreated when the application is started
> again. The error I'm getting in the message log is "dansguardian: Error
> creating/opening pid file." Any ideas on what to do?
> 
> Thanks for your help,
> Rod
> 
> 
Check whether the user that the webserver runs as has appropriate  
permissions in the relevant directory?

-- 
Quod subigo farinam

$email =~ s/oz$/au/o;
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet?

--- End Message ---
--- Begin Message ---
In article <[EMAIL PROTECTED]>, 
[EMAIL PROTECTED] says...
> > It's not usless if you read the page. 
> > [EMAIL PROTECTED]
> 
> As I said, the page is useless. This doesn't work either.
> 
> J.
> 

You may be trying to unsubscribe from a different email address that the 
one used originally to subscribe. The original subscribe confirmation, if 
you kept it, should have the address in it. Failing that, have a look at 
the headers of any message from the list for a clue as to the subscribed 
address. I'd be more specific, but I read from the newsgroup so don't have 
an appropriate set of headers available to refer to.

-- 
Quod subigo farinam

A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet?

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

> Otherwise, a year down the line, you find yourself stuck with a thing
> that needs a small modification which will take you hours and hours and
> hours and probably turn your little project into spaghetti (speaking
> from experience).

        That's probably some good advice, and something for me to think about.  I
have a habbit of learning something new, and then overusing it to death...
I'm sure I'm guitly of making spaghetti.

-Dan Joseph


--- End Message ---

Reply via email to