Cakephp after register auto log in - cakephp-2.0

How to auto log in after I register? Im using this code, after I Save the data
$this->UserAuth->login($user);
$this->redirect('/');
but this is not working

Related

My Kibana instance randomly will take long times to load data on Kibana index

I am using json script to fetch Okta users data and save in .json files by cronjob till this process working fine.
After this try to load json files data into Kibana index to create visualizations using config files, Starting point data loading working fine randomly after certain period of time loading process getting very slow.
on basis of my observation only 3k to 4k data loaded daily means in 24 hr. .
can anyone please suggest any solution on this ?

Android app not saving in the database with Url

I have this code for saving some content into an Azure Database, the fields that i have are
Name(string), Lastname(string), Date of birth(DateTime), Illnes(string), Email(string), Phone(int)
but when I try to save it it's basically not working, is throwing me the "Couldn't save data" message that I typed in a validation, idk if im doing something wrong
This is the code to send the information to the database

Send cluster or array of data generated by a machine programmed in LabVIEW, to Firebase

I've already tried to connect LabVIEW to Firebase, and it needs a json file. I added a knob to control the input and meter as an output. When I change the knob, let's say, to 5 for example, the meter also changes to 5.
Now the machine code is actually made, and it gives an array for the results of tests, and I want to send that array to Firebase.
How can I accomplish this?
you can use the api rest to your real time database in firebase
api rest Firebase
then your labview code can use http post and http get to save and retrieve data.
the url have the following sintax
https://proyectID.firebaseio.com/Datacollection/somename.json
the somename.json does not mean a file, just mean the tag to be saved in your database, to encode any labview data use the function "Flatten to Json"
sample code

Email does not send in Laravel API after writing to database

I have an AngularJS 1.5 application which is working with a Laravel 5.2 API and I'm trying to send emails at different points in the application. So I'm able to send data to Laravel and it gets recorded in the tables I specify but when it gets to sending a confirmation email it gives me this error with an HTTP status code of 500: MethodNotAllowedHttpException
Odd thing is, it works perfectly fine in local development on my laptop. But the same functions on the AWS EC2 instance and it fails when it gets to sending any email. I'm using SendGrid to manage sending emails but I don't think I need to change any settings for that.
For Example:
$emailUser = array();
$emailUser['email'] = $request->email;
$emailUser['first_name'] = $request->first_name;
$emailUser['last_name'] = $request->last_name;
$emailUser['randomStr'] = str_random(36);
$emailUser['remove_dtm'] = Carbon::now()->addWeeks(2);
//Add a password reset set to 2 weeks out for the user to register
DB::table('password_resets')->insert([
'email' => $emailUser['email'],
'token' => $emailUser['randomStr'],
'remove_dtm' => $emailUser['remove_dtm']
]);
Mail::send('email.registered_user', $emailUser, function($message) use ($emailUser)
{ $message->to($emailUser['email'], $emailUser['first_name'] . ' ' . $emailUser['last_name']);
$message->from('WSCUSTOMERPO#waterstoneco.com', 'Waterstone Faucets');
$message->replyTo('WSCUSTOMERPO#waterstoneco.com', 'Waterstone Faucets');
$message->subject("Welcome to the Waterstone Faucets Portal!");
});
When I try to reset a user's password it will create the record in the password_reset table but not send the email on the live site. Again the same function works fine on my laptop. I checked that I'm posting on the Angular side and Laravel API is expecting a post HTTP call when running this function.
What am I missing here?
Thank you greatly for your help!
There are a few things to check here,
1: Are you sure you have your .env file set up to use the correct SMTP server settings to use SendGrid. If you forgot to set this up in your .env you will be using the internal mail function. Instead of using SendGrid, I would suggest keeping it inside of Amazon for more reliability. Switching over to Amazon SES may be a great option for you.
2: If you are using the internal mail system, there is a really good article about mail from Amazon EC2 instances here: http://shlomoswidler.com/2009/07/sending-email-from-ec2.html
Just a reminder for number 1 for others that may have come here looking for help. To set your mail service in Laravel to use an smtp service, open your config/mail.php file and set the driver to use your provider (if provided by laravel). This can be done by edit the file directly or setting the environment variable MAIL_DRIVER in your .env file.

How to send variable values to email/external file

I'm not an Expert in Flash... So, I want to do a Register Page, and get the variable values. I want to send variables to a external file or to my email.
I've got 2 Input Text Components with this Instance Names:
name
password
If your application is running in the Flash player you'll need a server-side script to send data via email or to save it to a file on the server. There are loads of tutorials out there to help you out with this, but here are a couple I found which look useful:
Contact form with ActionScript 3.0 and PHP
Saving data to a text file with ActionScript 3.0 and PHP

Resources