Skip to main content

HDInnovations/UNIT3D-Community-Edition

2255 stars
2 code files
View HDInnovations/UNIT3D-Community-Edition on GitHub

app/Helpers/Helpers.php

Open in GitHub
//
if (! function_exists('href_profile')) {
function href_profile($user)
{
$appurl = appurl();
 
return sprintf('%s/users/%s', $appurl, $user->username);
}
}
//

app/Http/Controllers/CommentController.php

Open in GitHub
use App\Models\Collection;
 
class CommentController extends Controller
{
//
public function collection(Request $request, $id)
{
$collection = Collection::findOrFail($id);
$user = \auth()->user();
//
$profileUrl = \href_profile($user);
//
}
//
}

We'd Love Your Feedback

Tell us what you like or what we can improve

Feel free to share anything you like or dislike about this page or the platform in general.