[PHP] Re: Question about losing port number

2011-09-26 Thread Shawn McKenzie
On 09/26/2011 05:45 PM, vince chan wrote: > Hi: > I have a general question about PHP: > So basically I have a link, and I want the href to be absolute., so I > do 'https://' . $_SERVER['HTTP_HOST'] . '/login' ; this gives me > https://127.0.0.1/login on my local; however, what i really want is >

[PHP] Re: Question about news.php.net

2010-09-16 Thread MikeB
MikeB wrote: Daniel Brown wrote: On Mon, Sep 13, 2010 at 19:51, MikeB wrote: As part of the bug report I included a link to an image of my nntp config. I saw that, thanks. I'll look into creating a mirror of the news server, as well, for NNTP-only access. I won't lie and say that it's a prio

[PHP] Re: Question about news.php.net

2010-09-15 Thread MikeB
Gary wrote: MikeB wrote: I understand that the news server is based on a mailing list, but I can't handle another high-volume source dumping stuff into my email (even if I filter it into a separate folder) so I am trying to subscribe through the news group. However, getting access seems to be h

Re: [PHP] Re: Question about template systems

2009-03-05 Thread Nathan Nobbe
On Mar 5, 2009, at 4:16 AM, Robert Cummings wrote: On Thu, 2009-03-05 at 03:08 -0800, Michael A. Peters wrote: Robert Cummings wrote: function hiddenInput($document,$name,$value) { $input = $document->createElement("input"); $input->setAttribute("type","hidden"); $input->setAttri

Re: [PHP] Re: Question about template systems

2009-03-05 Thread Michael A. Peters
Robert Cummings wrote: Is there a reason I shouldn't be doing it that way? I didn't say you shouldn't. It's just expensive on every page request to regenerate a document node by node. it also strikes me as tedious :/ It's definitely tedious - but I end up writing functions that do the tedi

Re: [PHP] Re: Question about template systems

2009-03-05 Thread Robert Cummings
On Thu, 2009-03-05 at 03:08 -0800, Michael A. Peters wrote: > Robert Cummings wrote: > > >> > >> function hiddenInput($document,$name,$value) { > >> $input = $document->createElement("input"); > >> $input->setAttribute("type","hidden"); > >> $input->setAttribute("name",$name); >

Re: [PHP] Re: Question about template systems

2009-03-05 Thread Michael A. Peters
Robert Cummings wrote: >> >> function hiddenInput($document,$name,$value) { >> $input = $document->createElement("input"); >> $input->setAttribute("type","hidden"); >> $input->setAttribute("name",$name); >> $input->setAttribute("value",$value); >> return($input); >> } >> >

Re: [PHP] Re: Question about template systems

2009-03-05 Thread Robert Cummings
On Thu, 2009-03-05 at 02:04 -0800, Michael A. Peters wrote: > Robert Cummings wrote: > > On Wed, 2009-03-04 at 18:01 -0800, Michael A. Peters wrote: > >> Robert Cummings wrote: > >>> On Wed, 2009-03-04 at 15:21 -0800, Michael A. Peters wrote: > Robert Cummings wrote: > > > To punt wha

Re: [PHP] Re: Question about template systems

2009-03-05 Thread Michael A. Peters
Robert Cummings wrote: On Wed, 2009-03-04 at 18:01 -0800, Michael A. Peters wrote: Robert Cummings wrote: On Wed, 2009-03-04 at 15:21 -0800, Michael A. Peters wrote: Robert Cummings wrote: To punt what is repeated over and over during runtime to a single compilation phase when building the t

Re: [PHP] Re: Question about template systems

2009-03-05 Thread Robert Cummings
On Wed, 2009-03-04 at 21:42 -0700, Nathan Nobbe wrote: > On Wed, Mar 4, 2009 at 7:01 PM, Michael A. Peters wrote: > > > echoing html involves mixing html and php. > > Using an XML class (like DOMDocument) to build the document does not. > > > ive actually written a little templating system which

Re: [PHP] Re: Question about template systems

2009-03-05 Thread Robert Cummings
On Wed, 2009-03-04 at 18:01 -0800, Michael A. Peters wrote: > Robert Cummings wrote: > > On Wed, 2009-03-04 at 15:21 -0800, Michael A. Peters wrote: > >> Robert Cummings wrote: > >> > >>> To punt what is repeated over and over during runtime to a single > >>> compilation phase when building the tem

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Nathan Nobbe
On Wed, Mar 4, 2009 at 7:01 PM, Michael A. Peters wrote: > Robert Cummings wrote: > >> On Wed, 2009-03-04 at 15:21 -0800, Michael A. Peters wrote: >> >>> Robert Cummings wrote: >>> >>> To punt what is repeated over and over during runtime to a single compilation phase when building the temp

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Michael A. Peters
Robert Cummings wrote: On Wed, 2009-03-04 at 15:21 -0800, Michael A. Peters wrote: Robert Cummings wrote: To punt what is repeated over and over during runtime to a single compilation phase when building the template target. To simplify the use of parameters so that they can be used in arbitra

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Robert Cummings
On Wed, 2009-03-04 at 15:21 -0800, Michael A. Peters wrote: > Robert Cummings wrote: > > > > > To punt what is repeated over and over during runtime to a single > > compilation phase when building the template target. To simplify the use > > of parameters so that they can be used in arbitrary ord

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Michael A. Peters
Robert Cummings wrote: To punt what is repeated over and over during runtime to a single compilation phase when building the template target. To simplify the use of parameters so that they can be used in arbitrary order with default values. To allow for the encapsulation of complex content in t

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Robert Cummings
On Wed, 2009-03-04 at 12:15 -0700, Nathan Nobbe wrote: > On Wed, Mar 4, 2009 at 11:51 AM, Robert Cummings wrote: > > > On Wed, 2009-03-04 at 12:46 -0600, Shawn McKenzie wrote: > > > Robert Cummings wrote: > > > > On Wed, 2009-03-04 at 10:55 -0600, Shawn McKenzie wrote: > > > >> Robert Cummings wro

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Nathan Nobbe
On Wed, Mar 4, 2009 at 11:51 AM, Robert Cummings wrote: > On Wed, 2009-03-04 at 12:46 -0600, Shawn McKenzie wrote: > > Robert Cummings wrote: > > > On Wed, 2009-03-04 at 10:55 -0600, Shawn McKenzie wrote: > > >> Robert Cummings wrote: > > >>> On Tue, 2009-03-03 at 21:18 -0600, Shawn McKenzie wrote

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Robert Cummings
On Wed, 2009-03-04 at 12:46 -0600, Shawn McKenzie wrote: > Robert Cummings wrote: > > On Wed, 2009-03-04 at 10:55 -0600, Shawn McKenzie wrote: > >> Robert Cummings wrote: > >>> On Tue, 2009-03-03 at 21:18 -0600, Shawn McKenzie wrote: > Matthew Croud wrote: > > Hello, > > > > First

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Shawn McKenzie
Robert Cummings wrote: > On Wed, 2009-03-04 at 10:55 -0600, Shawn McKenzie wrote: >> Robert Cummings wrote: >>> On Tue, 2009-03-03 at 21:18 -0600, Shawn McKenzie wrote: Matthew Croud wrote: > Hello, > > First post here, I'm in the process of learning PHP , I'm digesting a > few

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Robert Cummings
On Wed, 2009-03-04 at 10:55 -0600, Shawn McKenzie wrote: > Robert Cummings wrote: > > On Tue, 2009-03-03 at 21:18 -0600, Shawn McKenzie wrote: > >> Matthew Croud wrote: > >>> Hello, > >>> > >>> First post here, I'm in the process of learning PHP , I'm digesting a > >>> few books as we speak. > >>>

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Shawn McKenzie
Robert Cummings wrote: > On Tue, 2009-03-03 at 21:18 -0600, Shawn McKenzie wrote: >> Matthew Croud wrote: >>> Hello, >>> >>> First post here, I'm in the process of learning PHP , I'm digesting a >>> few books as we speak. >>> I'm working on a content heavy website that provides a lot of >>> informa

Re: [PHP] Re: Question about template systems

2009-03-04 Thread Robert Cummings
On Tue, 2009-03-03 at 21:18 -0600, Shawn McKenzie wrote: > Matthew Croud wrote: > > Hello, > > > > First post here, I'm in the process of learning PHP , I'm digesting a > > few books as we speak. > > I'm working on a content heavy website that provides a lot of > > information, a template system w

RE: [PHP] Re: Question about template systems

2009-03-03 Thread Chetan Rane
more research on what is Code Injection and how to avoid it. From: Shawn McKenzie [mailto:nos...@mckenzies.net] Sent: Wednesday, March 04, 2009 9:05 AM To: php-general@lists.php.net Subject: [PHP] Re: Question about template systems Shawn McKenzie wrote: > Matthew Croud wrote: >> He

[PHP] Re: Question about template systems

2009-03-03 Thread Shawn McKenzie
Shawn McKenzie wrote: > Matthew Croud wrote: >> Hello, >> >> First post here, I'm in the process of learning PHP , I'm digesting a >> few books as we speak. >> I'm working on a content heavy website that provides a lot of >> information, a template system would be great and so i've been looking >>

[PHP] Re: Question about template systems

2009-03-03 Thread Shawn McKenzie
Matthew Croud wrote: > Hello, > > First post here, I'm in the process of learning PHP , I'm digesting a > few books as we speak. > I'm working on a content heavy website that provides a lot of > information, a template system would be great and so i've been looking > at ways to create dynamic data

Re: [PHP] Re: Question about template systems

2009-03-03 Thread Ashley Sheridan
On Tue, 2009-03-03 at 20:53 +0100, Martin Zvarík wrote: > Matthew Croud napsal(a): > > Hello, > > > > First post here, I'm in the process of learning PHP , I'm digesting a > > few books as we speak. > > I'm working on a content heavy website that provides a lot of > > information, a template sys

[PHP] Re: Question about template systems

2009-03-03 Thread Martin Zvarík
Matthew Croud napsal(a): Hello, First post here, I'm in the process of learning PHP , I'm digesting a few books as we speak. I'm working on a content heavy website that provides a lot of information, a template system would be great and so i've been looking at ways to create dynamic data with

[PHP] Re: Question about version control.. sorta..

2008-12-31 Thread Nathan Rixham
TG wrote: Ok.. so I know about CVS and SVN and unfortunately haven't had as much experience with them as I'd like. I've used them, but always in a really basic sense and always on systems that have already been set up. A friend recently mentioned GIT ( http://git.or.cz/ ) too. But here's my

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Dan Joseph
On Wed, Oct 22, 2008 at 2:29 PM, Stut <[EMAIL PROTECTED]> wrote: > > Never any issues this way? They always run without a hitch? >> > > Not had any issues to far, and it's being used on some pretty busy sites > and various PHP versions and several different web servers. > > Terrific! Thanks for

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Stut
On 22 Oct 2008, at 09:35, Jochem Maas wrote: Stut schreef: On 22 Oct 2008, at 00:22, Jochem Maas wrote: Stut schreef: I use destructors to update dirty objects in memcache. care to eloborate ... sounds interesting. Nothing complicated. The core objects in my application are all cached i

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Stut
On 22 Oct 2008, at 14:42, Dan Joseph wrote: On Tue, Oct 21, 2008 at 5:14 PM, Stut <[EMAIL PROTECTED]> wrote: When a script ends everything is released (with some small exceptions), thus also all references to instances of classes. Thus AFAIK a deconstructor will always be called at the end of

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Eric Butera
On Wed, Oct 22, 2008 at 9:42 AM, Dan Joseph <[EMAIL PROTECTED]> wrote: > On Tue, Oct 21, 2008 at 5:14 PM, Stut <[EMAIL PROTECTED]> wrote: > >> >> When a script ends everything is released (with some small exceptions), thus also all references to instances of classes. Thus AFAIK a dec

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Dan Joseph
On Tue, Oct 21, 2008 at 5:14 PM, Stut <[EMAIL PROTECTED]> wrote: > > >>> When a script ends everything is released (with some small exceptions), >>> thus also all references to instances of classes. >>> Thus AFAIK a deconstructor will always be called at the end of script >>> execution. >>> >>> >>

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Jochem Maas
Stut schreef: > On 22 Oct 2008, at 00:22, Jochem Maas wrote: >> Stut schreef: >>> I use destructors to update dirty objects in memcache. >> >> care to eloborate ... sounds interesting. > > Nothing complicated. The core objects in my application are all cached > in memcache. If anything changes in

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Stut
On 22 Oct 2008, at 00:22, Jochem Maas wrote: Stut schreef: I use destructors to update dirty objects in memcache. care to eloborate ... sounds interesting. Nothing complicated. The core objects in my application are all cached in memcache. If anything changes in an object it changes an int

Re: [PHP] Re: Question about __destruct()

2008-10-21 Thread Jochem Maas
Stut schreef: > On 21 Oct 2008, at 22:08, Jochem Maas wrote: >> Mike van Riel schreef: >>> Dan Joseph wrote: Hi, I want to make sure I completely understand __destruct() and when its hit... Understand that it will run if all references to a particular object are >

Re: [PHP] Re: Question about __destruct()

2008-10-21 Thread Stut
On 21 Oct 2008, at 22:08, Jochem Maas wrote: Mike van Riel schreef: Dan Joseph wrote: Hi, I want to make sure I completely understand __destruct() and when its hit... Understand that it will run if all references to a particular object are removed, but is that also true when a page ends

Re: [PHP] Re: Question about __destruct()

2008-10-21 Thread Jochem Maas
Mike van Riel schreef: > Dan Joseph wrote: >> Hi, >> >> I want to make sure I completely understand __destruct() and when its >> hit... >> >> Understand that it will run if all references to a particular object are >> removed, but is that also true when a page ends its execution? >> >> Example, I c

[PHP] Re: Question about __destruct()

2008-10-21 Thread Mike van Riel
Dan Joseph wrote: Hi, I want to make sure I completely understand __destruct() and when its hit... Understand that it will run if all references to a particular object are removed, but is that also true when a page ends its execution? Example, I call a database class. It constructs, connects,

[PHP] Re: question about <<

2008-09-30 Thread Ross McKay
On Tue, 30 Sep 2008 12:48:35 +0800, LKSunny wrote: >i want on inner EOF do something, calculate and call function ? can not ? if >yes, how to ? Same way as you do with "" strings. e.g. bar()} ENDHELLO; } } $foo = new foo(); $foo->hello(); ?> -- Ross McKay, Toronto, NSW Australia "Let the la

[PHP] Re: question about validation and sql injection

2008-05-15 Thread Chris W
Sudhakar wrote: A) validating username in php If you do what needs to be done to prevent sql injection, it doesn't matter what you let users have for their user name. B) preventing sql injection htmlentities this has nothing to do with sql injection it just is needed so when you prin

[PHP] Re: question about linux editor

2008-03-25 Thread Ross McKay
On Tue, 25 Mar 2008 11:28:07 +0900, Sudhakar wrote: >i need to connect to the linux server using an editor. can anyone suggest >which would be an ideal linux editor to connect to the server. Geany - http://geany.uvena.de/ Also look at: Quanta Plus - http://quanta.kdewebdev.org/ Bluefish - http:

[PHP] Re: question about linux editor

2008-03-25 Thread Nilesh Govindrajan
Sudhakar wrote: i need to connect to the linux server using an editor. can anyone suggest which would be an ideal linux editor to connect to the server. apart from the ip address, username and password are there any other details i would need to connect to the server. please advice. thanks.

[PHP] Re: question about customized error

2008-03-22 Thread Nilesh Govindrajan
Sudhakar wrote: if a user by mistake types the wrong url directly in the address bar ex= www.website.com/abou.php instead of typing www.website.com/aboutus.php instead of the browser displaying File not found or a 404 error message i would like to display a customized page which will still have t

[PHP] Re: question about direct access to url

2008-03-18 Thread Donn Ingle
Use sessions or (not as secure) pass a hidden form field along from form.php to thankyou.php. You can look for it in thankyou.php and if it's not there then you know something's wrong. You'd check the $_POST array for your secret field and value. \d -- PHP General Mailing List (http://www.php

[PHP] Re: Question about cURL, and iFrames...

2008-02-19 Thread Shawn McKenzie
Jason Pruim wrote: > Happy friday to all of you! > > May the Beer[1] flow freely from the kegs to your lips after work! > > I am trying to think through something, I am writing a simple proxy > script for my own knowledge and to simplify my life :) > > What I want to do is bring in multiple webs

Re: [PHP] Re: Question about development

2008-02-12 Thread Richard Lynch
On Tue, February 12, 2008 3:32 pm, Jason Pruim wrote: > > On Feb 12, 2008, at 4:24 PM, Daniel Brown wrote: > >> On Feb 12, 2008 2:53 PM, Nathan Rixham <[EMAIL PROTECTED]> wrote: >>> Browsers generally send the the HTTP_ACCEPT_LANGUAGE header in a >>> request. >>> >>> $_SERVER[HTTP_ACCEPT_LANGUAGE]

Re: [PHP] Re: Question about development

2008-02-12 Thread Jason Pruim
On Feb 12, 2008, at 4:24 PM, Daniel Brown wrote: On Feb 12, 2008 2:53 PM, Nathan Rixham <[EMAIL PROTECTED]> wrote: Browsers generally send the the HTTP_ACCEPT_LANGUAGE header in a request. $_SERVER[HTTP_ACCEPT_LANGUAGE] => en-gb,en;q=0.5 thus with mine, preference is en-gb, failing that an

Re: [PHP] Re: Question about development

2008-02-12 Thread Daniel Brown
On Feb 12, 2008 2:53 PM, Nathan Rixham <[EMAIL PROTECTED]> wrote: > Browsers generally send the the HTTP_ACCEPT_LANGUAGE header in a request. > > $_SERVER[HTTP_ACCEPT_LANGUAGE] => en-gb,en;q=0.5 > > thus with mine, preference is en-gb, failing that anything en; failing > that whatever you've got. >

Re: [PHP] Re: Question about development

2008-02-12 Thread Nathan Rixham
> Jason Pruim wrote: On Feb 12, 2008, at 2:09 PM, Aleksandar Vojnovic wrote: Could you explain this a little better - "...into using a database[1] for storing the pages and using browser sniffing to find out what language preference they currently had selected to display in that language"?

Re: [PHP] Re: Question about development

2008-02-12 Thread Nathan Rixham
Jason, If you don't mind I may give you an email off the list in a moment to brain storm up a quick list of questions to ask clients and indeed client "gotchas". For the time being as this seems to be going down the line of how to handle multilingual sites here's my two pennies. XML, store

Re: [PHP] Re: Question about development

2008-02-12 Thread Jason Pruim
On Feb 12, 2008, at 2:09 PM, Aleksandar Vojnovic wrote: Could you explain this a little better - "...into using a database[1] for storing the pages and using browser sniffing to find out what language preference they currently had selected to display in that language"? Aleksandar I'll t

Re: [PHP] Re: Question about development

2008-02-12 Thread Aleksandar Vojnovic
Could you explain this a little better - "...into using a database[1] for storing the pages and using browser sniffing to find out what language preference they currently had selected to display in that language"? Aleksandar Quoting Jason Pruim <[EMAIL PROTECTED]>: On Feb 12, 2008, at 1:0

Re: [PHP] Re: Question about development

2008-02-12 Thread Shawn McKenzie
Jason Pruim wrote: > > On Feb 12, 2008, at 1:03 PM, Nathan Rixham wrote: > >> Jason Pruim wrote: >>> Hi Everyone, >>> I know this isn't 100% on topic... But when is any post to this list >>> 100% on topic? :) >>> I've been doing some googling trying to find info on how to plan for >>> what a webs

Re: [PHP] Re: Question about development

2008-02-12 Thread Wolf
Jason Pruim <[EMAIL PROTECTED]> wrote: > > On Feb 12, 2008, at 1:03 PM, Nathan Rixham wrote: > > > Jason Pruim wrote: > >> Hi Everyone, > >> I know this isn't 100% on topic... But when is any post to this > >> list 100% on topic? :) > >> I've been doing some googling trying to find info

Re: [PHP] Re: Question about development

2008-02-12 Thread Jason Pruim
On Feb 12, 2008, at 1:03 PM, Nathan Rixham wrote: Jason Pruim wrote: Hi Everyone, I know this isn't 100% on topic... But when is any post to this list 100% on topic? :) I've been doing some googling trying to find info on how to plan for what a website needs. Stuff like Does it need a foru

[PHP] Re: Question about development

2008-02-12 Thread Nathan Rixham
Jason Pruim wrote: Hi Everyone, I know this isn't 100% on topic... But when is any post to this list 100% on topic? :) I've been doing some googling trying to find info on how to plan for what a website needs. Stuff like Does it need a forum, live support, database driven etc. etc. Does any

[PHP] Re: Question about functions

2008-01-24 Thread Nathan Rixham
Jason Pruim wrote: Hi everyone! So, I'm trying to learn about functions, and I think I understand what to use them for... And one of the ideas I had was to write a function to logout of an application. The question I have though, is how do I call it? Right now I just have a link like this: C

Re: [PHP] Re: Question About Blocking Email Addresses in Forms

2008-01-19 Thread Per Jessen
Richard Lynch wrote: > On Fri, January 18, 2008 10:41 am, Per Jessen wrote: >> 2. check that the domain exists and has an MX. > > I believe this will foul you up... > > I *think* many domains just use their regular domain as MX if there is > no MX. We've been using the method on public forms fo

Re: [PHP] Re: Question About Blocking Email Addresses in Forms

2008-01-18 Thread Richard Lynch
On Fri, January 18, 2008 10:41 am, Per Jessen wrote: > 2. check that the domain exists and has an MX. I believe this will foul you up... I *think* many domains just use their regular domain as MX if there is no MX. And the Bad Guy can easily change tactics to use [EMAIL PROTECTED] or whatever, o

Re: [PHP] Re: Question About Blocking Email Addresses in Forms

2008-01-18 Thread Javier Huerta
> What does your form actually do? Does it email you, >email them, stick > something in a DB? What? > The form sends an email to a listserv and cc's the sender and then enters data into a database. > Regardless, if they're entering a nonsense email address >and are > managing to get your scr

[PHP] Re: Question About Blocking Email Addresses in Forms

2008-01-18 Thread Manuel Lemos
Hello, on 01/18/2008 01:55 PM Javier Huerta said the following: > Thanks for all of your suggestions which all point to using Catpcha. I have > actually already implemented Capchta and they are still getting around it. > Even if they are entering it manually rather than via a bot, is there a wa

Re: [PHP] Re: Question About Blocking Email Addresses in Forms

2008-01-18 Thread Per Jessen
Javier Huerta wrote: > Thanks for all of your suggestions which all point to using Catpcha. > I have actually already implemented Capchta and they are still getting > around it. Even if they are entering it manually rather than via a > bot, is there a way to check if the email address is of a spe

Re: [PHP] Re: Question About Blocking Email Addresses in Forms

2008-01-18 Thread Stut
On 18 Jan 2008, at 16:01, Eric Butera wrote: On Jan 18, 2008 10:55 AM, Javier Huerta <[EMAIL PROTECTED]> wrote: Thanks for all of your suggestions which all point to using Catpcha. I have actually already implemented Capchta and they are still getting around it. Even if they are entering i

Re: [PHP] Re: Question About Blocking Email Addresses in Forms

2008-01-18 Thread Eric Butera
On Jan 18, 2008 10:55 AM, Javier Huerta <[EMAIL PROTECTED]> wrote: > Thanks for all of your suggestions which all point to using Catpcha. I have > actually already implemented Capchta and they are still getting around it. > Even if they are entering it manually rather than via a bot, is there a wa

[PHP] Re: Question About Blocking Email Addresses in Forms

2008-01-18 Thread Javier Huerta
Thanks for all of your suggestions which all point to using Catpcha. I have actually already implemented Capchta and they are still getting around it. Even if they are entering it manually rather than via a bot, is there a way to check if the email address is of a specific format and if so then

[PHP] Re: Question about urlencode....

2007-11-30 Thread Colin Guthrie
TG wrote: > Unless your URL is more complicated than your example, you shouldn't need to > use urlencode() at all. You'd need to use it in a case where your string > may contain characters that aren't valid in URLs like spaces and such: > > $baseurl = "http://www.somesearchsite.com/search=";;

[PHP] Re: question about str_replace function

2007-01-08 Thread M.Sokolewicz
change it to Kencana wrote: Hi all, I got a doubt about the str_replace function. $string="avenue 1, ave 1"; $words=str_replace ("ave","avenue", $string); echo $words; ?> the php code above will return me "avenuenue 1, avenue 1". i expect the result will be "avenue 1, avenue 1". any idea of

Re: [PHP] Re: Question about constructors and destructors

2006-06-28 Thread Jochem Maas
Richard Lynch wrote: > On Wed, June 28, 2006 5:07 pm, Jochem Maas wrote: >> zend.ze1_compatibility_mode is next to useless in practice for >> anything >> but the most simple php4 OO code. certainly if you are wanting to >> use php5 specific OO functionality like __destruct() you should not be >> us

Re: [PHP] Re: Question about constructors and destructors

2006-06-28 Thread Richard Lynch
On Wed, June 28, 2006 5:07 pm, Jochem Maas wrote: > zend.ze1_compatibility_mode is next to useless in practice for > anything > but the most simple php4 OO code. certainly if you are wanting to > use php5 specific OO functionality like __destruct() you should not be > using > ze1_compatibility_mode

Re: [PHP] Re: Question about constructors and destructors

2006-06-28 Thread Jochem Maas
I tested on linux also and found no problem ... Mathieu Dumoulin wrote: > For all to know > > This bug is linux AND windows, the problem is caused when you have the > > zend.ze1_compatibility_mode = On now it makes sense ... someone else offered a pretty good explanation as to why you see the '

RE: [PHP] Re: Question about constructors and destructors

2006-06-28 Thread KermodeBear
> For all to know > This bug is linux AND windows, the problem is caused when you have the > zend.ze1_compatibility_mode = On > in the php.ini file. This is a bug that was reported before several > times without having been resolved. I commented and reactiveated the bug > on the php bug submissio

[PHP] Re: Question about constructors and destructors

2006-06-28 Thread Mathieu Dumoulin
For all to know This bug is linux AND windows, the problem is caused when you have the zend.ze1_compatibility_mode = On in the php.ini file. This is a bug that was reported before several times without having been resolved. I commented and reactiveated the bug on the php bug submission engine

Re: [PHP] Re: Question about C++ like macros on PHP

2006-02-01 Thread Andrei
Thnx for the tip. I wanted debug features only for this function. So working with debug_backtrace() was what I needed. Thnx again, Andrei Richard Lynch wrote: On Tue, January 31, 2006 6:40 am, Andrei wrote: Well I know, I wanted to know if any1 did find a workaround... To be more clear, sin

Re: [PHP] Re: Question about C++ like macros on PHP

2006-01-31 Thread Richard Lynch
On Tue, January 31, 2006 6:40 am, Andrei wrote: > Well I know, I wanted to know if any1 did find a workaround... To be more clear, since obviously several other posters aren't aware of it... http://php.net/set_error_handler allows you to write a function to be called when an error occurs and that

Re: [PHP] Re: Question about C++ like macros on PHP

2006-01-31 Thread Andrei
Well I know, I wanted to know if any1 did find a workaround... Barry wrote: Andrei wrote: Hi list, For debugging purposes I want to send to a function the line and file where it is called. The problem is that I want these parameters to be added to function as default parameters (changin

[PHP] Re: Question about C++ like macros on PHP

2006-01-31 Thread Barry
Andrei wrote: Hi list, For debugging purposes I want to send to a function the line and file where it is called. The problem is that I want these parameters to be added to function as default parameters (changing all function calls would not be an option for me) function my_func( $para

[PHP] Re: question about using $this as a method in a function argument

2006-01-21 Thread Bogdan Ribic
> > I have a question about using $this as an argument in a method. > As I understand it, the only issue here is if you are passing $this from constructor of your class from PHP 4. In short, when you do $var = new MyClass(); you are actually storing a copy of what constructor was seeing a

[PHP] Re: question about compositing objects

2006-01-12 Thread Mark
jonathan wrote: > I have a class which creates another class within it such as: > > class Loc{ > > public function outputInfo() > { > > > $map=new Map(); > > $map->setKey(); > > > } > > } > > In my main page can I access the $map object like this: > > $loc=new Loc(); > > $loc->map->publ

[PHP] Re: Question about Request.php

2005-12-01 Thread Danilo Azevedo
Jonathan, thanks for ur assistence, i did the print_r($_REQUEST) , its working fine all my get vars returned i did all my website using the Request.php/PEAR class but only this page dont work, because i never used a Tag with attributes before :(

[PHP] Re: Question about Request.php

2005-12-01 Thread James Benson
Try checking for the error after:- $Req->sendRequest(); Example:- $response = $Req->sendRequest(); if (PEAR::isError($response)) { die($response->getMessage()); } $Response = $Req->getResponseBody(); You may also want to include some options like so:- $options = array( 'method' => 'G

Re: [PHP] Re: Question about including files and server load

2005-10-14 Thread Greg Donald
On 10/14/05, Dan Baker <[EMAIL PROTECTED]> wrote: > The concept is that only the code that actually gets executed is ever > loaded/compiled. Pretty sneaky! I think that's the general idea behind PHP's autoload(): http://php.net/autoload Using a caching tool like APC or Zend Optimizer would be he

[PHP] Re: Question about including files and server load

2005-10-14 Thread Dan Baker
"Jay Paulson" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >I just started working with a new company and they handed me some of their > php code for me to look over. I noticed that they have a TON of include > files being called into their scripts. For example, instead of having

[PHP] Re: Question about including files and server load

2005-10-14 Thread Oliver Grätz
Jay Paulson schrieb: > function xyz($abc) { return include(xyz_func.php); } > function abc($xyz) { return include(abc_func.php); } Oh. My. God. Is this ugly. OK, it works, but that's not the way how one should abuse include(). > I was wondering isn't this putting a bigger load on a server by inc

Re: [PHP] Re: Question about "shortening" a string

2005-03-12 Thread Jochem Maas
Ashley M. Kirchner wrote: Mário Gamito wrote: ... >> Does anyone knows how to do this ? > > $parts = explode(' ', $fullName); > $shortenedName = $parts[0].' '.$parts[count($parts)-1]; > ?> > This might solve one problem. What about people who have names like 'Pablo Ricardo del Rey' where you

Re: [PHP] Re: Question about "shortening" a string

2005-03-11 Thread Ashley M. Kirchner
Mário Gamito wrote: Hi Sokolewicz, Thanks a lot. It just working really fine :) M. Sokolewicz wrote: > Mário Gamito wrote: > >> For example, if i fill the form with "Mário Augusto Machado dos Reis Gamito", i want to change this string to only "Mário Gamito". >> >> The total number of names is not

Re: [PHP] Re: Question about "shortening" a string

2005-03-11 Thread Mário Gamito
Hi Sokolewicz, Thanks a lot. It just working really fine :) Thank you again. Warm regards, Mário Gamito M. Sokolewicz wrote: > Mário Gamito wrote: > >> Hi, >> >> In Portgal we have big names. >> My complete name, for instance, is "Mário Augusto Machado dos Reis Gamito". >> "Mário" is the Christian

[PHP] Re: Question about "shortening" a string

2005-03-11 Thread M. Sokolewicz
Mário Gamito wrote: Hi, In Portgal we have big names. My complete name, for instance, is "Mário Augusto Machado dos Reis Gamito". "Mário" is the Christian name and "Gamito" - the last one - is always the last name of the father. I have a form where i want to let my users insert their full big nam

[PHP] Re: question about a cron job

2005-01-17 Thread Al
Al wrote: I've got a question about the following cronjob. #At 3:01 our time, run backups 1 0 * * * /usr/local/bin/php /www/r/rester/htdocs/auto_backup/back_em_up.php >/www/r/rester/htdocs/auto_backup/cron.log 2>&1 #At 3:02 clean up sessions folder 2 0 * * * (find /www/r/rester/htdocs/sessions/

[PHP] Re: Question about function dns_check_record

2004-11-01 Thread Ben Ramsey
First of all, don't ask two questions in one message. Send two separate messages. You're more likely to get better answers to both questions. Bao Vu wrote: I have a problem regard to function - dns_check_record - dns_get_mx Can you tell me why the PHP said the "Call to undefined function"?

[PHP] Re: Question about executing PHP script

2004-06-28 Thread Lars Torben Wilson
Charlie Don wrote: Hello, I need to have some scripts that do database maintanance on my cron tab. However, some might take more time to execute that the maxtime set on php.ini. These are now web scripts but scripts that I execute on my command prompt or cron tab. I wonder if there is any way t

[PHP] Re: question about M. Lemos's HTML forms generation and validation

2004-03-29 Thread Gimic
I just looked over the code I recently submitted.. the last if statement needs a semi-colon at the end of the echo("The name don't exist") part... sory if you copy/pasted and got an error.. ;) "Gimic" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > It's a simple algorythem, use a loop

[PHP] Re: question about M. Lemos's HTML forms generation and validation

2004-03-29 Thread Gimic
It's a simple algorythem, use a loop to enter the names from the database into an array, and compare each to the value in the array. or some hybred thereof. regardless of what performance freaks say.. this won't make a big dif in performance unless you are like yahoo with several hundred millio

[PHP] Re: question about M. Lemos's HTML forms generation and validation

2004-03-26 Thread dr. zoidberg
Manuel Lemos wrote: Hello, On 03/25/2004 10:19 PM, Dr. Zoidberg wrote: I'm creating registration service with this great form script for creating forms within Smarty. Question is how can I validate 'username' against allready registered users in MySQL so that someone cannot register him self i

[PHP] Re: question about M. Lemos's HTML forms generation and validation

2004-03-25 Thread Manuel Lemos
Hello, On 03/25/2004 10:19 PM, Dr. Zoidberg wrote: I'm creating registration service with this great form script for creating forms within Smarty. Question is how can I validate 'username' against allready registered users in MySQL so that someone cannot register him self if there is another u

[PHP] Re: Question about CGI binary

2004-02-26 Thread Chris
I am aware of safe mode but, are you saying that when PHP is installed as a CGI binary safe mode is on by default? Chris "André cerqueira" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > http://www.php.net/set_time_limit > > [snip]

[PHP] Re: Question about CGI binary

2004-02-26 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 actually i thought you said your scripts were running in a remote host which you cant change php.ini and assuming that, i said that most servers setup php in safe mode i believe php.ini is the same for php as module and cgi-bin dont know if that helps

[PHP] Re: Question about CGI binary

2004-02-25 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 http://www.php.net/set_time_limit [snip] > Warning > > set_time_limit() has NO EFFECT when PHP is running in safe mode. There > is NO workaround other than turning off safe mode or changing the time > limit in the php.ini. [/snip] most servers do that

[PHP] Re: Question about php "forwarding" to javascript

2004-02-14 Thread Ammar Ibrahim
I'm not sure i completely understand what you need but you could write dynamic Javascript using PHP e.g; $myString = 'hey dude, help me'; The code i wrote is really dumb, but trying to give you an example.

[PHP] Re: Question about an array

2004-01-03 Thread Matt Grimm
If you're going to build your array that way, then you need to loop through $sometext[0], not $sometext. You're creating an array in the first element of the $sometext array, so $sometext element zero is an array containing your exploded words. Instead, try: $sometext = explode(" ", "your long s

  1   2   >