Re: [PHP] how call a variable in a text

2009-10-21 Thread Thodoris
On Wed, 2009-10-21 at 23:11 +0200, Kim Madsen wrote: Ashley Sheridan wrote on 2009-10-21 22:56: Try this though: Print "This is different from your previous example :-)"; -- Kind regards Kim Emax - masterminds.dk Yeah, I just forgot that PHP will correctly work wit

[PHP] XML parsing with PHP

2009-10-21 Thread Mari Masuda
Hi, I need to transform some XML files and have not really done much XSLT. I am looking for recommendations on ways to parse XML via PHP. The XML files I have contain the content from our website CMS. We are switching from a proprietary CMS to Drupal and I need to transform the XML int

Re: [PHP] Web Service Server in PHP

2009-10-21 Thread Sudheer Satyanarayana
On Thursday 22 October 2009 06:56 AM, Daniel Echalar wrote: Hi, Does anybody knows a web services server based on PHP? The only one a see is Nusoap, but even for this one i can't find the webpage to see the documentation. by the way, i'm trying to develop an application using web services in P

RE: [PHP] how call a variable in a text

2009-10-21 Thread Samrat Kar
This is always safe to use variables like this... $text = "This is " . $variable; Or $text = "This is " . $variable[0]; Regards, Samrat Kar FRD, BARC Tel: 022-25597295 Alternate Email: esam...@yahoo.com -Original Message- From: Kim Madsen [mailto:php@emax.dk] Sent: Thursday, Oc

Re: [PHP] Web Service Server in PHP

2009-10-21 Thread Dan McCullough
I believe NuSoap is still available source: http://sourceforge.net/projects/nusoap/ http://greghuet.blogspot.com/2007/12/soap-php5-and-nusoapphp.html You can also look here at PHPs SOAP functions http://php.net/manual/en/refs.webservice.php On Wed, Oct 21, 2009 at 9:26 PM, Daniel Echalar wrote:

Re: [PHP] Web Service Server in PHP

2009-10-21 Thread Eddie Drapkin
On Wed, Oct 21, 2009 at 9:26 PM, Daniel Echalar wrote: > Hi, > > Does anybody knows a web services server based on PHP? > > The only one a see is Nusoap, but even for this one i can't find the webpage > to see the documentation. > > by the way, i'm trying to develop an application using web servic

[PHP] Web Service Server in PHP

2009-10-21 Thread Daniel Echalar
Hi, Does anybody knows a web services server based on PHP? The only one a see is Nusoap, but even for this one i can't find the webpage to see the documentation. by the way, i'm trying to develop an application using web services in PHP, any start point suggestion will be appreciated. thanks fo

Re: [PHP] how call a variable in a text

2009-10-21 Thread Shawn McKenzie
Ashley Sheridan wrote: > On Wed, 2009-10-21 at 22:54 +0200, Kim Madsen wrote: > >> Ashley Sheridan wrote on 2009-10-21 22:43: >> >>> The {} only become really useful when you're trying to reference arrays >>> within a string: >>> >>> $var = array('great', 'boring'); >>> >>> $text = "this is {$var[

Re: [PHP] how call a variable in a text

2009-10-21 Thread Ashley Sheridan
On Wed, 2009-10-21 at 23:11 +0200, Kim Madsen wrote: > Ashley Sheridan wrote on 2009-10-21 22:56: > > > Try this though: > > > > > > > $var = array(array('great','alright'), 'boring'); > > > > print "This is $var[0][0]."; > > Print "This is different from your previous example :-)"; > > --

Re: [PHP] how call a variable in a text

2009-10-21 Thread Kim Madsen
Ashley Sheridan wrote on 2009-10-21 22:56: Try this though: Print "This is different from your previous example :-)"; -- Kind regards Kim Emax - masterminds.dk -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] how call a variable in a text

2009-10-21 Thread Ashley Sheridan
On Wed, 2009-10-21 at 22:54 +0200, Kim Madsen wrote: > Ashley Sheridan wrote on 2009-10-21 22:43: > > > The {} only become really useful when you're trying to reference arrays > > within a string: > > > > $var = array('great', 'boring'); > > > > $text = "this is {$var[0]}."; > > > > Without th

RE: [PHP] how call a variable in a text

2009-10-21 Thread Ashley Sheridan
On Wed, 2009-10-21 at 15:51 -0500, David Murphy wrote: > True however K.I.S.S would say , if you can use it like > > > > > > echo “This is a statement {$Blah}.”; > > echo “This is also a statement {$objBlah->BlahString}.”; > > echo “This is also a statement {$tBlah[‘BlahKey’]}.”; > >

Re: [PHP] how call a variable in a text

2009-10-21 Thread Kim Madsen
Ashley Sheridan wrote on 2009-10-21 22:43: The {} only become really useful when you're trying to reference arrays within a string: $var = array('great', 'boring'); $text = "this is {$var[0]}."; Without the curly braces, PHP wouldn't be able to figure out whether you wanted the end string to

RE: [PHP] how call a variable in a text

2009-10-21 Thread David Murphy
True however K.I.S.S would say , if you can use it like echo “This is a statement {$Blah}.”; echo “This is also a statement {$objBlah->BlahString}.”; echo “This is also a statement {$tBlah[‘BlahKey’]}.”; You should do it so you are always using the same expected format, cleaner

RE: [PHP] how call a variable in a text

2009-10-21 Thread Ashley Sheridan
On Wed, 2009-10-21 at 15:40 -0500, David Murphy wrote: > This is actually much better the { and } make it very obvious where the > variable is and also it can keep odd issues from occurring sometimes. > > $message=" There is a text {$variable} trial. "; > > There is always spri

RE: [PHP] how call a variable in a text

2009-10-21 Thread David Murphy
This is actually much better the { and } make it very obvious where the variable is and also it can keep odd issues from occurring sometimes. $message=" There is a text {$variable} trial. "; There is always sprint type functions also. David -Original Message- From

[PHP] Re: how call a variable in a text

2009-10-21 Thread Shawn McKenzie
Bulend Kolay wrote: > I 'll send a mail in html form using php5. > > cat send.php > $variable="date1" ; > .. > .. > $message=' > > There is a text $variable trial. > '; > > mail($to, $subject, $message, $headers) ; > ?> > > when I run send.php, I get the mail. But I can't call variable call

Re: [PHP] how call a variable in a text

2009-10-21 Thread Andrew Ballard
2009/10/21 Bulend Kolay : > I 'll send a mail in html form using php5. > > cat send.php > $variable="date1" ; > .. > .. > $message=' > > There is a text $variable  trial. > '; > > mail($to, $subject, $message, $headers) ; > ?> > > when I run send.php, I get the mail. But I can't call variable ca

[PHP] Re: Text File Busy

2009-10-21 Thread Shawn McKenzie
Floyd Resler wrote: > For some reason I'm getting a Text file busy error when I try to execute > PHP scripts from the command line now. It used to work, but now it > doesn't. I do have #!/usr/bin/php at the top of my script. If I feed > the file to php (i.e. /usr/bin/php -f filename.php) it work

[PHP] how call a variable in a text

2009-10-21 Thread Bulend Kolay
I 'll send a mail in html form using php5. cat send.php There is a text $variable trial. '; mail($to, $subject, $message, $headers) ; ?> when I run send.php, I get the mail. But I can't call variable called variable. it comes as string. How can I correct this? -- PHP General Mailing Lis

RE: [PHP] How to pronounce PHP code over the phone?

2009-10-21 Thread Daevid Vincent
> -Original Message- > From: tedd [mailto:tedd.sperl...@gmail.com] > Sent: Wednesday, October 21, 2009 7:38 AM > To: Dotan Cohen; Daevid Vincent > Cc: php-general. > Subject: Re: [PHP] How to pronounce PHP code over the phone? > > At 9:42 AM +0200 10/21/09, Dotan Cohen wrote: > > > Op

[PHP] Text File Busy

2009-10-21 Thread Floyd Resler
For some reason I'm getting a Text file busy error when I try to execute PHP scripts from the command line now. It used to work, but now it doesn't. I do have #!/usr/bin/php at the top of my script. If I feed the file to php (i.e. /usr/bin/php -f filename.php) it works. Of course, I can

Re: [PHP] Sanitizing potential MySQL strings with no database connection

2009-10-21 Thread Jim Lucas
Dotan Cohen wrote: >> If you look a little closer, you will see that I am not using addslashes(). >> Rather, I am using addcslashes(). This allows to specify the characters >> that I want escaped, instead of the default assumed characters from >> addslashes(). >> > > I do not know which characte

Re: [PHP] Sanitizing potential MySQL strings with no database connection

2009-10-21 Thread Dotan Cohen
> Thinking a little deeper here, you say you are concerned about the character > type, yet you say that it is all assumed UTF-8.  Is everything going to be > UTF-8 > or something else? > > If it is all going to be UTF-8, then the addcslashes() variation above will > work. > It _should_ all be UT

Re: [PHP] Sanitizing potential MySQL strings with no database connection

2009-10-21 Thread Dotan Cohen
> If you look a little closer, you will see that I am not using addslashes(). >  Rather, I am using addcslashes().  This allows to specify the characters > that I want escaped, instead of the default assumed characters from > addslashes(). > I do not know which characters to escape. -- Dotan Coh

Re: [PHP] Sanitizing potential MySQL strings with no database connection

2009-10-21 Thread Jim Lucas
Jim Lucas wrote: > Dotan Cohen wrote: >>> So, actually taking a minute to read up on addcslashes(), it is a >>> rather handy >>> little function. >>> >>> Taking the list of characters that mysql_real_escape_string() says it >>> escapes: >>> >>> http://us3.php.net/mysql_real_escape_string >>> >>> Wh

Re: [PHP] How to pronounce PHP code over the phone?

2009-10-21 Thread tedd
At 9:42 AM +0200 10/21/09, Dotan Cohen wrote: > Open paren. Dollar-sign "item" de-ref getServiceID method. Question mark. Dollar-sign "item" de-ref getServiceID method again. Colon. Dollar-sign "item" de-ref getID method. Close up matching parenthesis. > http://en.wikipedia.org/wiki/Refere

Re: [PHP] Sanitizing potential MySQL strings with no database connection

2009-10-21 Thread Jim Lucas
Dotan Cohen wrote: So, actually taking a minute to read up on addcslashes(), it is a rather handy little function. Taking the list of characters that mysql_real_escape_string() says it escapes: http://us3.php.net/mysql_real_escape_string Which it lists: \x00, \n, \r, \, ', " and \x1a \0 = \x

RE: [PHP] Sanitizing potential MySQL strings with no database connection

2009-10-21 Thread Andrea Giammarchi
I so much avoid the silent char that sometimes I even forget this exists. I guess it is worth it for this case. Regards > Date: Tue, 20 Oct 2009 21:28:06 +0200 > From: dotanco...@gmail.com > To: php@emax.dk > CC: a...@ashleysheridan.co.uk; php-general@lists.php.net > Subject: Re: [PHP] Sani

Re: [PHP] Spam opinions please

2009-10-21 Thread Ashley Sheridan
On Tue, 2009-10-20 at 23:41 +0200, Kim Madsen wrote: > Gary wrote on 2009-10-20 22:55: > > I like that idea,so in other words they have to get to the form from > > another > > page on the site, and you set a time limit for a minimum amount of time > > they > > spend on the page(5-10 seconds)?

Re: [PHP] Sanitizing potential MySQL strings with no database connection

2009-10-21 Thread John Black
Dotan Cohen wrote: So far as I understand mysql_real_escape_string() was invented because addslashes() is not adequate. Correct, addslashes() works fine for latin1 (single byte encoding) but does not work properly when used with a multibyte encoded string. That is most likely the reason why my

Re: [PHP] How to pronounce PHP code over the phone?

2009-10-21 Thread Dotan Cohen
> Open paren. Dollar-sign "item" de-ref getServiceID method. Question mark. > Dollar-sign "item" de-ref getServiceID method again. Colon. > Dollar-sign "item" de-ref getID method. Close up matching parenthesis. > > http://en.wikipedia.org/wiki/Reference_%28computer_science%29 > Thanks. The word Re

Re: [PHP] Sanitizing potential MySQL strings with no database connection

2009-10-21 Thread Dotan Cohen
> So, actually taking a minute to read up on addcslashes(), it is a rather handy > little function. > > Taking the list of characters that mysql_real_escape_string() says it escapes: > > http://us3.php.net/mysql_real_escape_string > > Which it lists: \x00, \n, \r, \, ', " and \x1a > > \0  = \x0 > \