forked from oraoto/pib
-
-
Notifications
You must be signed in to change notification settings - Fork 72
Open
Description
$a = new \Vrzno;
var_dump(($type = \getVrznoType($a->__php_action)) === \getVrznoType($a->__php_action)); // false
var_dump($type); // WindowPhpActionS
var_dump(($type = \getVrznoType($a->__php_action)) === \getVrznoType($a->__php_action)); // true
var_dump($type); // WindowPhpAct
var_dump(($type = \getVrznoType($a->__php_action)) === \getVrznoType($a->__php_action)); // true
var_dump($type); // WindowPhpActionService
var_dump(($type = \getVrznoType($a->__php_action)) === \getVrznoType($a->__php_action)); // true
var_dump($type); // WindowPhpActionServiceThe names of js objects can be obtained via print_r or var_dump.
function getVrznoType(object $obj): string
{
if ($obj::class === \Vrzno::class) {
$value = \print_r($obj, true);
$value = \trim($value);
\preg_match('/^([a-z]+)/i', $value, $m);
return $m[0] ?? '';
}
return $obj::class;
}window.__php_action = new WindowPhpActionService;I use https://cdn.jsdelivr.net/npm/php-wasm@0.0.8/PhpWeb.mjs
what is the stable version at the moment?
Metadata
Metadata
Assignees
Labels
No labels