Re: [PHP-DEV] [RFC] orphan extensions cleanup

2016-08-15 Thread Lester Caine
ilds and supply an unsupported third party build so be it ... -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://med

Re: [PHP-DEV] [RFC] orphan extensions cleanup

2016-08-15 Thread Lester Caine
On 15/08/16 18:48, Kalle Sommer Nielsen wrote: > 2016-08-15 19:09 GMT+02:00 Lester Caine <les...@lsces.co.uk>: >> We will do what WE have to to maintain it, but none of us are up to >> speed with current PHP 'style' of coding so we also need help which is >> how we mana

Re: [PHP-DEV] [RFC] orphan extensions cleanup

2016-08-15 Thread Lester Caine
On 15/08/16 18:02, Kalle Sommer Nielsen wrote: > 2016-08-15 18:05 GMT+02:00 Lester Caine <les...@lsces.co.uk>: >> > Don't go there again! > If there is no active maintainer, it just creates a burden on us core > developers that have to maintain it to the best o

Re: [PHP-DEV] [RFC] orphan extensions cleanup

2016-08-15 Thread Lester Caine
On 15/08/16 11:41, Nikita Popov wrote: > I think the interbase extension is missing from this list, I don't think it > has an active maintainer. Don't go there again! -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Elec

Re: [PHP-DEV] Simple variable handling.

2016-08-15 Thread Lester Caine
; I have no intention of using Yasuo's filter extension as it does not > provide anything that I need. I have already written code that does the > job, and I see no reason to change it. SNAP ... Only problem is none of mine plays well with 'composer/PSR' style of module management :

Re: [PHP-DEV] Simple variable handling.

2016-08-15 Thread Lester Caine
worse rather than better :( This is simply about a standard method of adding constraint and other data to the $fieldarray. Even Yasuo's filter extensions need a third party tool to build HIS set of rules from every body else’s version of storing them ... -- Lester C

Re: [PHP-DEV] Re: [RFC][VOTE] Add validation functions to filter module

2016-08-15 Thread Lester Caine
u can not assume your output process will complete without errors and those errors will amend the rest of the chain. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysol

Re: [PHP-DEV] Namespaces internal refactoring

2016-08-15 Thread Lester Caine
user's development. In the past it used to be easier to write extensions and the way I still see it is that anything that you don't want the 'customers' to play with should be packaged that way. It's the 'creative ways' of using the USER interface which is the problem and as soon a

Re: [PHP-DEV] Namespaces internal refactoring

2016-08-14 Thread Lester Caine
And that I think is much more important. On top of just how useful IS namespace and if it's needed at all? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquiryso

Re: [PHP-DEV] Simple variable handling.

2016-08-14 Thread Lester Caine
change the remaining legacy sites which are just working fine as long as you babysit them. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engin

Re: [PHP-DEV] [RFC][VOTE] Add session_create_id() function

2016-08-14 Thread Lester Caine
to pick up if they try and start a second session, but I don't believe I NEED all the complexity of cryptography secure id's? Just ones where I CAN actually identify the client ... or should I be handling that separate from the actual session_id ? -- Lester Caine - G8HFL --

Re: [PHP-DEV] Simple variable handling.

2016-08-13 Thread Lester Caine
nation. $ni_no->__tostring simply returns the raw text string if the content is valid ... and if the user switches on 'strict' they get an exception if the variable is not valid, or I would prefer simply NULL ... -- Lester Caine - G8HFL - Contact - http://lsces.co.u

Re: [PHP-DEV] Simple variable handling.

2016-08-13 Thread Lester Caine
kflow ensures that validation includes elimination of any potentially malicious code. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers D

Re: [PHP-DEV] Simple variable handling.

2016-08-13 Thread Lester Caine
egex as been used for years in hand coded javascript and is clean in the checker program, just not producing a match in FV :( -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk Enquiry

Re: [PHP-DEV] RFC Posted for str_begins and str_ends functions

2016-08-13 Thread Lester Caine
he other methods of doing things take the strain, so certainly LIKE 'XYZ%' and '%XYZ' are probably the 'generic' solution but suffer from slower search times, especially when looking for the ENDING string. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contac

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
he variable $date and ditto on bookname and isbn. All three of them are elements I have user land code to validate, and I don't see what is so special about making that validation available inside an array against simply having $date->rules($my_date_spec) and return $date->valid; ... -- Leste

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
On 12/08/16 12:18, Peter Lind wrote: > On 12 August 2016 at 13:15, Lester Caine <les...@lsces.co.uk> wrote: > >> On 12/08/16 12:09, Peter Lind wrote: >>> And if all typos were switching 'e' and 'n', what a wonderful world it >>> would be. That is

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
On 12/08/16 12:09, Peter Lind wrote: > And if all typos were switching 'e' and 'n', what a wonderful world it > would be. That is not the case though - it's possible to accidentally enter > " and > too. And the browser validation strips them and handles the ' when used in text fi

Re: [PHP-DEV] [RFC][VOTE] Add session_create_id() function

2016-08-12 Thread Lester Caine
On 12/08/16 10:22, Yasuo Ohgaki wrote: > Hi Lester, > > On Fri, Aug 12, 2016 at 6:12 PM, Lester Caine <les...@lsces.co.uk> wrote: >> On 12/08/16 09:23, Yasuo Ohgaki wrote: >>> I don't think it's framework job to do. >> >> This was a little 'tongu

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
ent, and the rules you are defining are the same rules that would be needed on a variable by variable basis? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
On 12/08/16 11:01, Peter Lind wrote: > On 12 August 2016 at 11:54, Rowan Collins <rowan.coll...@gmail.com> wrote: > >> On 12/08/2016 10:21, Lester Caine wrote: >> >>> Many of my systems run on secure intra-nets and much of the 'safety >>> concerns' that h

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
On 12/08/16 11:23, Peter Lind wrote: > On 12 August 2016 at 12:13, Lester Caine <les...@lsces.co.uk> wrote: > >> On 12/08/16 10:42, Peter Lind wrote: >>> On 12 August 2016 at 11:25, Lester Caine <les...@lsces.co.uk> wrote: >>> >>> Thanks fo

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
On 12/08/16 11:11, Yasuo Ohgaki wrote: > Hi Lester, > > On Fri, Aug 12, 2016 at 5:19 PM, Lester Caine <les...@lsces.co.uk> wrote: >> > I'm thinking >> > $var->setConstraint() >> > $var->setEscape() >> > $var->setReadOnly() > DbC canno

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
On 12/08/16 10:42, Peter Lind wrote: > On 12 August 2016 at 11:25, Lester Caine <les...@lsces.co.uk> wrote: > >> On 12/08/16 10:07, Christoph M. Becker wrote: >>>>> I'm thinking >>>>> $var->setConstraint() >>>>> $var->setEscap

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
On 12/08/16 09:54, Rowan Collins wrote: > On 12/08/2016 09:19, Lester Caine wrote: >> I'm thinking >> $var->setConstraint() >> $var->setEscape() >> $var->setReadOnly() >> >> Rather than having to build 'reflections' classes to pull out data that >

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
it platforms. The raw view of the data can vary depending on if you are using seconds or days as a base but both bases eventually produce a variety of displays with managed time offsets. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Cain

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
ntly being discussed MAY be better handled with a return to the basic model of a variable. If a variable is 'readonly' there is no need to worry about each variable. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsc

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
right thing. It's one of the reasons I've not been able to convert a number of sites since they don't have a problem :( -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enqui

Re: [PHP-DEV] [RFC][VOTE] Add session_create_id() function

2016-08-12 Thread Lester Caine
t's result needs to follow some rules. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rainbow Digi

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
iable can be managed in it's own right. I'm thinking $var->setConstraint() $var->setEscape() $var->setReadOnly() Rather than having to build 'reflections' classes to pull out data that a simple $var->is_valid or echo $var will output a correctly escaped piece of text. --

Re: [PHP-DEV] [RFC][VOTE] Add session_create_id() function

2016-08-12 Thread Lester Caine
framework is right than one can simply adjust the rules on a generic variable to cater for your own requirements? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.c

Re: [PHP-DEV] Simple variable handling.

2016-08-12 Thread Lester Caine
his is workflow and that workflow could include a simple array function on the input array, but that still requires that there are a set of constraint rules for each element of the array ... applied to each variable ... so why can't we simply improve the variable? -- Leste

Re: [PHP-DEV] Simple variable handling.

2016-08-11 Thread Lester Caine
, and adding range checking expands that packet. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rai

Re: [PHP-DEV] Simple variable handling.

2016-08-11 Thread Lester Caine
On 11/08/16 16:14, Rowan Collins wrote: > On 11/08/2016 15:49, Lester Caine wrote: >> The question is not how >> you flag an error, but rather when do you check for one. If the 'load' >> function from a database record or the populate from a web form results >> in $age

Re: [PHP-DEV] Simple variable handling.

2016-08-11 Thread Lester Caine
On 11/08/16 14:51, Rowan Collins wrote: > On 11/08/16 13:50, Niklas Keller wrote: >>> > If not by using exceptions, how would you handle them if you assign >>> such >>> > checks to variables and assign a wrong value? > > On 11/08/2016 14:29, Lester Ca

Re: [PHP-DEV] Simple variable handling.

2016-08-11 Thread Lester Caine
clean built in validation process. Rather than throwing some array handling validator with an isolated set of rules at the problem post reading the data. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - htt

Re: [PHP-DEV] Simple variable handling.

2016-08-11 Thread Lester Caine
variables simply passes a pointer to the variable code to process an operation like $age->setannot( 'number', range(1,120) ); at which point setannot( $age, 'number', range(1,120) ); makes perfect sense since $age is simply passed to the global library of code

Re: [PHP-DEV] Function auto-loading

2016-08-10 Thread Lester Caine
off list to set up a account. At some point I'll being THAT site up to the latest versions ... it's on a PHP5.4 base at the moment. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk

[PHP-DEV] Simple variable handling.

2016-08-10 Thread Lester Caine
but ones which still use all the basic functionality. Similarly an array of them can be asked to provide a simple 'yes/no' if all of the variables pass their validation check, or an array of elements which need processing. -- Lester Caine - G8HFL - Contact - http

Re: [PHP-DEV] Function auto-loading

2016-08-10 Thread Lester Caine
On 10/08/16 20:36, Peter Lind wrote: >>From what i can tell, Lester has an infrastructure problem. Not a PHP > problem. But he still wants to halt language development so the community > doesn't pick up new features that might make problems in his code. That > does not seem reasona

Re: [PHP-DEV] Function auto-loading

2016-08-10 Thread Lester Caine
projects and it is that sort of hassle that simply crushes any pleasure in coding these days, when there is nothing gained by this move to 'auto-loading' libraries as the standard for everybody. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact

Re: [PHP-DEV] Function auto-loading

2016-08-10 Thread Lester Caine
On 09/08/16 06:54, Sara Golemon wrote: > On Mon, Aug 8, 2016 at 9:59 PM, Lester Caine <les...@lsces.co.uk> wrote: >>> That is, when I'm running the test-suite of my package, the Composer >>> project is the root folder of that package - but when the package is >>&g

Re: [PHP-DEV] Function auto-loading

2016-08-08 Thread Lester Caine
ge number of different packages it's a major hindrance. I don't need to know where my Linux install has put the include files ... it takes care of that and then finding the pigging things again is the problem. Much the same with finding the source of problems in the mess that composer has cre

Re: [PHP-DEV] Function auto-loading

2016-08-08 Thread Lester Caine
nto the engine rather than something which needs 'auto-loading' at all. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Worksho

Re: [PHP-DEV] Adding validate_var_array()/validate_input_array() to which version?

2016-08-04 Thread Lester Caine
ored in a correct manor. The complexity of what you plan for your array validation elements start with all the same rules applied to a single variable. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services -

Re: [PHP-DEV] Adding validate_var_array()/validate_input_array() to which version?

2016-08-01 Thread Lester Caine
oes in the user land libraries that currently fill the gap. On one hand we are being pushed to add things like getter and setter and all that overhead to create proper objects, while this option is back with handling a raw set of variables as an array? -- Lester Caine - G8HFL

Re: [PHP-DEV] New escaped output operator

2016-07-01 Thread Lester Caine
On 30/06/16 23:46, Thomas Bley wrote: >> What for? > is easy to verify > > is not easy to verify But a fixed version of http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop -

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-06-22 Thread Lester Caine
ng code work. Typing is only a subset of data validation, and so I would teach that and not worry about any of the current 'type' functions as they get in the way. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Ser

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-06-22 Thread Lester Caine
to set constraints such as range or string length, then attempts to store the wrong value can be handled ... something that several user coded frameworks already provide ... then even the 'strict' debate has a completely different base? -- Lester Caine - G8HFL - Contact

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-06-22 Thread Lester Caine
the usage of PHP *SO* much greater than any of them with no sign of any of them gaining traction? Simply because for the vast number of users the simplicity of PHP works ... they are not degree level software engineers. -- Lester Caine - G8HFL - Contact - http://lsces.co.

Re: [PHP-DEV] [RFC] RNG fixes

2016-06-21 Thread Lester Caine
tions, or simply select an entry at random from a list. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop -

Re: [PHP-DEV] New escaped output operator

2016-06-20 Thread Lester Caine
ugh ... and we still keep hitting missed bits. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rain

Re: [PHP-DEV] New escaped output operator

2016-06-20 Thread Lester Caine
On 20/06/16 16:24, Rasmus Schultz wrote: > (and please, nobody say "use a template engine" - I *am* using a > template engine, it's called PHP!) My PHP is augmented with Smarty so I know which are template files and which are program code :) -- Lest

Re: [PHP-DEV] New escaped output operator

2016-06-20 Thread Lester Caine
On 20/06/16 07:00, Niklas Keller wrote: >> Now ... I want to add content that includes >> > alert("xss") it needs to be in the format >> > scriptalert(xss)script so that it never >> > appears in the 'dangerous' format, but if $user['about_me'] is >> > designated a simple text string, then any

Re: [PHP-DEV] New escaped output operator

2016-06-19 Thread Lester Caine
On 19/06/16 19:33, Михаил Востриков wrote: > Lester > >> > there is NO need to simply slap htmlspecialchars() onto >> > properly built data > There are many cases when user data can contain quotes or other html > entities. > > > // $book['title'] =

Re: [PHP-DEV] New escaped output operator

2016-06-19 Thread Lester Caine
On 19/06/16 10:01, Marco Pivetta wrote: > This basically means that you lack basic understanding of how escaping and > user input are to be handled. > Most apps out there about getting a bunch of text from the user, then > rendering it somewhere else in the app. > Cleaning user input just leads to

Re: [PHP-DEV] New escaped output operator

2016-06-19 Thread Lester Caine
n the output' approach, but this STILL left holes which can only be fixed by cleaning the input ... -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engi

Re: [PHP-DEV] [RFC] [VOTE] Replace "Missing argument" warning with "Too few arguments" exception

2016-06-17 Thread Lester Caine
legacy code up to PHP5.6 and eliminated all previous versions before starting the migration to PHP7? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/

Re: [PHP-DEV] [RFC] Throw Exception on Attempt of Constant Redefinition

2016-06-16 Thread Lester Caine
can use PHP7 yet ... -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rainbow Digital Media - http://rainbowdi

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-06-12 Thread Lester Caine
t makes a lot more sense to me that '$this->_price = $value;' either does the job of validation fully, or does not do it at all? And there should be no distinction between $this->_price = $value; and $this->params_array[_price] = $value; It is exactly the same variable? -- Lester Caine

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-06-10 Thread Lester Caine
ifferent metric.) The problem with your base is it assumes everybody is using composer? Just how many people are not? None of my infrastructure uses it and none of the ISP's I support. So it's skewed in favour of the converted. -- Lester Caine - G8HFL - Contact - http://

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-06-10 Thread Lester Caine
On 10/06/16 20:51, Larry Garfield wrote: > On 06/10/2016 02:14 PM, Lester Caine wrote: >> On 10/06/16 17:57, Rowan Collins wrote: >>> For the record, I'm not entirely sure which way I want the language to >>> go, but I think it's a decision that needs to be made, and

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-06-10 Thread Lester Caine
PHP even if it does mean there are two builds. But we already HAVE two builds ... people who want strongly typed and pre-compiled PHP simply use HHVM. There is no need to drag PHP down the same road map? Each has it's own strengths. -- Lester Caine - G8HFL - Conta

Re: [PHP-DEV] Test

2016-06-10 Thread Lester Caine
ust getting email traffic again ... AH there is my test message ... -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - h

[PHP-DEV] Is this thing on?

2016-06-10 Thread Lester Caine
Not seem any traffic for a couple of days? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rainbow

Re: [PHP-DEV] PHP's handling of BOM (byte order mark)

2016-06-06 Thread Lester Caine
hich is where the advise not to use them comes from ... -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.

Re: [PHP-DEV] Re: Opinion on function/method name overloading

2016-06-06 Thread Lester Caine
he natural way of doing things if the FIRST validation step is '$a between 1 and 10' and adding the 'int' does nothing to change the work flow of handling $a in my book ... just loads the process with additional checks which often have to be duplicated internally anyway to maintain a proper flow through

Re: [PHP-DEV] [RFC DISCUSSION] typeof

2016-06-05 Thread Lester Caine
ch property then it's own full copy of the var code, which is why you want to 'optimise' for each different type, rather than improving the caching of the objects data to only run a type conversion when it is needed. -- Lester Caine - G8HFL - Contact - http://lsces.co.

Re: [PHP-DEV] can't reflection on DateTime properties?

2016-06-04 Thread Lester Caine
raw dates. An alternate date/time variable is essential anyway, which is why some of these discussions are so utterly pointless anyway. date and time are as essential to any system as integer and float but all anybody seems to be bothered about is the same limited subset of 'types' ? -- Lester Cain

Re: [PHP-DEV] Set object properties inline

2016-06-01 Thread Lester Caine
he same constraint system to a list of dynamic properties. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw

Re: [PHP-DEV] Set object properties inline

2016-06-01 Thread Lester Caine
On 01/06/16 21:09, Jesse Schalken wrote: > On Wed, Jun 1, 2016 at 7:40 PM, Lester Caine <les...@lsces.co.uk> wrote: > >> Morphed into simply passing an array to the constructor ... >> >> $static1 = new Data\StaticVariable( array( >>

Re: [PHP-DEV] Set object properties inline

2016-06-01 Thread Lester Caine
=> 'blahFunction' ) ); // className defaults to null Of cause the short cut at that time was to drop the names and simply count the variables, but what this replaces is all the complications of named parameters and allowed passing objects in such as '$unknown1' -- Lester Caine - G8

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-29 Thread Lester Caine
On 28/05/16 09:06, Lester Caine wrote: > class Person { > protected var $death; // var is intentional - my flag for a holder > $death->__type( DateTime, not_null = false ); > > To which one can add > $death->__limit( $birth, '120years' ); > Where $birth

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-28 Thread Lester Caine
y converted to a date offset :) BASICALLY any hard coded handling of attributes can co-exist tidily with the much more dynamic and flexible nature that PHP used to have! If you want strict fully bolted down code simply use C/C++ in the first place? -- Lester Caine - G8HFL --

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-27 Thread Lester Caine
On 27/05/16 18:25, Rowan Collins wrote: > On 27 May 2016 10:53:05 GMT+01:00, Lester Caine <les...@lsces.co.uk> wrote: >>On 27/05/16 10:16, Rowan Collins wrote: >>> The most useful typehints are inside the SomeModel class, not the >>> table-level wrapper. This

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-27 Thread Lester Caine
argument all along. And if I'm doing it all in userland anyway I do it in the database read/write rather than duplicating all of that in secondary copies ... -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Servic

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-27 Thread Lester Caine
On 27/05/16 11:25, Fleshgrinder wrote: > On 5/27/2016 11:41 AM, Lester Caine wrote: >> Now I am confused, but it's probably because I'm looking at a simple >> >> $f->d = new DateTime( $initial ); >> >> While you are looking at >> >> If ( isset($i

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-27 Thread Lester Caine
On 27/05/16 10:16, Rowan Collins wrote: > My comment was in reaction to Lester expressing surprise at destroying > and re-creating objects when new data is fetched. To be clear, I'm > talking about this: > > // Clear old data > $this->data = []; > // Re-populate from

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-27 Thread Lester Caine
an object I can do all of the checks on that are provided by int or DateTime as appropriate ... the object needs to exist before the 'new' in order to know if you need the first or second type of $initial code ... or we make typed properties only work one way or the other? -- Lester Caine - G8HFL ---

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-27 Thread Lester Caine
same 'type' of second :( Having accessed the data which naturally includes many null elements is it REALLY more efficient then to create new copies of all of that material? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-26 Thread Lester Caine
a date, it's a null value. The exact question here then is in relation to just how one uses 'DateTime' in this situation? Or more accurately how one maintains the 'or Null' state when the type does not allow null itself? -- Lester Caine - G8HFL - Contact - http:

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-26 Thread Lester Caine
agement but rather than direct properties of the object they are simply an array element. This is why I have such a problem with 'array' functions being so different to 'properties' ... in my book they are the same thing! -- Lester Caine - G8HFL - Contact - http://lsce

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-26 Thread Lester Caine
On 26/05/16 20:56, Rowan Collins wrote: > On 26/05/2016 20:33, Lester Caine wrote: >> If I am creating an object which is a 'person' for which I actually want >> to ensure I have valid dates for birth, marriage and death and an >> integer 'no of siblings' then I have a set

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-26 Thread Lester Caine
On 26/05/16 20:16, Fleshgrinder wrote: > On 5/26/2016 9:10 PM, Lester Caine wrote: >> DateTime is probably a better example to work with than 'int' since it >> already has a long pedigree of problems and clashes where many projects >> had their own interpretation and still

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-26 Thread Lester Caine
ood reasons that the initialization is later then the 'construct' be that a DateTime or an int ... null is the correct way of indicating that 'as yet we do not have the value of type xxx' just as it does for an untyped value, so trying to make a special case to block it's use is simply strangling nor

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-26 Thread Lester Caine
need different functions to access them. Within a class isset($x) should mirror isset($this->x) and exists($x) makes sense along with other 'object' related functions, but is there no way to get back to a lot simpler consistent handling of variables ... and a more constructive way to add f

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-25 Thread Lester Caine
ps the 'fault' that isset does not actually work properly is biting? But since $a->z does not exist false avoids an error. > var_dump($a->z); // 0 + notice The notice should be 'variable does not exist' as at this point $a->z has no context at all! -- Lester Caine - G8HFL

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-25 Thread Lester Caine
es that '0' records were returned. If you are reading a set of fields for which some have no matching values then these are returned as 'NULL' while the rest will be populated. NULL is ALWAYS a 'state' meaning that this field is undefined or more accurately unset. -- Lester Caine - G8HFL

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-25 Thread Lester Caine
riable does not exist. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rainbow Digital Media

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-25 Thread Lester Caine
ch may or may not be set along with a 'now' few more attributes to constrain what that value is restricted to contain. unset simply removes that name and content from the list and leaving any 'trail' which prevents creating a totally clean use of the same name is simply wrong?

Re: [PHP-DEV] [RFC][Vote] Typed Properties

2016-05-20 Thread Lester Caine
I can even see the addition of a 'read only' flag to solve that problem while still constraining the initial setting of a domain. But this is simply user land code and does not need a small subset of elements of it added to the code base? -- Lester Caine - G8HFL - Contac

Re: [PHP-DEV] Re: [RFC][VOTE] Nullable Types

2016-05-12 Thread Lester Caine
hints then this is were the using code needs to be checked? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http:/

Re: [PHP-DEV] Re: [RFC][VOTE] Nullable Types

2016-05-12 Thread Lester Caine
On 12/05/16 12:39, Michael Wallner wrote: > On 12/05/16 13:36, Lester Caine wrote: >> > On 12/05/16 11:21, Davey Shafik wrote: >>> >> E.g. the behavior of passing executing with a null value for the >>> >> argument is something you should be consciousl

Re: [PHP-DEV] Re: [RFC][VOTE] Nullable Types

2016-05-12 Thread Lester Caine
is that I HAVE to add the '?' for many of my libraries to continue to work simply because they do handle the null case. So what was a working system is broken by this change. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic

Re: [PHP-DEV] [RFC DRAFT] Automatic CSRF Protection

2016-05-12 Thread Lester Caine
best chargeable security, and there is now at least a path that can be documented to help them which includes https, sessions and authentication? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.

Re: [PHP-DEV] [RFC DRAFT] Automatic CSRF Protection

2016-05-11 Thread Lester Caine
Post from tablet seems to have gone missing ... On 11/05/16 16:41, Andrey Andreev wrote: > On Wed, May 11, 2016 at 5:46 PM, Lester Caine <les...@lsces.co.uk> wrote: > >> On 11/05/16 14:40, Andrey Andreev wrote: >>> Therefore, while the session store *after l

Re: [PHP-DEV] [RFC DRAFT] Automatic CSRF Protection

2016-05-11 Thread Lester Caine
an see that some people would want to ensure that anonymous content was 'secure', but isn't that the job of https? -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysol

Re: AW: [PHP-DEV] [RFC] Allow loading extensions by name

2016-05-11 Thread Lester Caine
nds a copy of a 'library' which is the main problem here, and in my case it's finding copies of the gds32.dll which are the wrong format for the php_interbase.dll extension. I'm seeing the same problem with other third party clients, so in my book it is important to keep using the extension so one knows exac

Re: [PHP-DEV] Re: [RFC][VOTE] Nullable Types

2016-05-11 Thread Lester Caine
?' throws an error the workflow is broken after the event where a user code warning would be more helpful. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.co

Re: AW: [PHP-DEV] [RFC] Allow loading extensions by name

2016-05-11 Thread Lester Caine
On 11/05/16 07:20, Christian Stoller wrote: > Apache modules on Windows also have the .so suffix. THAT was what I was forgetting ;) -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co

<    1   2   3   4   5   6   7   8   9   10   >