I have this code:
if(count($vid_files)>0){
$videoNames = array_keys($vid_files);
$videoName = basename($videoNames[0]);
$this->videourl = $videoName;
I would like to add a url at the beginning after the result of basename , resulting from it is 100392video.mp4 I wanted the url to stay ahead, / p>
$this->videourl = "url" + $videoName;
But when I do this, it comes out just the numbers.
100392
And there is no url or the ending that is .mp4 .
In response to Isac;
public function add($f3, $id, $name, $userid, $category, $vid_files){
//add or edit to db
if($id>=0){
$this->load(array('id = ?',$id));
}
$this->userid = $userid;
$this->name = $name;
$this->category = $category;
if(count($vid_files)>0){
$videoNames = array_keys($vid_files);
$videoName = basename($videoNames[0]);
$this->videourl = $videoName;
}
$this->save();
}