[PHP] - Revive Script - (HELP)

I am writing a revive tool for a website supporting TrinityCore, but can’t figure out what to update in the Character db to revive the character… I have tried everything…

mysql_query("UPDATE $db.trinity_characters SET ?='' AND ?='' WHERE guid='$guid_id' AND account='$account_id'");

So what would I set to revive the player?

[CODE] $query_select = “SELECT map, zone, position_x, position_y, position_z FROM character_homebind WHERE guid = '”.$char_array_acc[‘guid’].“’ LIMIT 1”;

	$query_result = mysql_query($query_select) or die(mysql_error());

	$query_array = mysql_fetch_array($query_result);


	//echo $query_select;


 $final = "UPDATE characters SET  drunk = 0, playerFlags = playerFlags & ~ 16, position_x = '".$query_array['position_x']."', position_y = '".$query_array['position_y']."', position_z = '".$query_array['position_z']."', zone = '".$query_array['zone']."', map = '".$query_array['map']."' WHERE account = '".$_SESSION['id']."' AND guid = '".$char_array_acc['guid']."'

   LIMIT 1";

 $query_final = mysql_query($final) or die(mysql_error());

 $aura_query = "DELETE FROM character_aura WHERE guid = ".$char_array_acc['guid']."";

 mysql_query($aura_query) or die (mysql_error());[/CODE]

note

[CODE]playerFlags = playerFlags & ~ 16,

&

$aura_query = “DELETE FROM character_aura WHERE guid = “.$char_array_acc[‘guid’].””;[/CODE]

piece of my unstuck script, hope this helps

please add full php script

Nice worked like a charm.

Glad it worked ya, lemme know if you some other help.

My topic on trinity mail system, not sure if you know how to use it… anyways Topic Here.

Sundrowner, wrong section