i'm making a drop down click menu..and i'm having a god aweful hard time with the syntax. i know how to link URL's just fine usually but this one i'm lacking the common sense for. link part works without a problem..just the $i++ in the value isn't giving me what i need. when selected it should go to cpanel.php?sw=1 for example. Its giving me everything but depending on how i change it up. any suggestions? it's supposed to match the $i++ that's displayed.
<form action="../">
<select class="form" onchange="window.open(this.options[this.selectedIndex].value,'_top')">
<option value="">Choose Week</option>
<?php
$i=1;
do {
echo "<option name='week' value='cpanel.php?sw=.$i++.'>" . "Week" . " " . $i++ . "</option>";
}
while ($i<=7);
echo "</select></form>";