PHP code example of ozh / bookmarkletgen

1. Go to this page and download the library: Download ozh/bookmarkletgen library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

ozh / bookmarkletgen example snippets



$javascript = <<<CODE
var link="http://google.com/"; // destination
window.location = link;
CODE;

k = $book->crunch( $javascript );

printf( '<a href="%s">bookmarklet</a>', $link );