<?php

        //Get all needed includes
        require_once dirname(__FILE__) . DIRECTORY_SEPARATOR . &#039;ArmoryStream&#039; . DIRECTORY_SEPARATOR . &#039;ArmoryStream.php&#039;;
        require_once dirname(__FILE__) . DIRECTORY_SEPARATOR . &#039;ArmoryStream&#039; . DIRECTORY_SEPARATOR . &#039;Page&#039; . DIRECTORY_SEPARATOR . &#039;Achievements.php&#039;;

        //Setup the StreamObject and tell it to use the european Armory data.
        //Also register the cache object
        $oClient = new ArmoryStream();
        $oClient->setLocation( ArmoryStream::LOCATION_EUROPE );

        //Setup the PageObject. Use the Achievement page and get FeastsOfStrength of a character
        $oCharacterPage = new ArmoryStream_Page_Achievements();
        $oCharacterPage->setCharacter(&#039;Nnoitra&#039;)
                ->setRealm(&#039;Gul&#039;dan&#039;)
                ->setCategory( ArmoryStream_Page_Achievements::CATEGORY_FEASTSOFSTRENGTH );

        //Try to stream the ArmoryData into the AchievementPage object
        try {
                $oClient->streamIntoPage( $oCharacterPage );
        } catch ( Exception $oException ) {
                if ( $oException instanceof ArmoryStream_Page_Exception ) {
                        echo "Armory error: " . $oException->getArmoryMessage();
                }
                else {
                        echo "An error has occured: " . $oException->getMessage();
                }
                die();
        }

        //Write the FeastsOfStrength into the HTTP-Response
        echo "Nnoitra of Gul&#039;dan<br />";
        foreach ( $oCharacterPage->Xml->category->achievement as $oAchievement ) {
                echo "
                        <img width=&#039;18px&#039; height=&#039;18px&#039; src=&#039;http://eu.wowarmory.com/wow-icons/_images/51x51/".$oAchievement[&#039;icon&#039;].".jpg&#039; />
                        ".$oAchievement[&#039;title&#039;]."<br />
                ";
        }

Add a code snippet to your website: www.paste.org