Productive Friday

Stay Productive Even on Friday

Displaying Code in WordPress

There is several ways to display code in WordPress.

1. This text using WordPress feature Code Block.

<?php 
echo phpversion(); 
?>

2. Paste your code on Hilite.me and paste the result on WordPress Code View editor.

1
2
3
<?php 
echo phpversion();
?>

3. Using prism.js. Here the example for displaying php script.