3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Create the keypair $res=openssl_pkey_new(); // Get private key openssl_pkey_export($res, $privkey); // Get public key $pubkey=openssl_pkey_get_details($res); $pubkey=$pubkey["key"]; print_r($pubkey); print_r("\n<br>\n") print_r($privkey);
Output for 5.4.1 - 5.4.45, 5.5.24 - 5.5.30, 5.6.8 - 5.6.14
Parse error: syntax error, unexpected 'print_r' (T_STRING) in /in/Zg6VW on line 14
Process exited with code 255.

preferences:
183.22 ms | 1395 KiB | 65 Q