Hi,
Does any one knows if XPath 2.0 will be supported in 5.3?
__
Raymond Irving
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hello everyone,
I've run into a bit of a sticky situation trying to connect to a remote
MySQL database. Here's the background:
Connecting from the command line on the web server works.
Connecting from a different vhost works.
There's no information in mysql_error. In fact, mysql_select_db(
Cesco wrote:
Could you help me clarify one thing that I don't understand... let's put
it simple, just imagine that I have a tiny XML document with a list of
movies:
Gone with the wind
I want to read this XML file and write the name of the first (and only)
movie in the lis
On Wed, 06 May 2009 08:54:14 -0400, f...@thefsb.org (Tom Worster) wrote:
...
>clancy, i can't argue with you. my desired usage of break is really just a
>cover-up for a goto. i know.
>
>it makes no logical sense but i think i'd sooner adopt oop than gotos. my
>mom taught me to program back in
Robert Cummings wrote:
On Wed, 2009-05-06 at 08:41 -0400, Tom Worster wrote:
On 5/6/09 7:05 AM, "Robert Cummings" wrote:
That seems like an abuse of exceptions. But then we're already abusing
loops. I just don't think one could say it's the proper way to do it :)
i don't have a lot of intere
Robert Cummings wrote:
> On Wed, 2009-05-06 at 22:23 +0200, Marcus Gnaß wrote:
>> Robert Cummings wrote:
>>> On Wed, 2009-05-06 at 12:56 +0200, Marcus Gnaß wrote:
Tom Worster wrote:
> there's a control structure i wish php had: a simple block that you can
> break out of, e.g.
>
>>
Could you help me clarify one thing that I don't understand... let's
put it simple, just imagine that I have a tiny XML document with a
list of movies:
Gone with the wind
I want to read this XML file and write the name of the first (and
only) movie in th
On Wed, 2009-05-06 at 15:50 -0500, Shawn McKenzie wrote:
> Marcus Gnaß wrote:
> > Robert Cummings wrote:
> >> On Wed, 2009-05-06 at 12:56 +0200, Marcus Gnaß wrote:
> >>> Tom Worster wrote:
> there's a control structure i wish php had: a simple block that you can
> break out of, e.g.
> >>>
On Wed, 2009-05-06 at 22:23 +0200, Marcus Gnaß wrote:
> Robert Cummings wrote:
> > On Wed, 2009-05-06 at 12:56 +0200, Marcus Gnaß wrote:
> >> Tom Worster wrote:
> >>> there's a control structure i wish php had: a simple block that you can
> >>> break out of, e.g.
> >>
> >> As Maarten pointed out yo
Marcus Gnaß wrote:
> Robert Cummings wrote:
>> On Wed, 2009-05-06 at 12:56 +0200, Marcus Gnaß wrote:
>>> Tom Worster wrote:
there's a control structure i wish php had: a simple block that you can
break out of, e.g.
>>> As Maarten pointed out you could use a function. Another alternative i
Andrew Ballard wrote:
> On Wed, May 6, 2009 at 2:25 PM, Shawn McKenzie wrote:
>> Igor Escobar wrote:
>>> Yeah yeah, i understood that, but, the point is... i sad previously, my
>>> function is not tied to any database.
>>>
>>> Is a generic function, i dont know who be use this, so i don't know, wh
Robert Cummings wrote:
> On Wed, 2009-05-06 at 12:56 +0200, Marcus Gnaß wrote:
>> Tom Worster wrote:
>>> there's a control structure i wish php had: a simple block that you can
>>> break out of, e.g.
>>
>> As Maarten pointed out you could use a function. Another alternative is
>> to use Exceptions
Tom Worster wrote:
there's a control structure i wish php had: a simple block that you can
break out of, e.g.
block {
if ( condition )
break;
blah...
blah...
if ( another condition )
break;
blah...
blah...
etc...
}
the block is just like a loop except that it is ex
On Wed, May 6, 2009 at 2:25 PM, Shawn McKenzie wrote:
> Igor Escobar wrote:
>> Yeah yeah, i understood that, but, the point is... i sad previously, my
>> function is not tied to any database.
>>
>> Is a generic function, i dont know who be use this, so i don't know, what is
>> your data base so, i
Please reply all.
> Do you test with associative arrays?
>
Yes.
Array
(
[test] => some stuff \"here\"
[test_array] => Array
(
[a] => a\"a
[0] => b\'b
[c] => Array
(
[x] => x\"x
[0] => y\'y
Igor Escobar wrote:
> Yeah yeah, i understood that, but, the point is... i sad previously, my
> function is not tied to any database.
>
> Is a generic function, i dont know who be use this, so i don't know, what is
> your data base so, i can't use functions like mysql_real_scape_string etc...
The
Igor Escobar wrote:
> hun...by the way I forgot to mention, I am Brazilian and here in Brazil
> these words are not common ...
Yes, but you can reuse your function even if you start accepting english
posts/comments, etc. You don't want this function to be specific to
your app or data because
Yeah yeah, i understood that, but, the point is... i sad previously, my
function is not tied to any database.
Is a generic function, i dont know who be use this, so i don't know, what is
your data base so, i can't use functions like mysql_real_scape_string etc...
Regards,
Igor Escobar
Systems An
2009/5/6 Igor Escobar :
> hun...by the way I forgot to mention, I am Brazilian and here in Brazil
> these words are not common ...
Igor,
I'm brazilian too, but that is not the point. Deny the use of *any*
word as input in your app is unnecessary. The problem that you're
trying to solve, has b
Now i realize... i sent only to the Shawn the modified functions... here
goes:
function _antiSqlInjection($Target){
$sanitizeRules =
array('OR','FROM','SELECT','INSERT','DELETE','WHERE','DROP TABLE','SHOW
TABLES','*','--','=');
foreach($Target as $key => $value):
if(is_array($valu
hun...by the way I forgot to mention, I am Brazilian and here in Brazil
these words are not common ...
That is a recursive function and i can use array_map becouse i some cases we
obtain arrays of arrays and that will generate a error.
Regards,
Igor Escobar
Systems Analyst & Interface Design
Igor Escobar wrote:
> Hunnn...
>
> So, what do you think now?
>
> function _antiSqlInjection($Target){
> $sanitizeRules =
> array('OR','FROM','SELECT','INSERT','DELETE','WHERE','DROP
> TABLE','SHOW TABLES','*','--','=');
> foreach($Target as $key => $value):
> if(is_array($value)):
mysql_escape_string can be used instead. You just lose the ability to
have it match coallation. I still think there should be the
mysql_escape_string or real one and allow it to pass the coallation
without a database handle -or- just make a unicode/utf8 one and be
done with it.
On May 6,
I know that use the mysql_real_escape_string to do de job is better but you
should consider that the this function don't have any access to the data
base, to objective of this function is sanitize the string.
And please, see my second answer, i make some updates in the function that
possibly is re
On Wed, May 6, 2009 at 12:06 PM, Bruno Fajardo wrote:
> Hi there!
>
> 2009/5/6 Igor Escobar
>>
>> Hi folks,
>> Someone know how i can improve this function to protect my envairounment
>> vars of sql injection attacks.
>>
>> that is the function i use to do this, but, some people think is not enou
Hi there!
2009/5/6 Igor Escobar
>
> Hi folks,
> Someone know how i can improve this function to protect my envairounment
> vars of sql injection attacks.
>
> that is the function i use to do this, but, some people think is not enough:
>
> * @uses $_REQUEST= _antiSqlInjection($_REQUEST);
> * @us
Igor Escobar wrote:
> Hi folks,
> Someone know how i can improve this function to protect my envairounment
> vars of sql injection attacks.
>
> that is the function i use to do this, but, some people think is not enough:
>
> * @uses $_REQUEST= _antiSqlInjection($_REQUEST);
> * @uses $_POST = _a
Hi folks,
Someone know how i can improve this function to protect my envairounment
vars of sql injection attacks.
that is the function i use to do this, but, some people think is not enough:
* @uses $_REQUEST= _antiSqlInjection($_REQUEST);
* @uses $_POST = _antiSqlInjection($_POST);
* @uses $_
On 5/6/09 8:55 AM, "Per Jessen" wrote:
> Shawn McKenzie already posted the right solution - did you miss it?
no, per, i didn't. i like do {} while (0) very much. thanks, shawn!
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Tom Worster wrote:
> On 5/6/09 6:56 AM, "Marcus Gnaß" wrote:
>
>> Tom Worster wrote:
>>> there's a control structure i wish php had: a simple block that you
>>> can break out of, e.g.
>>
>> As Maarten pointed out you could use a function. Another alternative
>> is to use Exceptions which might
On 5/5/09 8:55 PM, "Clancy" wrote:
> On Tue, 05 May 2009 14:13:23 -0400, rob...@interjinn.com (Robert Cummings)
> wrote:
>
>> On Tue, 2009-05-05 at 13:56 -0400, Tom Worster wrote:
>>> there's a control structure i wish php had: a simple block that you can
>>> ...
>
>> But PHP 5.3 introd
On Wed, 2009-05-06 at 08:43 -0400, Tom Worster wrote:
> On 5/6/09 6:56 AM, "Marcus Gnaß" wrote:
>
> > Tom Worster wrote:
> >> there's a control structure i wish php had: a simple block that you can
> >> break out of, e.g.
> >
> > As Maarten pointed out you could use a function. Another alternati
On Wed, 2009-05-06 at 08:41 -0400, Tom Worster wrote:
> On 5/6/09 7:05 AM, "Robert Cummings" wrote:
>
> > That seems like an abuse of exceptions. But then we're already abusing
> > loops. I just don't think one could say it's the proper way to do it :)
>
> i don't have a lot of interest in "the
On 5/6/09 6:56 AM, "Marcus Gnaß" wrote:
> Tom Worster wrote:
>> there's a control structure i wish php had: a simple block that you can
>> break out of, e.g.
>
> As Maarten pointed out you could use a function. Another alternative is
> to use Exceptions which might be the most proper way to do i
tedd wrote:
> At 3:14 AM -0700 5/6/09, Michael A. Peters wrote:
>> Peter Ford wrote:
>>>
>>> tedd wrote: (and I added in some extra bits...)
You need to normalize.
Authors should have an unique id in an authors table. The authors table
has all the specific information about auth
On 5/6/09 7:05 AM, "Robert Cummings" wrote:
> That seems like an abuse of exceptions. But then we're already abusing
> loops. I just don't think one could say it's the proper way to do it :)
i don't have a lot of interest in "the proper way" to do things. i'm
interested in how other programmers
At 3:14 AM -0700 5/6/09, Michael A. Peters wrote:
Peter Ford wrote:
tedd wrote: (and I added in some extra bits...)
You need to normalize.
Authors should have an unique id in an authors table. The authors table
has all the specific information about authors, but not the books they
have writte
>>He already found the problem and fixed it :)<<
Correction: His problem was pointed out to him and he was able to follow
instructions he he.
I think I posted yesterday, but I had the double= in the script earlier, but
it was givning inconsisitant answers, however when I changed the = for=
Hi Gary,
2009/5/5 Gary :
> Jan
>
> Thanks for your note.
>
> So your wrote:
>
> $x = (3)*(2) makes no sense.
> $x = 3 * 2 works, as
> $x = (3 * 2) does, too.
> But this is not an error at all.
^^
>
> In the first example($x = (3)*(2) makes no sense.), which is
On Wed, 2009-05-06 at 12:56 +0200, Marcus Gnaß wrote:
> Tom Worster wrote:
> > there's a control structure i wish php had: a simple block that you can
> > break out of, e.g.
>
>
> As Maarten pointed out you could use a function. Another alternative is
> to use Exceptions which might be the most p
Tom Worster wrote:
> there's a control structure i wish php had: a simple block that you can
> break out of, e.g.
As Maarten pointed out you could use a function. Another alternative is
to use Exceptions which might be the most proper way to do it.
--
PHP General Mailing List (http://www.php.ne
On Tue, 2009-05-05 at 22:31 -0700, Jim Lucas wrote:
> Well, since nobody seems to want to answer your question, I will... :)
>
> It has to do with you using an assignment '=' instead of a comparison '=='
> operator in your condition.
He already found the problem and fixed it :)
Cheers,
Rob.
--
Peter Ford wrote:
tedd wrote: (and I added in some extra bits...)
You need to normalize.
Authors should have an unique id in an authors table. The authors table
has all the specific information about authors, but not the books they
have written.
Books should have an unique id in a books table
On Tue, 2009-05-05 at 16:22 -0700, Michael A. Peters wrote:
> Ashley Sheridan wrote:
>
> >>
> > content coming from MS Office clipboard pastes generally contain
> > characters that are encoded wrong, and do not display correctly in web
> > pages unless they have very relaxed doctypes. The function
tedd wrote: (and I added in some extra bits...)
> You need to normalize.
>
> Authors should have an unique id in an authors table. The authors table
> has all the specific information about authors, but not the books they
> have written.
>
> Books should have an unique id in a books table. The
tedd wrote:
On 5/4/09, Matthieu wrote:
Hello,
I'm a totally newbie to php/Mysql but I'd like to know if it is
normal that
I have to connect 3 times to the db in one page.
For example, I have
1. A connection for the login / pass a $_SESSION['login'] before the
HTML
tags
2. I need
46 matches
Mail list logo