Server scripting: Difference between revisions

From SoftwareGuy
Jump to navigation Jump to search
Mark (talk | contribs)
No edit summary
Mark (talk | contribs)
Line 6: Line 6:
  $fcontents = file_get_contents('php://input') . " - " . $direction;
  $fcontents = file_get_contents('php://input') . " - " . $direction;
  file_put_contents('php.log', $fcontents, FILE_APPEND);
  file_put_contents('php.log', $fcontents, FILE_APPEND);
?>
simple server side with image saving
<?php
$direction = $_GET['direction'];
#$fcontents = file_get_contents('php://input') . " - " . $direction;
$fcontents = file_get_contents('php://input');
file_put_contents('php_image.log', $fcontents);
  ?>
  ?>

Revision as of 16:39, 1 May 2024

php

simple php example of server side message (from camera) with argument(s)

<?php
$direction = $_GET['Message'];
$fcontents = file_get_contents('php://input') . " - " . $direction;
file_put_contents('php.log', $fcontents, FILE_APPEND);
?>

simple server side with image saving

<?php
$direction = $_GET['direction'];

#$fcontents = file_get_contents('php://input') . " - " . $direction;
$fcontents = file_get_contents('php://input');
file_put_contents('php_image.log', $fcontents);

?>