SitePoint Sponsor

User Tag List

Page 2 of 4 FirstFirst 1234 LastLast
Results 26 to 50 of 87
  1. #26
    SitePoint Addict
    Join Date
    Jan 2005
    Location
    Ireland
    Posts
    349
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Dr Livingston
    [...] but how that would pan out with server side development I have no idea, unless Marcus was referring to something else...
    He mentions AJAX and a cancel button as an example. So, for instance if someone wanted make a search they could type there keyword in an press enter. Now, they may notice they misspelled the keyword(s) and will quickly hit 'Cancel'. This will notify the script that is running (by AJAX) of this event, where the script can decide what to do (for instance, cancel the search).

    That is how I understand it anyway.

  2. #27
    Non-Member
    Join Date
    Jan 2003
    Posts
    5,748
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    > He mentions AJAX and a cancel button as an example.

    Yes... Yes I know that, but I was actually referring to those interrupts themselves, and how they could work from the point of view of the server and host OS in question - the real technicalality that normally would not effect web developers

    As for your further comments, well that's taken care of by the browser, so directly you are not actually interacting with those said interrupts...

    Please re-read my first paragraph on the other post I made to explain what an interrupt is

  3. #28
    SitePoint Addict
    Join Date
    Mar 2005
    Posts
    251
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Definitely put a vote in for the abolition of $this
    I like Pythons way of handling scope in this regard.

    Also like the direction that Rails is taking with .rjs templates, if you could handle your server-side and most of your client-side with one language that would be a lot more fluid.

    The other thing I'd love to lose is the semi colons but that's not really web-specific..

    Mentioned earlier but making security a default is an absolute essential. $_POST and $_GET should be filtered by default, original data should be available in a new $_POST_RAW_BUT_POSSIBLY_QUITE_DANGEROUS superglobal..... that might get the message across.

  4. #29
    SitePoint Addict
    Join Date
    Jan 2005
    Location
    Ireland
    Posts
    349
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Dr Livingston
    Closer to home, these interrupts are what gives you your client side Javascript event handling, but how that would pan out with server side development I have no idea
    Sorry Dr. Livingston, it was this sentence that got me confused. To me this was saying how such a feature could be used in a server-side application, not so much how would such a feature be supported by the technologies that run the server-side application. Sorry for the misunderstanding.

    Quote Originally Posted by Dr. Livingston
    [..] and how they could work from the point of view of the server and host OS in question
    I don't see how the OS is involved. I was under the assumption that by interupts he was more specifically talking about events that happen within the scope of the browser, and how they can communicate with running scripts via AJAX.

    Quote Originally Posted by Dr. Livingston
    As for your further comments, well that's taken care of by the browser, so directly you are not actually interacting with those said interrupts...
    Would you mind expanding? I don't really get what you are trying to say.

  5. #30
    SitePoint Member
    Join Date
    Mar 2006
    Posts
    22
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Seems -to me- like there's two types of interrupts:

    Dr Livingston's: hardware/software interrupts: a signal that temporarily stops the execution of a program so that another procedure can be carried out.

    The more general one: To make a break in; "We interrupt the program for the following messages".

    Sorry for intruding, please do go on with this interesting discussion/brainstorm.

    I've been following Neko with a close eye aswell, since I've been playing around with scaffolding / code generation / (automated) translation of OO to simple procedural code for quite a while now...

  6. #31
    SitePoint Addict mx2k's Avatar
    Join Date
    Jan 2005
    Posts
    256
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    you know, this read/thread really caught my eye, the first one in a long, long while. It is a shame that an ill-placed rant has push this thread somewhat off-topic.

    wysiwyg editors, indeed. Even most modern browsers can not keep up with web standards at this point, and wysiwyg editors die when it comes to being able to use even most basic positioning css attributes, and css is essential to any professional level type of website. I smell sweatshop.

    secondly, tween is an animation word and has been for some time, which flash is heavily animation based.... so your comparison is offbase. A proper comparison would have been pitch (audio) vs tweening (animation). Any seasoned proffessional would not stoop to arguing digital vs analog, but instead use a combination of the two to achieve stunning visual or amazing audio effects. A great illusion is always based to some degree in reality.



    moving on.

    would the perfect web based solution be compiled before or at run time?
    would it be able to support mutilple syntax like with/without $
    would it stuff all functions into an object similar to ruby?
    would hashes and arrays become seperated entities?
    would it support various templating methods?
    would it be modular/component based to the point that you could add as needed?
    I would love to be able to use mixins.
    XML support is a must


    (ps Marcus, if you would look at playing around with the Prototype JS library, I'm sure you would pick it up rather fast, looking at your Caching class example. I've hated javascript till I came across that library. Now i have made a good ways on a nice small reusable library )

  7. #32
    SitePoint Member
    Join Date
    Mar 2006
    Posts
    22
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    would the perfect web based solution be compiled before or at run time?
    Something JIT like. The advantages of scripting & compilation! Are there disadvantages (except initial load time)?

    would it stuff all functions into an object similar to ruby?
    Objects all the way, though I'll get alot of negative responses on that one, since I guess it should be (as?) accessible as PHP is (though being accessible beyond a certain point has disadvantages aswell btw. )

    would it be able to support mutilple syntax like with/without $
    I'd say leave 'em out. Do they add anything except making variables different from constants, which are (okay, should be) uppercase anyway?

    would hashes and arrays become seperated entities?
    Both? As in, you can do anything you want with an array, but you can also explicitly tell the interpreter/compiler that something should be an (integer index) array or a hash, and depend on that functionality / let the compiler optimize.

    Edit: To expand on that last one:

    I was writing a Form class where you'd pass in Text, MultilineText & Select objects and it would render the form / validate, etc. I ran into a bit of a problem with the Select class: I had an addItems() method, which would accept an array. But select element children (<option>'s) can have just values or values and labels. How to differentiate a simple array (just options, whatever the type) from a complex array (where the keys are significant, whether integer/string)... In the end I added an extra parameter to make the distinction

  8. #33
    SitePoint Wizard silver trophy kyberfabrikken's Avatar
    Join Date
    Jun 2004
    Location
    Copenhagen, Denmark
    Posts
    6,157
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by XoloX
    Something JIT like. The advantages of scripting & compilation! Are there disadvantages (except initial load time)?
    An explicit compile step is annoying. PHP's model for this is good, although an opcode-cache should be standard. (It should for PHP too ...)

    Quote Originally Posted by XoloX
    I'd say leave 'em out. Do they add anything except making variables different from constants, which are (okay, should be) uppercase anyway?
    They do allow variable variables, which is rather cool. It could be archieved with eval, but ...

  9. #34
    SitePoint Wizard Ren's Avatar
    Join Date
    Aug 2003
    Location
    UK
    Posts
    1,060
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Not a language feature, but a compiling XSLT down to bytecode would be nice, so can be used in a streamming manner.

  10. #35
    SitePoint Member
    Join Date
    Mar 2006
    Posts
    22
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by kyberfabrikken
    An explicit compile step is annoying. PHP's model for this is good, although an opcode-cache should be standard. (It should for PHP too ...)
    Agreed. +10 for the opcode cache.

    They do allow variable variables, which is rather cool. It could be archieved with eval, but ...
    You're right. eval() should be a last resort only : ).

    / ponders on

  11. #36
    SitePoint Zealot DerelictMan's Avatar
    Join Date
    Oct 2005
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by kyberfabrikken
    They do allow variable variables, which is rather cool.
    Eww. Is there actually a legitimate use for variable variables that cannot be more cleanly accomplished with a simple associative array? Don't variable variables tend to lead to the prototypical spaghetti that PHP programmers are so often criticized for producing?

    Not flamebait, I'm genuinely curious if there are useful (i.e. non-hack) tricks that I could be accomplishing with variable variables that I'm unaware of...

  12. #37
    SitePoint Addict
    Join Date
    Mar 2005
    Posts
    251
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by mx2k
    would the perfect web based solution be compiled before or at run time?
    would it be able to support mutilple syntax like with/without $
    would it stuff all functions into an object similar to ruby?
    would hashes and arrays become seperated entities?
    would it support various templating methods?
    would it be modular/component based to the point that you could add as needed?
    I would love to be able to use mixins.
    XML support is a must
    1. Runtime
    2. Yes. And work back from local to class variable to avoid $this->...
    3. Yes. However PHP seems to be taking the route of providing both Object and procedural syntax as in
    PHP Code:
    $mysqli = new mysqli( .... 
    or
    PHP Code:
    $link mysqli_connect( .... 
    This is probably going to get too confusing the further down this route we go.
    4. Agree with XoloX - both
    5. Essential. It seems different work environments have different needs. We use PHPTAL for templating which is great for designer prototyping. If you are a more tightly disciplined team then perhaps php is enough for templating.
    6. Yes modular with proper namespaces.
    7. Yes. Lack of mixins or multiple inheritance is a bit of a downside to php.
    8. As well as XML built in JSON and YAML woul be great too.

  13. #38
    SitePoint Addict mx2k's Avatar
    Join Date
    Jan 2005
    Posts
    256
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    what about a parser that compiles to bytecode depending on the modified date of a file,

    JSON YAML (most definitely)

  14. #39
    SitePoint Zealot DerelictMan's Avatar
    Join Date
    Oct 2005
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by mx2k
    what about a parser that compiles to bytecode depending on the modified date of a file
    Python takes this approach (compiling .py files to .pyc files and then recompiling if the modification time of the .py is newer than the .pyc) and it seems to work well for them. Perhaps when the opcode cache is made a part of PHP6 it will work this way as well...

  15. #40
    ********* Victim lastcraft's Avatar
    Join Date
    Apr 2003
    Location
    London
    Posts
    2,423
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Hi...

    Quote Originally Posted by mx2k
    you know, this read/thread really caught my eye, the first one in a long, long while. It is a shame that an ill-placed rant has push this thread somewhat off-topic.
    Agreed. I have only now returned to this thread after the interlude.

    Quote Originally Posted by mx2k
    would the perfect web based solution be compiled before or at run time?
    Compile as needed, or optionally ahead of time so taht binary versions of applications can be distributed.

    Quote Originally Posted by mx2k
    would it be able to support mutilple syntax like with/without $
    When the $ is used for string substitution as well as variable, I find I don't that I resent it.

    Quote Originally Posted by mx2k
    would it stuff all functions into an object similar to ruby?
    No. Most web developers are amateurs and they are not going to need OO. We should keep the easy things easy, but make the clever stuff possible. Yes, everything should be an object underneath, but there is no need for this to be explicit. C++ manages to emulate all sorts of syntaxes.

    Quote Originally Posted by mx2k
    would hashes and arrays become seperated entities?
    Yes!

    Quote Originally Posted by mx2k
    would it support various templating methods?
    I think this can be handled with a funky block syntax. A kind of output buffering in reverse.

    Quote Originally Posted by mx2k
    would it be modular/component based to the point that you could add as needed?
    If it's all objects, then there should be no problem.

    Quote Originally Posted by mx2k
    I would love to be able to use mixins.
    It shortcuts the AOP stuff coming out of the Java world.

    Quote Originally Posted by mx2k
    XML support is a must
    Continuations are handy here too. There are some great Scheme and Haskell XML libraries (that drew me into these languages). The line between SAX/Pull/XSLT becomes blurred.

    Quote Originally Posted by mx2k
    if you would look at playing around with the Prototype JS library...
    Other guys I work with specialise in the front end stuff, and I've certainly heard them mention that library. If only I had time to learn everything .

    Regarding AJAX and interrupts, yes it's just a special case of continuations. The feature list was just a quick brain dump.

    yours, Marcus
    Marcus Baker
    Testing: SimpleTest, Cgreen, Fakemail
    Other: Phemto dependency injector
    Books: PHP in Action, 97 things

  16. #41
    SitePoint Wizard stereofrog's Avatar
    Join Date
    Apr 2004
    Location
    germany
    Posts
    4,324
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by DerelictMan
    Eww. Is there actually a legitimate use for variable variables that cannot be more cleanly accomplished with a simple associative array?
    "varvars" are useful as long as php lacks indirect property referencing syntax. If we only had javascript's object[expression]...

  17. #42
    SitePoint Addict timvw's Avatar
    Join Date
    Jan 2005
    Location
    Belgium
    Posts
    354
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    There used to be a time where variable variables really seemed useful...

    Now that i know that they exist in php (and how i have to use them) i just don't seem to run into situations anymore where i could actually use them.

  18. #43
    SitePoint Addict mx2k's Avatar
    Join Date
    Jan 2005
    Posts
    256
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by lastcraft
    No. Most web developers are amateurs and they are not going to need OO. We should keep the easy things easy, but make the clever stuff possible. Yes, everything should be an object underneath, but there is no need for this to be explicit. C++ manages to emulate all sorts of syntaxes.
    i agree with this with the most web developers are amateurs, but let me make sure that i am understanding you correctly. Does "everything should be an object underneath" mean the underlying program language, most likely c++ or would you be able to do prodedural syntax and then it would be stuffed into a global object of some sort?



    Quote Originally Posted by lastcraft
    I think this can be handled with a funky block syntax. A kind of output buffering in reverse.
    an example if you would please. =)



    Quote Originally Posted by lastcraft
    Other guys I work with specialise in the front end stuff, and I've certainly heard them mention that library. If only I had time to learn everything .
    i totally understand. my head has been deep into working over time with javascript and a fusion of js libraries on the dot net platform in conjuction with Atlas (their client js is nightmarish, but the text/xml-script declaration model is interesting , but i'm not sold on it because its placed inline via the html document and declaritive programming from an ms view is another thread entirely ), along with working on ocassionaly connected data synching model for a desktop application....sigh.


    i would also have to add simplied webservice calls to the list, platform portability, and hey, maybe even a comefrom statement......... just for kicks

  19. #44
    SitePoint Addict dek's Avatar
    Join Date
    Oct 2004
    Location
    UK
    Posts
    352
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by stereofrog
    "varvars" are useful as long as php lacks indirect property referencing syntax. If we only had javascript's object[expression]...
    What's wrong with associative arrays?
    Only dead fish go with the flow

  20. #45
    SitePoint Wizard stereofrog's Avatar
    Join Date
    Apr 2004
    Location
    germany
    Posts
    4,324
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Nothing, except they are not the objects In php, you cannot say
    Code:
    $o = new SomeObj;
    echo $o[some + expression];
    and this is exactly the reason why we stll need varvars:
    Code:
    $o = new SomeObj;
    $v = some + expression;
    echo $o->$v;

  21. #46
    SitePoint Wizard Ren's Avatar
    Join Date
    Aug 2003
    Location
    UK
    Posts
    1,060
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by stereofrog
    Nothing, except they are not the objects In php, you cannot say
    Code:
    $o = new SomeObj;
    echo $o[some + expression];
    Isn't that....
    PHP Code:
    class SomeObj
    {
        public 
    $AA 42;
    }
    $o = new SomeObj();
    echo 
    $o->{'A' 'A'}; 
    ?

  22. #47
    SitePoint Wizard silver trophy kyberfabrikken's Avatar
    Join Date
    Jun 2004
    Location
    Copenhagen, Denmark
    Posts
    6,157
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by stereofrog
    Nothing, except they are not the objects In php, you cannot say
    Code:
    $o = new SomeObj;
    echo $o[some + expression];
    and this is exactly the reason why we stll need varvars:
    If I'm not mistaken, it was actually possible at one point (php 4.3.??)

  23. #48
    SitePoint Guru
    Join Date
    May 2005
    Location
    Finland
    Posts
    608
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by XoloX
    Objects all the way, though I'll get alot of negative responses on that one, since I guess it should be (as?) accessible as PHP is (though being accessible beyond a certain point has disadvantages aswell btw. )
    This I have trouble understanding. Who says objects aren't "accessible" and on what grounds does he base the argument on?

    That said, Ruby does it fine in not shoving objects down your throat. Java does not. This (among other things) can be demonstrated by comparing a Ruby "Hello World!" to a Java one.

  24. #49
    Non-Member
    Join Date
    Jan 2003
    Posts
    5,748
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    > That said, Ruby does it fine in not shoving objects down your throat. Java does not.

    I don't believe having a base object as for example Java has, but apart from that one distinct fault, Java does it right in every other respect;

    Anyways, back on topic now?
    Last edited by Dr Livingston; Apr 5, 2006 at 11:23. Reason: ...

  25. #50
    SitePoint Addict mx2k's Avatar
    Join Date
    Jan 2005
    Posts
    256
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    edited. something about a really good dr.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •