-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpage-dashboard-v1.php
99 lines (68 loc) · 4.01 KB
/
page-dashboard-v1.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
<?php get_header(); ?>
<div id="content">
<div id="inner-content" class="wrap clearfix">
<div id="main" class="twelvecol first clearfix" role="main">
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<article id="post-<?php the_ID(); ?>" <?php post_class('clearfix'); ?> role="article" itemscope itemtype="http://schema.org/BlogPosting">
<header class="article-header">
<h1 class="page-title" itemprop="headline"><?php the_title(); ?></h1>
</header> <!-- end article header -->
<section class="entry-content clearfix" itemprop="articleBody">
<?php the_content(); ?>
<?php if( is_user_logged_in() ) : ?>
<?php $full_name = $current_user->user_firstname . ' ' . get_the_author_meta( 'middlename', $current_user->ID ) . ' ' . $current_user->user_lastname; ?>
<div id="hcard-<?php echo $current_user->user_firstname . '-' . $current_user->user_lastname; ?>" class="vcard clearfix">
<img src="<?php get_gravatar_url( $user_email, 120 ); ?>" alt="<?php echo $full_name; ?>" class="photo" width="120" height="120" />
<div class="account-details">
<a href="<?php echo $user_url; ?>" class="fn url"><?php echo $full_name; ?></a>
<span class="nickname"><?php echo $user_login; ?></span>
<span class="email"><?php echo $user_email; ?></span>
<span class="tel"><?php the_author_meta( 'phonenumber', $current_user->ID ) ?></span>
<span class="title"><?php the_author_meta( 'occupation', $current_user->ID ) ?></span>
<p class="bold">Bio</p>
<p class="bio"><?php echo the_author_meta( 'description', $current_user->ID ) ?></p>
<p class="bold">Interests</p>
<p class="interests">
<?php
$interests = get_the_author_meta( 'interests', $current_user->ID );
echo $interests;
?>
</p>
</div>
<a href="<?php echo admin_url( 'profile.php' ); ?>">Edit Profile</a>
</div>
<div class="interests-loop">
<h2>Entrepreneurial Endeavors that May Interest You</h2>
<?php $interests_array = explode( ', ', $interests ); ?>
<?php $interests_loop = new WP_Query( array( 'post_type' => 'project', 'tag' => $interests ) ); ?>
<?php if( $interests_loop->have_posts() ) : while( $interests_loop->have_posts() ) : $interests_loop->the_post() ?>
<h3><a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><?php the_title(); ?></a></h3>
<?php endwhile; else : ?>
Sorry, there's just <strong>nothing</strong> here that'll interest you.
<?php endif; ?>
<?php wp_reset_postdata(); ?>
</div>
<?php else : ?>
<p>You didn't create an account yet? There are monkeys starving in Atlanta. <a href="<?php echo home_url( '/' ) ?>wp-register.php">Hop to it!</a></p>
<?php endif; ?>
</section> <!-- end article section -->
<footer class="article-footer">
</footer> <!-- end article footer -->
</article> <!-- end article -->
<?php endwhile; else : ?>
<article id="post-not-found" class="hentry clearfix">
<header class="article-header">
<h1><?php _e("Oops, Post Not Found!", "bonestheme"); ?></h1>
</header>
<section class="entry-content">
<p><?php _e("Uh Oh. Something is missing. Try double checking things.", "bonestheme"); ?></p>
</section>
<footer class="article-footer">
<p><?php _e("This is the error message in the page.php template.", "bonestheme"); ?></p>
</footer>
</article>
<?php endif; ?>
</div> <!-- end #main -->
</div> <!-- end #inner-content -->
</div> <!-- end #content -->
<?php get_footer(); ?>