trying to figure out how to write this with arrays
<p>here is the code im having trouble with</p>

<pre><code>$key = array(
"0" =&gt; "sss",
"1" =&gt; "wst",
"2" =&gt; "sfv",
"3" =&gt; "lac",
"4" =&gt; "sgv",
"5" =&gt; "lgb",
"6" =&gt; "ant"
);

$urls = array(
"0" =&gt; "http://www.sarmenhb.com/index.php?key=",
"1" =&gt; "http://www.navidoor.com/index.php?key=",
"2" =&gt; "http://www.worldexchange.com/index.php?key=",
"3" =&gt; "http://www.iaddesign.com/index.php?key=",
"4" =&gt; "http://www.iadesignandstudio.com/index.php?key=",
"5" =&gt; "http://www.redlineautoleasing.com/index.php?key="

);

for($a=0;$a &lt;= count($urls);$a++) {
foreach($key as $keys) {
print $urls[$a].$keys[$a]."&lt;br/&gt;";

}
}

print "&lt;br/&gt;&lt;br/&gt;";
</code></pre>

<p>i am trying to make the output look like this:</p>

<pre><code>http://www.sarmenhb.com/index.php?key=sss
http://www.navidoor.com/index.php?key=sss
http://www.worldexchange.com/index.php?key=sss
http://www.iaddesign.com/index.php?key=sss
http://www.iadesignandstudio.com/index.php?key=sss
http://www.redlineautoleasing.com/index.php?key=sss

http://www.sarmenhb.com/index.php?key=wst
http://www.navidoor.com/index.php?key=wst
http://www.worldexchange.com/index.php?key=wst
http://www.iaddesign.com/index.php?key=wst
http://www.iadesignandstudio.com/index.php?key=wst
http://www.redlineautoleasing.com/index.php?key=wst

etc including all key values included as a value the the param key
</code></pre>

<p>ive removed the origional urls to prevent url hacking but how can i print an output like that?</p>

<p>the output i keep getting is key=s or key=w  the whole key value isnt displaying. along with an error of Notice: Uninitialized string offset: 3 in D:\wamp\www\MVC\t.php on line 32</p>

<p>please help</p>

<p>thank alot!</p>
