Hello i am trying to put a value into a field on a table in my database. The value changes accordingly so the type of the column is ENUM ('P','A','T') but everything i do the value tha is been inserted is 'P'.
this is the html
<input type="hidden" id="type" name="type" value="A">
the javascript
$("body").on('click','#updateButton',function()
{
var type=$("#type").val();
updateNewsFeed(uid, update,Z,groupID,token,pic,lat,lang,baseUrl,apiBaseUrl,type);
}
function updateNewsFeed(uid, update,uploads,group_id,token,pic,lat,lang,baseUrl,apiBaseUrl,type)
{
$("#newsFeed").fadeIn();
var embed='';
var encodedata=JSON.stringify({"uid": uid,"update": update,"group_id": group_id,"uploads": uploads,"token": token,"lat": lat,"lang": lang,"type": type});
var url=apiBaseUrl+'api/updateNewsFeed';
}
i dont thing its a php thing because the values that is always inserted is 'P'