Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation
This project
Loading...
Sign in
hfpp2012
/
laravel-blog
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit c6149eda
authored
Sep 08, 2017
by
hfpp2012 yinsigan
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Social Network Profile Design
1 parent
0a2f489e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
2 deletions
app/Http/Controllers/ProfileController.php
resources/views/user/profile.blade.php
app/Http/Controllers/ProfileController.php
View file @
c6149ed
...
...
@@ -13,7 +13,8 @@ class ProfileController extends Controller
$user
=
User
::
whereUsername
(
$username
)
->
first
();
// $user = User::where('username', $username)->first();
// $user = User::where('username', '=', $username)->first();
return
$user
;
dd
(
$user
);
// return $user;
// dd($user);
return
view
(
'user.profile'
,
compact
(
'user'
));
}
}
resources/views/user/profile.blade.php
0 → 100644
View file @
c6149ed
@extends('layouts.app')
@section('content')
<div
class=
"row"
>
<div
class=
"col-md-6 col-md-offset-3"
>
<div
class=
"panel panel-default"
>
<div
class=
"panel-body text-center"
>
<img
src=
"https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQe8W2ur7n_tTz1jE--CSLNEiDmN56hMyqIw-k-Z5Xt4AN34SZP"
alt=
""
>
<h1>
{{ $user->name }}
</h1>
<h5>
{{ $user->email }}
</h5>
<h5>
{{ $user->dob }}
</h5>
</div>
</div>
</div>
</div>
@endsection
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment