The following warnings occurred:
Warning [2] Undefined variable $unreadreports - Line: 26 - File: global.php(961) : eval()'d code PHP 8.2.25 (Linux)
File Line Function
/global.php(961) : eval()'d code 26 errorHandler->error
/global.php 961 eval
/showthread.php 28 require_once





× This forum is read only. As of July 23, 2019, the UserSpice forums have been closed. To receive support, please join our Discord by clicking here. Thank you!

  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Upload with link
#11
This is an image file you want to insert into the database? For that, I seem to recall about 10 years ago I did something to insert thumbnails into a DB rather than having them in the filesystem. I think you need to use some binary read functions or something like that.

I'm going to be doing some file upload stuff soon, so I could help you with that once I get there.
  Reply
#12
I need it to upload a CV and create a link for that users ID so it can be downloaded by the staff for that user.

I'm making an address book
http://prntscr.com/citu8y

I just cant work out how to do it, I used that link and it will upload to it's own database and upload the file but I cant get it to add it to users.
  Reply
#13
Sorry for the slow response.

It is perfectly fine to have the upload go to a different database table, but the key is to assign the uploader's user id to that upload. So make another column in the table and call it user_id.

Then when uploading the file, make sure that you send $user->data()->id to the user_id folder.

If you want from there you can have it check to see if there is already an upload with that user id in the table and delete it before uploading a new one.
  Reply
#14
hre is example what i have. upload images: cv/year/month/day/user_id/cv.file + upload info to DB

https://gist.github.com/artpicassoo/3c9d...7090304045
  Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)