url upload with mysql db update

Started on the old forum in November 2020 · view the original in the archive · old links redirect here

2 replies · 59 views · started 6 years ago · 1 min read

2 participants
ayesham Developer · 69 posts #1

Need To know how to Url file(mp3) upload with mysql update filepath, size, file title to a DB?? anyone can help me on this is much appreciated. i do have db as

id (auto increment) 'filepath' 'song_title' 'size' 'artist' 'coverphoto' 'lyrics' 'music' 'date'

getid3 file path =.. system/getid3/getid3.php

something else Fellow · 2,296 posts #2

To grab a file via url:

$url = 'http://example.con/song.mp3';
$saveAs = '/someFolderName/'.basename($url);
$gotMp3 = file_put_contents($saveAs, file_get_contents($url));
if($gotMp3)
{
// get size, artist etc using getid3 from $saveAs here
}

Note: above script has no security ^

ayesham Developer · 69 posts #3

🤨 hmmm lets see.... tnx bro

Write your reply now; next you create a free account (or sign in) and it is posted right away. Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close