title: PHP and RegEx to grab a value inside of a string
body: <p>Using PHP and RegExp I need to grab the value inside of <code>&lt;rdf:li xml:lang="x-default"&gt;</code> and <code>&lt;/rdf:li&gt;</code></p>
  
  <p>So the string I need a value from will have this line in it...</p>
  
  <p><code>&lt;rdf:li xml:lang="x-default"&gt;Yuengling Americas Oldest Brewery Huffmans Pub &amp;amp; Grub 60x30 5&lt;/rdf:li&gt;</code></p>
  
  <p>I need to get the <code>Yuengling Americas Oldest Brewery Huffmans Pub &amp;amp; Grub 60x30 5</code> into a PHP variable.  I'm not good with Regex, could someone help me to get this value?</p>
  
  <pre><code>$str = '&lt;rdf:li xml:lang="x-default"&gt;Yuengling Americas Oldest Brewery Huffmans Pub &amp;amp; Grub 60x30 5&lt;/rdf:li&gt;';
  </code></pre>
  
  <p>My string comes from reading the contents of an .AI file....</p>
  
  <pre><code>%PDF-1.5
  %âãÏÓ
  1 0 obj
  &lt;&lt;/Metadata 2 0 R/OCProperties&lt;&lt;/D&lt;&lt;/ON[7 0 R]/Order 8 0 R/RBGroups[]&gt;&gt;/OCGs[7 0 R]&gt;&gt;/Pages 3 0 R/Type/Catalog&gt;&gt;
  endobj
  2 0 obj
  &lt;&lt;/Length 67315/Subtype/XML/Type/Metadata&gt;&gt;stream
  &lt;?xpacket begin="ï»¿" id="W5M0MpCehiHzreSzNTczkc9d"?&gt;
  &lt;x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 5.3-c011 66.145661, 2012/02/06-14:56:27        "&gt;
     &lt;rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"&gt;
        &lt;rdf:Description rdf:about=""
              xmlns:dc="http://purl.org/dc/elements/1.1/"&gt;
           &lt;dc:format&gt;application/pdf&lt;/dc:format&gt;
           &lt;dc:title&gt;
              &lt;rdf:Alt&gt;
                 &lt;rdf:li xml:lang="x-default"&gt;Yuengling Americas Oldest Brewery Huffmans Pub &amp;amp; Grub 60x30 5&lt;/rdf:li&gt;
              &lt;/rdf:Alt&gt;
           &lt;/dc:title&gt;
        &lt;/rdf:Description&gt;
        &lt;rdf:Description rdf:about=""
              xmlns:xmp="http://ns.adobe.com/xap/1.0/"
              xmlns:xmpGImg="http://ns.adobe.com/xap/1.0/g/img/"&gt;
           &lt;xmp:MetadataDate&gt;2014-04-01T16:13-05:00&lt;/xmp:MetadataDate&gt;
           &lt;xmp:ModifyDate&gt;2014-04-01T16:13-05:00&lt;/xmp:ModifyDate&gt;
           &lt;xmp:CreateDate&gt;2014-04-01T16:13-05:00&lt;/xmp:CreateDate&gt;
           &lt;xmp:CreatorTool&gt;Adobe Illustrator CS6 (Windows)&lt;/xmp:CreatorTool&gt;
           &lt;xmp:Thumbnails&gt;
              &lt;rdf:Alt&gt;
                 &lt;rdf:li rdf:parseType="Resource"&gt;....
  </code></pre>