lundi 5 février 2018

my checkboxes doesn't show ticks selected

This is my checkbox code for sending checked boxes to MySQL table.

In this page /Coach/index.php there is sql code for send information of form to the MySQL tables.

I can successfully send the checkbox Value "on" to the tables but after page returned in the form it doesn't show ticks selected!

This form is for users select the players by tick in the checkboxes , I want every checkbox that checked by user become save and after submit the form and page returned it shows the checkboxes checked by every user!

what should i do in my code ? I appreciate any guidance.

   <div id="wb_Form3" style="position:absolute;width:299px;height:328px;">
    <form name="Coach" method="post" action="/Coach/index.php" id="Form3" onclick="window.location.href='/League.php;return false;">
    <input type="checkbox" id="Checkbox19" name="GoalKeeperBox1" value="on" style="position:absolute;left:28px;top:37px;z-index:47;">
    <div id="wb_Text186" style="position:absolute;left:8px;top:38px;width:21px;height:16px;z-index:48;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>1</strong></span></div>
    <div id="wb_Text187" style="position:absolute;left:7px;top:17px;width:71px;height:17px;z-index:49;">
    <span style="color:#1E1E1E;font-family:Arial;font-size:12px;"><strong>Goalkeeper</strong></span><span style="color:#F5F5F5;font-family:Arial;font-size:12px;"><strong><br></strong></span></div>
    <input type="checkbox" id="Checkbox20" name="GoalKeeperBox12" value="on" style="position:absolute;left:87px;top:37px;z-index:50;">
    <div id="wb_Text188" style="position:absolute;left:67px;top:38px;width:21px;height:16px;z-index:51;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>12</strong></span></div>
    <input type="checkbox" id="Checkbox21" name="GoalKeeperBox15" value="on" style="position:absolute;left:147px;top:37px;z-index:52;">
    <div id="wb_Text189" style="position:absolute;left:127px;top:38px;width:21px;height:16px;z-index:53;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>15</strong></span></div>
    <div id="wb_Text190" style="position:absolute;left:8px;top:69px;width:70px;height:17px;z-index:54;">
    <span style="color:#1E1E1E;font-family:Arial;font-size:12px;"><strong>Defensive<br></strong></span></div>
    <input type="checkbox" id="Checkbox22" name="DefensiveBox2" value="on" style="position:absolute;left:28px;top:90px;z-index:55;">
    <div id="wb_Text191" style="position:absolute;left:8px;top:91px;width:21px;height:16px;z-index:56;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>2</strong></span></div>
    <input type="checkbox" id="Checkbox23" name="DefensiveBox3" value="on" style="position:absolute;left:87px;top:90px;z-index:57;">
    <div id="wb_Text192" style="position:absolute;left:67px;top:91px;width:21px;height:16px;z-index:58;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>3</strong></span></div>
    <input type="checkbox" id="Checkbox24" name="DefensiveBox4" value="on" style="position:absolute;left:147px;top:90px;z-index:59;">
    <div id="wb_Text193" style="position:absolute;left:127px;top:91px;width:21px;height:16px;z-index:60;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>4</strong></span></div>
    <input type="checkbox" id="Checkbox25" name="DefensiveBox5" value="on" style="position:absolute;left:207px;top:90px;z-index:61;">
    <div id="wb_Text194" style="position:absolute;left:187px;top:91px;width:21px;height:16px;z-index:62;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>5</strong></span></div>
    <div id="wb_Text199" style="position:absolute;left:247px;top:91px;width:21px;height:16px;z-index:63;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>16</strong></span></div>
    <div id="wb_Text200" style="position:absolute;left:127px;top:58px;width:55px;height:11px;z-index:64;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:9.3px;"><strong>Superstar</strong></span></div>
    <div id="wb_Text203" style="position:absolute;left:8px;top:122px;width:71px;height:17px;z-index:65;">
    <span style="color:#1E1E1E;font-family:Arial;font-size:12px;"><strong>Midfielder<br></strong></span></div>
    <input type="checkbox" id="Checkbox27" name="MidfielderBox6" value="on" style="position:absolute;left:28px;top:144px;z-index:66;">
    <div id="wb_Text204" style="position:absolute;left:8px;top:145px;width:21px;height:16px;z-index:67;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>6</strong></span></div>
    <input type="checkbox" id="Checkbox28" name="MidfielderBox7" value="on" style="position:absolute;left:87px;top:144px;z-index:68;">
    <div id="wb_Text205" style="position:absolute;left:67px;top:145px;width:21px;height:16px;z-index:69;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>7</strong></span></div>
    <input type="checkbox" id="Checkbox29" name="MidfielderBox8" value="on" style="position:absolute;left:147px;top:144px;z-index:70;">
    <div id="wb_Text206" style="position:absolute;left:127px;top:145px;width:21px;height:16px;z-index:71;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>8</strong></span></div>
    <input type="checkbox" id="Checkbox30" name="MidfielderBox13" value="on" style="position:absolute;left:207px;top:144px;z-index:72;">
    <div id="wb_Text207" style="position:absolute;left:187px;top:145px;width:21px;height:16px;z-index:73;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>13</strong></span></div>
    <div id="wb_Text208" style="position:absolute;left:247px;top:145px;width:21px;height:16px;z-index:74;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>17</strong></span></div>
    <div id="wb_Text210" style="position:absolute;left:8px;top:176px;width:56px;height:15px;z-index:75;">
    <span style="color:#1E1E1E;font-family:Arial;font-size:12px;"><strong>Forward</strong></span></div>
    <input type="checkbox" id="Checkbox32" name="ForwardBox9" value="on" style="position:absolute;left:29px;top:199px;z-index:76;">
    <div id="wb_Text211" style="position:absolute;left:9px;top:200px;width:21px;height:16px;z-index:77;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>9</strong></span></div>
    <input type="checkbox" id="Checkbox33" name="ForwardBox10" value="on" style="position:absolute;left:88px;top:199px;z-index:78;">
    <div id="wb_Text212" style="position:absolute;left:68px;top:200px;width:21px;height:16px;z-index:79;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>10</strong></span></div>
    <input type="checkbox" id="Checkbox34" name="ForwardBox11" value="on" style="position:absolute;left:148px;top:199px;z-index:80;">
    <div id="wb_Text213" style="position:absolute;left:128px;top:200px;width:21px;height:16px;z-index:81;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>11</strong></span></div>
    <input type="checkbox" id="Checkbox35" name="ForwardBox14" value="on" style="position:absolute;left:208px;top:199px;z-index:82;">
    <div id="wb_Text214" style="position:absolute;left:188px;top:200px;width:21px;height:16px;z-index:83;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>14</strong></span></div>
    <div id="wb_Text215" style="position:absolute;left:248px;top:200px;width:21px;height:16px;z-index:84;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:13px;"><strong>18</strong></span></div>
    <input type="checkbox" id="Checkbox26" name="DefensiveBox16" value="on" style="position:absolute;left:267px;top:90px;z-index:85;">
    <input type="checkbox" id="Checkbox31" name="MidfielderBox17" value="on" style="position:absolute;left:267px;top:144px;z-index:86;">
    <input type="checkbox" id="Checkbox36" name="ForwardBox18" value="on" style="position:absolute;left:268px;top:199px;z-index:87;">
    <div id="wb_Text202" style="position:absolute;left:239px;top:113px;width:55px;height:11px;z-index:88;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:9.3px;"><strong>Superstar</strong></span></div>
    <div id="wb_Text209" style="position:absolute;left:239px;top:167px;width:55px;height:11px;z-index:89;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:9.3px;"><strong>Superstar</strong></span></div>
    <div id="wb_Text216" style="position:absolute;left:240px;top:222px;width:55px;height:11px;z-index:90;">
    <span style="color:#F5F5F5;font-family:Arial;font-size:9.3px;"><strong>Superstar</strong></span></div>
    <div id="wb_Text158" style="position:absolute;left:10px;top:245px;width:279px;height:42px;text-align:center;z-index:91;">
    <span style="color:#1E1E1E;font-family:Arial;font-size:11px;"><strong>Attention: You can't select more than 11 players. The incorrect composition of players can have bad consequences for the results of your team. </strong></span></div>
    <input type="submit" id="Button25" name="" value="Submit" style="position:absolute;left:97px;top:292px;width:96px;height:25px;z-index:92;">
    </form>
    </div>



Aucun commentaire:

Enregistrer un commentaire