Skip to content

Instantly share code, notes, and snippets.

@uneak
Created December 8, 2017 14:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save uneak/f7063e9910a837634132fa9b3451fc4c to your computer and use it in GitHub Desktop.
Save uneak/f7063e9910a837634132fa9b3451fc4c to your computer and use it in GitHub Desktop.
<?php
public function campaignSmsAction(Request $request) {
$all = $request->query->all();
$log = serialize($all);
$dir = '/home/happysmsfr/www/process';
if (isset($all['tag'])) {
$slugify = new Slugify();
$file = $slugify->slugify($all['tag']).".process";
} else {
$file = "message.error";
}
$output = $dir . "/" . $file;
file_put_contents($output, $log.PHP_EOL , FILE_APPEND | LOCK_UN);
return new Response("add to ".$output);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment