<?php

namespace App\Http\Controllers;
use View, DB;
use App\Media;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use Illuminate\Support\Facades\Input;
use Illuminate\Support\Facades\Redirect;
use Illuminate\Support\Facades\Validator;
use Illuminate\Routing\Controller as BaseController;

class TagsController extends BaseController {

	public function tags(Request $request, $tagname){
		$tags 	= Media::where('tags', 'LIKE', '%'.$tagname.'%')->get();
		return view("media.media_tags", ['tags'=>$tags, 'tagname'=>$tagname]);
	}
}