@calvincani You can just have an images or profile_images table where you store the image paths, and also a foreign key pointing to the profile ID the image belongs to. Then showing random images is just a case of pulling random rows from the table.
Link pictures in a database table to a user profile
I'm busy building this app that will allow users to upload pictures they have taken, to their profile. Like a gallery for their profile. so multiple images on one profile. The problem is I need these pictures to be in their own table so I can have the website display all the pictures in that table randomly on the site. So first off how do I allow a person to upload multiple pictures to their profile? Oh and a profile is separate from the user account. every user account can only have one profile, but one profile can have many pictures uploaded by the profile owner? I am fairly new to Laravel and PHP so any help will be greatly appreciated. Thank you in advance.
Please or to participate in this conversation.