Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if ($dragon_breed != '')
- {
- // First, let's see what $dragon_breed contains
- var_dump($dragon_breed);
- echo "<BR>";
- // That displayed the ID of the breed. Now let's get the name of the breed.
- $breedid = $dragon_breed;
- $breeddata = new Pod('breeds', $breedid);
- echo 'Breed: ' . $breeddata->display('name') . "<BR>";
- // Name of the breed is being displayed, now let's get the name of the artist with a simple display
- echo 'Artist name: ' . $breeddata->display('artist') . "<BR>";
- // With this result we can't get the artist link, so let's see if we can get the artist id instead. First, let's get the artist info in a different way.
- $dragon_artist = $breeddata->get_field('artist');
- var_dump($dragon_artist);
- echo "<BR>";
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement