Hacker News new | past | comments | ask | show | jobs | submit login

Well that just makes me go WTF.

I genuinely can't think of a way this will be used which will be positive for PHP.




In theory, it will have the exact same use as the rubyracer gem (http://rubygems.org/gems/therubyracer). Possible uses of that are compiling coffee script using the official compiler or running the same form validation code on both the client- and the server side.

In general I'd be cautious about both the ruby racer and this as you are practically embedding a garbage-collected heap into another garbage collected heap, exchanging references between them (more so for the ruby racer - the PHP extension here is way less integrated).

This is memory errors waiting to happen.


"or running the same form validation code on both the client- and the server side."

That sounds great until you realize that you usually do a lot more validation on the server than on the client (is the username taken, is password correct, etc etc). So you would still have to use PHP for validation (in most cases).


Sure, but only for the cases not covered by the JS.


I was trying to say that you don't really gain anything in this case. You would load some JS file (which would probably have to be written in a way that it could be used this way) just do do some simple validation (if (someField!='') for instance). Doesn't seem like worth the bother to me.


This extension has been around for a long time, just like the PHP Lua extension.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: