When you create a worker application or any large application in Laravel you might want to keep track of logs. It might be necessary to save logs to different files to keep things clean. But by default the Laravel Log System doesn’t provide this feature. We can save to different files based on date, butcontinue reading
php Archives
Drupal Save Profile Image Programmatically
When we use the Profile 2 module and need to save the profile image field (existing), we can use profile2 functions and achieve the task. Note down the Field needs to be updated. Load the profile. Add Image field to the loaded profile object Save the profile. function save_image_profile2($profile_id, $image_id){ // Load the profile objectcontinue reading
PHP Delete multiple files if name contains..
I wanted to delete thousands of thumbnails mixed with original images using php. There were no easy solutions available in Windows without extra tools. (Dint want command solution either) Here is the script i used to delete multiple files with names containing “word” in them. Note: We need a php server to run this script.