File: /home/petsclubcc/shopteste/wp-content/plugins/dev 2/includes/template.php
<?php
function template(){?>
<style>
.column {
width: 100%;
}
#btn{
border-radius: 5px;
border: 0.5px solid gray;
position: absolute;
left: 40%;
bottom:30%;
padding: 5px 20px 5px ;
}
p{
padding-left: 150px;
margin: 0;
font-size:10px;
color: gray;
}
#inputdiv{
padding-top:10px;
}
hr{
padding : 0px 0px;
width:100%;
}
#container{
padding :25px 30px 100px;
border-radius: 5px;
background-color: rgb(0,0,0); /* Fallback color */
background-color: rgba(255,255,255,1); /* Black w/ opacity */
border: 0.5px solid gray;
}
legend{
padding-left: 0px;
}
fieldset {
position: relative;
}
input {
width: 70%;
padding: 0;
margin: 0;
box-sizing: border-box;
border-radius:5px;
background-color: #3CBC8D;
color: white;
}
#image_plugin {
display: block;
margin-left: auto;
margin-right: auto;
height: 200px;
}
label {
display: inline-block;
width: 140px;
text-align: right;
}
</style>
<script type = "text/javascript">
function refreshPage(){
window.location.reload();
}
</script>
<img id="image_plugin"src="<?php echo __('https://firebasestorage.googleapis.com/v0/b/shopmyinfluens.appspot.com/o/ressources%20SMI%2Fshopify_app_config_logo_en.png?alt=media&token=164bb758-c343-46f2-9b6b-c2f94208e519','shop-my-influence');?>">
<form method="post">
<fieldset>
<div id="container">
<legend><strong><?php echo __('PLUGIN SETTINGS','shop-my-influence');?></strong></legend>
<hr>
<div id="inputdiv"><label for="Commission"><strong><?php echo __('Commission','shop-my-influence');?></strong></label>
<?php
require_once('data_fetch_smiclickid.php');
$commission_amount_db=fetch_smiclickid();
?>
<input type="number" min="0" max="100" name="cmsn" id="commission" value="<?php echo($commission_amount_db); ?>" required />
<br><br>
<?php
if(isset($_POST['refresh'])) {
//include "Mon script qui update ma database";
header('Location admin.php?page=my-admin-menu');
}
?>
<p><?php echo __('Please enter the percentage of the sale price that will be paid out as commission for each transaction. Only include the numeric value representing the percentage rate. For example, enter 10 for a 10% commission. Do not include the percent symbol (%). ','shop-my-influence');?></p>
<button id="btn" name="refresh" type="submit" ><?php echo __('SAVE','shop-my-influence');?></button>
</div>
</div>
</fieldset>
</form>
<?php
}