]]jkjjgdjffksdkdxmnvbcbcvbvcbbbbbbbbbvcbcbvcbmnmbnwqeqwewqskfgj
במ12[cvbnvbnvcvbcvbcvbvvvccccccccccccccvbcvbcvbnmnmqewv;'
/
home
/
u729855735
/
domains
/
stylebyou.com
/
public_html
/
admin
/
Upload FileeE
HOME
<?php require('inc/db.php'); if(isset($_POST['create'])){ $sku = mysqli_real_escape_string($conn, $_POST['sku']); $prdct_nm = mysqli_real_escape_string($conn, $_POST['prdct_nm']); $prdct_price = mysqli_real_escape_string($conn, $_POST['prdct_price']); $prdct_sale_price = mysqli_real_escape_string($conn, $_POST['prdct_sale_price']); $prd_cat = mysqli_real_escape_string($conn, $_POST['cat']); $tag = mysqli_real_escape_string($conn, $_POST['tag']); $prd_type = mysqli_real_escape_string($conn, $_POST['pr_type']); $affiliate_link = mysqli_real_escape_string($conn, $_POST['affiliate_link']); $desc = mysqli_real_escape_string($conn, $_POST['desc']); $short_desc = mysqli_real_escape_string($conn, $_POST['short_desc']); $logo = $_FILES['prdct_img']['name']; $logo = preg_replace("/[^a-zA-Z0-9\.\-]/", "_", $logo); $temp_name = $_FILES['prdct_img']['tmp_name']; $file_size = $_FILES['prdct_img']['size']; $file_destination = "uploads/".$logo; $prdct_weight = mysqli_real_escape_string($conn, $_POST['prdct_weight']); $length = mysqli_real_escape_string($conn, $_POST['length']); $width = mysqli_real_escape_string($conn, $_POST['width']); $height = mysqli_real_escape_string($conn, $_POST['height']); $purchase_note = mysqli_real_escape_string($conn, $_POST['purchase_note']); $insert = "INSERT INTO product(sku,pr_nm,pr_price,sale_price,pr_cat,pr_img,pr_desc,prd_type,status,affiliate_link,stock,sold_individual,weight,length,width,height,note,review,featured,best_seller,short_desc,tag) VALUES('$sku','$prdct_nm','$prdct_price','$prdct_sale_price','$prd_cat','$logo','$desc','$prd_type',1,'$affiliate_link',1,0,'$prdct_weight','$length','$width','$height','$purchase_note',1,1,1,'$short_desc','$tag')"; $run = mysqli_query($conn,$insert); if($run){ move_uploaded_file($temp_name, $file_destination); echo "<script>alert('Product created successfully'); location.href='add_product.php'; </script>"; } else{ echo "<script>alert('Something went wrong!'); location.href='add_product.php'; </script>"; } } ?>