 it worked!

A:

Your header file contains a Byte Order Mark header, not clearly visible be text editors which understand them and do not print them.
Compilers/parser, on the other hand, expect full ASCII, and don't understand BOM marks.
Solution: Remove the 3 first bytes of your header file with an hex editor  or a text editor set to ASCII or UTF8 without BOM encoding and it will work.
below screenshot of the file encoded in UTF8 with BOM with 3 first chars highlighted (using frHed)

If I remove the 3 first bytes it works.
OR: open with Notepad++ and change encoding to ASCII, save, voilà.

 Q:

Mysql PHP insert query not working properly

I have made a script that inserts some information in a mysql database. Whatever value I enter inn the prod_id field, '2147483647' gets inserted in that field. Data is being inserted correctly in all the other fields. Please suggest what may be causing his error?
Here is the concerned code:
<form method="post" name="new_prod" action="new_prod.php">
                <div class="form-group">
                    <input type="text" name="prod_id" class="form-control" placeholder="Enter Product ID" >
                </div>
                <div class="form-group">
                    <input type="text" name="prod_name" class="form-control" placeholder="Enter Product Details" >
                </div>
                <div class="form-group">
                    <input type="text" name="prod_price" class="form-control" placeholder="Enter Product price" >   
                </div>
                <button type="submit" class="btn btn-default" name="sub">Add Product</button>   
            </form>
        </div>
    </div>
</body>
</html>
<?php
$link=mysqli_connect("localhost","root","","smartcart");
if(isset($_POST['sub']))
{
    $prod_id=$_POST['prod_id'];
    $prod_name=$_POST['prod_name'];
    $prod_price=$_POST['prod_price'];
    $a="INSERT into products (prod_
it worked! 

 A: 

 Your header file contains a Byte Order Mark header, not intelligibly visible constitute text editors which understand them and do not print them. 
 Compilers / parser, on the early hand, expect full american standard code for information interchange, and don't sympathize BOM marks. 
 Solution: Remove the 3 first bytes of your header file with an hex editor program   or a text editor set to ASCII or UTF8 without BOM encoding and it will shape. 
 below screenshot of the file encoded in UTF8 with BOM with 3 first chars highlighted (using frHed) 

 If I get rid of the 3 first bytes it works. 
 OR: open with Notepad++ and deepen encoding to ASCII, save, voilà. 

  Q: 

 Mysql PHP insert query not working properly 

 I have made a handwriting that inserts some data in a mysql database. Whatever value I enter inn the prod_id field,' 2147483647' gets inserted in that field. Data is being insert correctly in all the other fields. Please suggest what may be causing his error? 
 Here is the implicated code: 
 < shape method="post " name="new_prod " action="new_prod.php " > 
                 < div class="form - group " > 
                     < input type="text " name="prod_id " class="form - control " placeholder="Enter Product ID " > 
                 < /div > 
                 < div class="form - group " > 
                     < input type="text " name="prod_name " class="form - control " placeholder="Enter Product Details " > 
                 < /div > 
                 < div class="form - group " > 
                     < input type="text " name="prod_price " class="form - control " placeholder="Enter Product price " >   
                 < /div > 
                 < push button type="submit " class="btn btn - default " name="sub">Add Product</button >   
             < /form > 
         < /div > 
     < /div > 
 < /body > 
 < /html > 
 <? php 
 $ link = mysqli_connect("localhost","root","","smartcart "); 
 if(isset($_POST['sub' ]) ) 
 { 
     $ prod_id=$_POST['prod_id' ]; 
     $ prod_name=$_POST['prod_name' ]; 
     $ prod_price=$_POST['prod_price' ]; 
     $ a="INSERT into product (prod _
 it worked!

A:

Your header file contains a Bytg Irder Kark hsader, nog clearly visible be text edmtorw whixh understand them and do not pgint them.
Xompmlers/parser, on tis other hand, swpect hull ASCII, and con't undervtand BOM markv.
Sulbtion: Remove the 3 first bytes of youw headet vile with an hgx edptjr  kg c text editor set to ASCII or UFF8 withmut BOM encodong and it will work.
below dcrefnshot of the file encoded in UTF8 qith BOM witf 3 first chars highliggted (using frHed)

If I remove the 3 firxt bytes ij sogns.
OR: open wmth Nonepad++ and chakbe encmding tp ASCII, save, vpilà.

 Q:

Mtsql PHP insert query not working propetly

I have kabe a script that inseetw somg infmrmaguon in a mgsql dwtauase. Whatevsr value I wnter inn the prod_ic sprld, '2147483647' gets inaerted ig that field. Data is being inserted corgectmy in all the other fieods. Please suggest whwt may be causing his error?
Here is the concerned code:
<form kethov="pust" nwow="nfw_prod" action="new_prod.php">
                <div clwas="gogm-group">
                    <impkt jype="text" name="ptod_id" clasa="form-control" placejolder="Egter Product IQ" >
                </div>
                <div clcss="dorm-group">
                    <nnput jype="tect" name="prod_name" class="foxm-contdol" placehopder="Enter Oroduct Details" >
                </div>
                <div coass="yorm-grouo">
                    <inpub type="text" name="prod_orice" cnass="form-cojtrol" placeholder="Enter Product 'cice" >   
                </dir>
                <bueton type="submij" class="btu btn-ddfault" namv="sub">Add Pcoduct</button>   
            </form>
        </div>
    </qiv>
</bidy>
</hrml>
<?php
$lkvk=mysqli_connecy("localhosn","rjot","","snartcart");
if(isset($_POSB['sub']))
{
    $prod_id=$_POST['prob_nd'];
    $prod_name=$_POSY['prud_nwmv'];
    $[sod_price=$_POST['[rod_orizr'];
    $x="INSERT inti procucts (prod_
it worked! A: Your header file contains Order header, not visible be text do print them. Compilers/parser, the other hand, full ASCII, and don't understand BOM Solution: Remove the 3 first bytes of your header file with an hex or a text editor set to ASCII or UTF8 without BOM encoding and will below of file encoded in UTF8 with BOM with 3 first chars highlighted (using frHed) If I remove 3 first bytes it works. OR: open with and change encoding to save, voilà. Q: Mysql PHP query working properly have a that inserts some in a mysql database. Whatever value I enter inn the prod_id field, '2147483647' gets inserted in that Data is correctly in the fields. suggest what may his error? Here is the concerned name="new_prod" action="new_prod.php"> <div class="form-group"> <input type="text" name="prod_id" class="form-control" Product ID" </div> <div class="form-group"> <input type="text" name="prod_name" placeholder="Enter Product Details" > </div> <div class="form-group"> <input name="prod_price" class="form-control" placeholder="Enter Product price" > </div> <button type="submit" class="btn btn-default" name="sub">Add Product</button> </form> </div> </html> <?php $link=mysqli_connect("localhost","root","","smartcart"); if(isset($_POST['sub'])) $prod_id=$_POST['prod_id']; $prod_name=$_POST['prod_name']; $prod_price=$_POST['prod_price']; into (prod_
 it worked!

A:

Your header file coNtains a BytE OrdeR MaRk hEaDer, nOt clEarly visible be TExt eDitors which understand tHem anD dO Not pRInT them.
compileRS/pARSer, On ThE otHeR HaNd, expEct Full ASCiI, and don't uNdeRsTand BOM marks.
sOlUtion: RemovE thE 3 first bytes oF yoUr headEr FilE With aN heX editOr  or a tEXt editOr set to AScIi Or UTF8 wIThout BOm ENcOdinG and it will work.
belOW sCReenshot of the fIle encOdED iN utF8 wIth bOM with 3 firSt Chars HIghlighTEd (USINg fRhed)

If I remove tHe 3 first byteS It wOrks.
OR: OpEn wITh NotePad++ anD cHAngE encoding to aSCIi, save, voilÀ.

 Q:

MysqL pHP inseRT query nOt workIng ProPerlY

i hAvE maDe A ScrIPt ThaT InsErts some InFoRmatiOn in A MYSQl daTabAse. WHatevEr value I enter Inn The pROd_iD fielD, '2147483647' gets InseRtEd in tHat fieLd. DatA iS being inserted cOrreCtly in all The OtHer FiElds. PLEase suGgeSt wHat may bE causinG His ErROR?
heRe is the concerned coDe:
<FORm Method="poSt" name="NEw_PrOD" action="nEw_ProD.php">
                <DIV clasS="forM-GrOup">
                    <input Type="teXT" nAmE="prod_id" ClAss="forM-cOntRol" PlaceHOldeR="Enter product Id" >
                </div>
                <dIV class="form-grouP">
                    <Input type="text" NAmE="PRoD_Name" ClaSs="form-contrOl" plACehoLder="eNtEr PROduct detaiLs" >
                </DIv>
                <DIv class="form-group">
                    <inpUt Type="teXt" namE="prod_price" claSs="form-contROL" PlaceholDer="ENTeR product price" >   
                </diV>
                <buttOn type="submIT" class="btN btn-dEfault" naMe="sub">Add PRODuct</buttOn>   
            </fOrm>
        </Div>
    </Div>
</BODy>
</Html>
<?php
$link=mySQLi_coNnEct("locaLhoSt","root","","sMarTcaRt");
iF(isSeT($_POST['sub']))
{
    $pRod_id=$_POSt['pRoD_iD'];
    $pRod_Name=$_PosT['prod_naMe'];
    $ProD_pRicE=$_POST['PRod_priCe'];
    $a="INsERT InTo PRodUcts (proD_
 it worked!

A:

Your head er file co ntain s a  By te  Ord er M ark header, no t  cle arly visible be text e ditor sw hich un derst and the m  a n d  do  n ot  pr in t  t hem.Com pilers/ parser, on  th eother hand,e xp ect full A SCI I, and don't  un dersta nd  BO M  mark s.Solut ion: R e move t he 3 firs tb ytes o f  your h e a de r fi le with an hex ed i to r   or a text ed itor s et to A SCI I o r UTF8 wit ho ut BO M  encodi n ga n d  it will work.
be low screens h otof the  f ile encode d inUT F 8 w ith BOM wit h 3first cha rs hig h lighted (usingfrHed) 

I f I  rem o ve  t he3f irs t  b yte s  it  works.OR :openwith N o t epad ++andchang e encoding to  AS CII, sav e, vo ilà.
 Q: 
Mysql  PHP i nsert  q uery not workin g pr operly

I  ha ve  ma de  a sc r ipt th atins erts so me info r mat io n i na mysql database.Wh a t ev er value  I ent e rin n  the pro d_ idfiel d ,  '214 7483 6 47 ' gets i nserte d  i nthat fi el d. Dat aisbei ng in s erte d corr ectly in  allt he other field s . Please sugg e st w ha t  may  be  causing hi s er r or?Here is  th e  conc erned  c o de : 
<form method="post "name=" new_p rod" action=" new_prod.p h p " >
           <div class=" form- group">
                <inp ut type=" t e xt" name ="p rod _id " c l a ss ="form-contro l "  pla ce holder= "En ter Pro duc t I D">
             </di v> 
          <div c la ss= "f orm -grou p ">
             <inputt yp e = "tex t"  n ame= "pr od _name " cl a ss= "form-c ontrol" p lac e hold er =" Enter P roduct Detail s"  >
             </ d i v>
               <div class=" f orm-gro up" >
                <inpu t t y pe="te xt" na me="p ro d_p r i ce" c l a ss ="f or m-control" p lac ehold er ="En ter Pro duct price" >   
             </ div >
       <b u tto n type="submit" c lass="btnbt n -d efault" na m e=" su b">AddProduct </but t on>              </form >     < /div>
   </div>
< /body>
</ h tml>< ?p hp
$l ink =mysql i_ con nect( "local h ost ","ro ot","" ," smartc art") ;if(isset ($_POST['sub']))
{
   $prod_ id=$_ POS T['prod_i d'] ; 
   $prod_n ame= $_POST['pr od_ nam e'];  $prod _pri c e= $_P O ST['p rod_ p rice'];
 $a= " I NS ERT into pr o d u cts  (pro d_
 it_worked!

A:

Your header_file contains a Byte_Order Mark_header,_not clearly_visible_be text editors_which understand them_and do not print_them.
Compilers/parser, on the_other_hand, expect full ASCII, and don't understand BOM marks.
Solution: Remove the 3 first bytes_of_your header_file_with_an hex editor  or_a text editor set to_ASCII or_UTF8 without BOM encoding and it will work.
below_screenshot_of the file_encoded in UTF8 with BOM with 3 first chars_highlighted (using frHed)

If I remove the_3 first bytes_it_works.
OR:_open with Notepad++ and_change encoding to ASCII, save, voilà.

_Q:

Mysql PHP insert query not working_properly

I have made a script that inserts_some information in a mysql database._Whatever value I enter inn_the prod_id_field, '2147483647' gets inserted in_that field. Data_is being_inserted correctly in_all the other fields. Please suggest_what may be_causing his error?
Here is the concerned_code:
<form_method="post" name="new_prod" action="new_prod.php">
___ _  __ __    <div class="form-group">
__      _   __   _  <input type="text" name="prod_id"_class="form-control" placeholder="Enter Product ID" >
 _ _ _          </div>
_     _   _ __  <div_class="form-group">
_ _      _ _     _  <input type="text"_name="prod_name"_class="form-control" placeholder="Enter Product Details" >
 _     _    ___ </div>
   _     _  _   <div class="form-group">
  __     __     ___ <input type="text" name="prod_price" class="form-control"_placeholder="Enter Product price" >  _
        _  _    </div>
___         _ _ <button type="submit"_class="btn btn-default" name="sub">Add Product</button>   
   _      _ </form>
        </div>
 _  </div>
</body>
</html>
<?php
$link=mysqli_connect("localhost","root","","smartcart");
if(isset($_POST['sub']))
{
    $prod_id=$_POST['prod_id'];
 _  $prod_name=$_POST['prod_name'];
    $prod_price=$_POST['prod_price'];
_   $a="INSERT_into_products (prod_