<span style="font-family: courier;"><br>I'm trying to add a style= key/value argument to a directive, and having a problem with ParseArgs not working as I expect.</span><br style="font-family: courier;"><br style="font-family: courier;"><span style="font-family: courier;">I tried my sample syntax at Cookbook/ParseArgs#demo and it seemed to parse it just fine. However, it doesn't work in my code. I just updated my PmWiki from SVN (rev 1582) and it still doesn't work.</span><br style="font-family: courier;"><br style="font-family: courier;"><span style="font-family: courier;">Specifically, I have a directive that I define as</span><br style="font-family: courier;"><br style="font-family: courier;"><span style="font-family: courier;">&nbsp;&nbsp; Markup( 'hrule', 'directives', '/\\(:hr (.*?):\\)/e', "Keep(Hrule('$1'))" );</span><br style="font-family: courier;"><br style="font-family: courier;"><span style="font-family: courier;">&nbsp;&nbsp; function Hrule( $args ) </span><br
 style="font-family: courier;"><span style="font-family: courier;">&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // debug output<br>&nbsp; &nbsp; &nbsp;&nbsp; print "&lt;pre&gt;";</span><br style="font-family: courier;"><span style="font-family: courier;">&nbsp; &nbsp; &nbsp;&nbsp; print_r( $args );</span><br style="font-family: courier;"><span style="font-family: courier;">&nbsp; &nbsp; &nbsp;&nbsp; print "&lt;/pre&gt;\n";</span><br style="font-family: courier;"><span style="font-family: courier;">&nbsp;&nbsp; </span><br style="font-family: courier;"><span style="font-family: courier;">&nbsp; &nbsp; &nbsp;&nbsp; $args = ParseArgs( $args );</span><br style="font-family: courier;"><span style="font-family: courier;">&nbsp;  <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // debug output<br>&nbsp; &nbsp; &nbsp;&nbsp; print "&lt;pre&gt;";</span><br style="font-family: courier;"><span style="font-family: courier;">&nbsp; &nbsp; &nbsp;&nbsp; print_r( $args );</span><br
 style="font-family: courier;"><span style="font-family: courier;">&nbsp; &nbsp; &nbsp;&nbsp; print "&lt;/pre&gt;\n";</span><br style="font-family: courier;"><br style="font-family: courier;"><span style="font-family: courier;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ....</span><br style="font-family: courier;"><br style="font-family: courier;"><span style="font-family: courier;">When I enter </span><br style="font-family: courier;"><br style="font-family: courier;"><span style="font-family: courier;">&nbsp;&nbsp; (:hr style="height: 1px; width: 1px;":)<br><br>I see this debug output:<br><br>&nbsp;&nbsp; style=\"height: 1px; width: 1px;\"<br><br>&nbsp;&nbsp; Array<br>&nbsp;&nbsp; (<br>&nbsp;&nbsp;&nbsp; [#] =&gt; Array<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [0] =&gt; style<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [1] =&gt;
 \"height:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [2] =&gt; <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [3] =&gt; 1px;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [4] =&gt; width<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [5] =&gt; width:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [6] =&gt; <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [7] =&gt; 1px;\"<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; )<br><br>&nbsp;&nbsp;&nbsp; [style] =&gt; \"height:<br>&nbsp;&nbsp;&nbsp; [] =&gt; Array<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [0] =&gt; 1px;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [1] =&gt; 1px;\"<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; )<br><br>&nbsp;&nbsp;&nbsp; [width] =&gt; width:<br>&nbsp;&nbsp;
 )<br><br>However, when I enter<br><br>&nbsp;&nbsp; style="height: 1px; width: 2px;"<br><br>into the ParseArgs field at http://www.pmwiki.org/wiki/Cookbook/ParseArgs#demo and click the ParseArgs button, I see:<br><br>&nbsp; Key&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; Value(s)<br>&nbsp; ---------&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; --------<br>&nbsp; $arg['#']&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (array) 'style' 'height: 1px; width: 2px;'<br>&nbsp; $arg['style'] 'height: 1px; width: 2px;'<br><br>What am I doing wrong or differently than whatever the ParseArgs button on pmwiki.org is doing?<br><br>--Tony<br></span><br style="font-family: courier;"><BR><BR>~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~<br>Whenever a theory appears to you as the only possible one,<br>take this as a sign that you have neither understood the theory<br>nor the problem which it was intended to solve. -- Karl Popper<br>~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~<br>HOME PAGE:
 www.awcfamily.com<br><br>I have no control over anything that appears after this sentence.<p>&#32;
                <hr size=1>How low will we go? Check out Yahoo! Messenger’s low <a href="http://us.rd.yahoo.com/mail_us/taglines/postman8/*http://us.rd.yahoo.com/evt=39663/*http://voice.yahoo.com"> PC-to-Phone call rates.