My code produce URL like this:
http://domain.com/netRacuni/tcpdf/examples/pdf.php?key=bi5u3w2zys1v9sqijomsqyya5ge2v5 How I can make it like this:
http://agroagro.com/bi5u3w2zys1v9sqijomsqyya5ge2v5 so only domain.com+key to be there?
You can a try a rule like this in your root .htaccess.
RewriteEngine On RewriteCond %{QUERY_STRING} ^key=(.+)$ RewriteRule ^netRacuni/tcpdf/examples/pdf.php$ /%1? [L] Edit: Sounds like you want it the other way around. Your question isn't too clear.
RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^([^/]+)/?$ /netRacuni/tcpdf/examples/pdf.php?key=$1 [L]