<?php
 require_once("../../../wp-load.php");
 global $wpdb;
 $table_name = $wpdb->prefix . "jack_jacker_pages";
 $P=$_POST['P'];
 
 $re = $wpdb->get_results( " SELECT * FROM ".$wpdb->prefix."jack_jacker_pages WHERE WPPage='$P' " );
 
 $WPPage=$re['0']->WPPage;
 $URL=$re['0']->URL;
 $Link=$re['0']->Link;
 $BarColor=$re['0']->BannerColor;
 $BarText=$re['0']->BannerText;
 $LinkColor=$re['0']->BannerTextColor;
 $JackTitle=$re['0']->JackTitle;
?>
 


<br>
<table style="width:100%; font-size:16px; font-family:sans-serif; font-weight:900;">
     </td>
    </tr> 
    <tr>
     <td>Jack Title</td>
     <td><input type="text" id="JackTitle" style="width:350px; font-size:18px; font-family:sans-serif; font-weight:900;" value="<?php echo $JackTitle; ?>"></td>
    </tr>
    <tr>
    <tr>
     <td>URL To Jack</td>
     <td><input type="text" id="URL" style="width:350px; font-size:18px; font-family:sans-serif; font-weight:900;" value="<?php echo $URL; ?>"></td>
    </tr>
    <tr>
     <td>Bar Color</td>
    <td>
       <select id="BarColor">
        <option value="000000">Black</option>
        <option value="FFFFFF" <?php if ($BarColor=="FFFFFF"){echo "selected='selected'";} ?>>White</option>
        <option value="FF2A2A" <?php if ($BarColor=="FF2A2A"){echo "selected='selected'";} ?>>Red</option>
        <option value="AB5656" <?php if ($BarColor=="AB5656"){echo "selected='selected'";} ?>>Dark Red</option>
        <option value="00FF00" <?php if ($BarColor=="00FF00"){echo "selected='selected'";} ?>>Green</option>
        <option value="56AB56" <?php if ($BarColor=="56AB56"){echo "selected='selected'";} ?>>Dark Green</option>
        <option value="00AAFF" <?php if ($BarColor=="00AAFF"){echo "selected='selected'";} ?>>Blue</option>
        <option value="2B55D5" <?php if ($BarColor=="2B55D5"){echo "selected='selected'";} ?>>Dark Blue</option>
        <option value="FFFF00" <?php if ($BarColor=="FFFF00"){echo "selected='selected'";} ?>>Yellow</option>
        <option value="9515EA" <?php if ($BarColor=="9515EA"){echo "selected='selected'";} ?>>Purple</option>
       </select>
     </td>
    <tr>
     <td>Bar Text</td>
     <td><input type="text" id="BarText" style="width:350px; font-size:18px; font-family:sans-serif; font-weight:900;" value="<?php echo $BarText; ?>"></td>
    </tr>
    <tr>
     <td>Bar Text Color</td>
     <td>
       <select id="LinkColor">
        <option value="000000">Black</option>
        <option value="FFFFFF" <?php if ($LinkColor=="FFFFFF"){echo "selected='selected'";} ?>>White</option>
        <option value="FF2A2A" <?php if ($LinkColor=="FF2A2A"){echo "selected='selected'";} ?>>Red</option>
        <option value="AB5656" <?php if ($LinkColor=="AB5656"){echo "selected='selected'";} ?>>Dark Red</option>
        <option value="00FF00" <?php if ($LinkColor=="00FF00"){echo "selected='selected'";} ?>>Green</option>
        <option value="56AB56" <?php if ($LinkColor=="56AB56"){echo "selected='selected'";} ?>>Dark Green</option>
        <option value="00AAFF" <?php if ($LinkColor=="00AAFF"){echo "selected='selected'";} ?>>Blue</option>
        <option value="2B55D5" <?php if ($LinkColor=="2B55D5"){echo "selected='selected'";} ?>>Dark Blue</option>
        <option value="FFFF00" <?php if ($LinkColor=="FFFF00"){echo "selected='selected'";} ?>>Yellow</option>
        <option value="9515EA" <?php if ($LinkColor=="9515EA"){echo "selected='selected'";} ?>>Purple</option>
       </select>
     </td>
    </tr>
    <tr>
     <td>Link URL</td>
     <td><input type="text" id="Link" style="width:350px; font-size:18px; font-family:sans-serif; font-weight:900;" value="<?php echo $Link; ?>"></td>
    </tr>
    
     
</table>

  </div>
  
  <center>
   <button onclick="editNow('<?php echo $WPPage; ?>');" style="font-weight:900; font-size:18px; padding:5px;">Save Now</button>
  </center>    
  
  <br>&nbsp;<br>
