Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $custom_fields = get_post_custom($post->ID);
- $my_custom_field = $custom_fields['my_custom_field'];
- foreach ( $my_custom_field as $key => $value ) {
- if ($key == ‘Level’){
- switch ($value){
- case ‘Easy’:
- echo “<img src=‘easy.gif’>”;
- break;
- case ‘Difficult’:
- echo “<img src=‘difficult.gif’>”;
- break;
- }
- }
- else{
- echo $key . “: " . $value . "<br />";
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement