Skip to content
Advertisement

Determine if a property value is a blank string

So I have the following foreach inside my method as shown below:

JavaScript

So 'azure_picture' => Azure::init()->set_blob_sas_url($profile->get_employee_id()), will return a string '' if the value is empty..

Is there a way that I can determine if azure_picture is an empty string, to pass in a empty string in 'azure_picture_expiration' => $profile->set_azure_picture_expiration(strtotime('+7 days')),..

So instead of passing strtotime('+7 days') automatically, I’d like to pass in an empty string if the azure_picture is empty, otherwise, use strtotime('+7 days').

All help would be appreciated!

Advertisement

Answer

JavaScript

Is this what you mean?

User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement