{"id":596,"date":"2010-03-24T21:36:19","date_gmt":"2010-03-25T03:36:19","guid":{"rendered":"http:\/\/www.evolutionarydesigns.net\/blog\/2010\/03\/24\/how-add-author-bio-to-wordpress-without-a-plugin\/"},"modified":"2010-12-03T10:29:39","modified_gmt":"2010-12-03T16:29:39","slug":"how-add-author-bio-to-wordpress-without-a-plugin","status":"publish","type":"post","link":"http:\/\/www.evolutionarydesigns.net\/blog\/2010\/03\/24\/how-add-author-bio-to-wordpress-without-a-plugin\/","title":{"rendered":"How to Add Author Bio to WordPress Without a Plugin"},"content":{"rendered":"<p><a href=\"https:\/\/i0.wp.com\/www.evolutionarydesigns.net\/blog\/wp-content\/uploads\/5b4e0cfc9824_2B0F\/wordpresslogo2300x282.png\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" style=\"margin: 0px 10px 0px 0px; display: inline; border-width: 0px;\" title=\"WordPress.org\" src=\"https:\/\/i0.wp.com\/www.evolutionarydesigns.net\/blog\/wp-content\/uploads\/5b4e0cfc9824_2B0F\/wordpresslogo2300x282_thumb.png?resize=200%2C200\" border=\"0\" alt=\"WordPress.org\" width=\"200\" height=\"200\" align=\"left\" \/><\/a> If you been reading my blog over the last month you may have noticed some design changes on my post pages. Today I wanted to tell you about one of those changes. That change is the author bio box at the end of the content of the post. I added the box to give a little info about the author and links to their sites.<em> <\/em>I installed this feature for anyone who wants to <a href=\"http:\/\/www.evolutionarydesigns.net\/blog\/write-for-us\/\" target=\"_blank\">guest post<\/a> for us.<\/p>\n<h3>So How Do I add an Author Bio Box to WordPress?<\/h3>\n<p>There are several different ways to add an author bio box to <a href=\"http:\/\/www.wordpress.org\/\" target=\"_blank\">WordPress<\/a>, The two easiest ways is through a plugin and manually adding the code to single.php and to the <a href=\"http:\/\/www.w3.org\/Style\/\" target=\"_blank\">style sheet<\/a>. Both options have their pros and cons.<\/p>\n<p>Using the plugin is the easiest way but you are limited to the authors design and their design may interfere with your website&#8217;s theme. I tried several different plugins but each one had issues with my theme.<\/p>\n<p>When added the code to your site manually there are pros and cons as well. With manually adding the code to, you need some basic <a class=\"zem_slink\" title=\"PHP\" rel=\"homepage\" href=\"http:\/\/www.php.net\/\">PHP<\/a>, CSS, and HTML skills to add the code. You need code, you can find it through research, create the code yourself or have someone create the code for you. You will need to change the CSS for the author box to match your site. It could take some time to perfect this. But in the end, you will have your own code, that is custom to your site, if it is coded correctly then it will run smoothly and your new bio box has been designed around your site so it looks like it suppose to be there and not an after thought.<\/p>\n<p>After testing the different plugins, I decided that since I was trying to remove as many plugins as can I and use my own code, I figured this would be the best opportunity to add my own code. So I started the research. After several days of research and testing I asked for some help from <a href=\"http:\/\/www.famousbloggers.net\/\" target=\"_blank\">Hisham from Famous Bloggers<\/a> for some coding help.<\/p>\n<p>Once he looked into the code we came to the conclusion that we needed needed to add some code to the single.php code to pull the author bio box and some <a href=\"http:\/\/www.w3.org\/Style\/CSS\/\" target=\"_blank\">CSS<\/a> to style the bio box to fit and to match my theme without issues.<\/p>\n<p>Once you have the code, its relatively easy to add the code your WordPress driven site. The first thing you want to do is back up your single.php and your style sheet. If you do not have access to backing up your work, then just copy paste each page into separate text documents and save them so you know what you have. Once everything is backed up then you can start the process of adding the bio box to your site.<\/p>\n<p>Inside your WordPress Dashboard, go to the Appearance section and click on editor. After the editor opens, look for and click on the single.php file and open it up.<\/p>\n<p>Next you will need to copy the code to the end of the post code files. You will need to change the link to your site. You can also change the wording here as well.<\/p>\n<blockquote style=\"width: 621px; height: 186px;\"><p>&lt;div class=&#8221;postauthor&#8221;&gt;<br \/>\n&lt;?php echo get_avatar( get_the_author_id() , 100 ); ?&gt;<br \/>\n&lt;h3&gt;Article by &lt;a href=&#8221;&lt;?php the_author_url(); ?&gt;&#8221;&gt;<br \/>\n&lt;?php the_author_firstname(); ?&gt; &lt;?php the_author_lastname(); ?&gt;&lt;\/a&gt;&lt;\/h3&gt;<br \/>\n&lt;p&gt;&lt;?php the_author_description(); ?&gt;&lt;\/p&gt;<br \/>\n&lt;p class=&#8221;hlight&#8221;&gt;&lt;?php the_author_firstname(); ?&gt; has written &lt;span&gt;&lt;?php the_author_posts(); ?&gt;&lt;\/span&gt; awesome articles for us at &lt;a href=&#8221;<a href=\"http:\/\/www.evolutionarydesigns.net\/blog%22\">http:\/\/www.evolutionarydesigns.net\/blog&#8221;<\/a>&gt;Evolutionary Designs&lt;\/a&gt;&lt;\/p&gt;<br \/>\n&lt;\/div&gt;<\/p><\/blockquote>\n<p>The code below is what you may find at the end of the code to post content at the bottom of the code you will see <!--\/post-->, put past the code here. If you do not have this feature let me know, and I can take a look at your code see where to add the code to make it work. You may also have some other custom code added such as <a class=\"zem_slink\" title=\"Facebook\" rel=\"homepage\" href=\"http:\/\/facebook.com\">Facebook<\/a> fan pages or bookmarking code their, you can either add it above it or below it.<\/p>\n<blockquote style=\"width: 616px; height: 611px;\"><p>&lt;div class=&#8221;details&lt;?php if($share):?&gt; share&lt;?php endif; ?&gt;&#8221;<br \/>\n&lt;?php<br \/>\nprintf(__(&#8216;This entry was posted by %1$s on %2$s at %3$s, and is filled under %4$s. Follow any responses to this post through %5$s.&#8217;, &#8216;mystique&#8217;), &#8216;&lt;a href=&#8221;&#8216;. get_author_posts_url(get_the_author_ID()) .'&#8221; title=&#8221;&#8216;. sprintf(__(&#8220;Posts by %s&#8221;,&#8221;mystique&#8221;), attribute_escape(get_the_author())).&#8217; &#8220;&gt;&#8217;. get_the_author() .'&lt;\/a&gt;&#8217;, get_the_time(get_option(&#8216;date_format&#8217;)),get_the_time(get_option(&#8216;time_format&#8217;)), get_the_category_list(&#8216;, &#8216;), &#8216;&lt;a href=&#8221;&#8216;.get_post_comments_feed_link($post-&gt;ID).'&#8221; title=&#8221;RSS 2.0&#8243;&gt;RSS 2.0&lt;\/a&gt;&#8217;);echo &#8216; &#8216;;<\/p>\n<p>if ((&#8216;open&#8217; == $post-&gt; comment_status) &amp;&amp; (&#8216;open&#8217; == $post-&gt;ping_status)):<br \/>\n\/\/ Both Comments and Pings are open<br \/>\nprintf(__(&#8216;You can &lt;a%1$s&gt;leave a response&lt;\/a&gt; or &lt;a%2$s&gt;trackback&lt;\/a&gt; from your own site.&#8217;, &#8216;mystique&#8217;), &#8216; href=&#8221;#respond&#8221;&#8216;,&#8217; href=&#8221;&#8216;.trackback_url(&#8221;,false).'&#8221; rel=&#8221;trackback&#8221;&#8216;);<\/p>\n<p>elseif (!(&#8216;open&#8217; == $post-&gt; comment_status) &amp;&amp; (&#8216;open&#8217; == $post-&gt;ping_status)):<br \/>\n\/\/ Only Pings are Open<br \/>\nprintf(__(&#8216;Responses are currently closed, but you can &lt;a%1$s&gt;trackback&lt;\/a&gt; from your own site.&#8217;, &#8216;mystique&#8217;), &#8216; href=&#8221;&#8216;.trackback_url(&#8221;,false).'&#8221; rel=&#8221;trackback&#8221;&#8216;);<\/p>\n<p>elseif ((&#8216;open&#8217; == $post-&gt; comment_status) &amp;&amp; !(&#8216;open&#8217; == $post-&gt;ping_status)):<br \/>\n\/\/ Comments are open, Pings are not<br \/>\n_e(&#8216;You can skip to the end and leave a response. Pinging is currently not allowed.&#8217;,&#8217;mystique&#8217;);<\/p>\n<p>elseif (!(&#8216;open&#8217; == $post-&gt; comment_status) &amp;&amp; !(&#8216;open&#8217; == $post-&gt;ping_status)):<br \/>\n\/\/ Neither Comments, nor Pings are open<br \/>\n_e(&#8216;Both comments and pings are currently closed.&#8217;,&#8217;mystique&#8217;);<br \/>\nendif; ?&gt;<br \/>\n&lt;?php edit_post_link(__(&#8216;Edit this entry&#8217;, &#8216;mystique&#8217;)); ?&gt;<br \/>\n&lt;\/div&gt;<br \/>\n&lt;\/div&gt;<br \/>\n&lt;\/div&gt;<br \/>\n&lt;!&#8211; \/post &#8211;&gt;<\/p><\/blockquote>\n<p>Once you have added and modified the code as needed, Save it and open the Style.css file. After opening the file, go to the bottom of the code and copy the follow code to the style sheet.<\/p>\n<blockquote style=\"width: 618px; height: 176px;\"><p>}<br \/>\n.postauthor { background: #F5F5F5; width:650px; border-top: 1px solid #e1e1e0; border-bottom: 1px solid #e1e1e0; overflow: hidden; padding: 10px; }<br \/>\n.postauthor img { border: 5px solid #e2dede; float: left; margin-right: 1.5em; }<br \/>\n.postauthor h4 { color: #666; font-size: 2em; margin-bottom: 5px; }<br \/>\n.postauthor p { color: #515151; font-size: 13px; margin-bottom: 12px; text-align:justify;}<br \/>\n.postauthor p.hlight { font-size: 11px; text-transform: uppercase; }<br \/>\n.postauthor p.hlight span { color: #CB3131; font-size: 13px; font-style: italic; font-weight: bold; letter-spacing: 0.8px; }<\/p><\/blockquote>\n<p>When finished save it and preview your work. If it pulls the correct text then then you are finished with the single.php file but if your bio box does not match with your theme or the box is to big or to small for the column, then you will need to edit the style sheet.<\/p>\n<p>After you get your bio box styled correctly you will need to go to the user tab and update the user information. You will need to have all if your users update their profiles and add a bio to their profile. The field that needs to be updated should look like the picture below.<\/p>\n<p><a href=\"https:\/\/i0.wp.com\/www.evolutionarydesigns.net\/blog\/wp-content\/uploads\/5b4e0cfc9824_2B0F\/authorbiobox.jpg\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" style=\"display: block; float: none; margin-left: auto; margin-right: auto; border-width: 0px;\" title=\"Filling WordPress User Bio Box\" src=\"https:\/\/i0.wp.com\/www.evolutionarydesigns.net\/blog\/wp-content\/uploads\/5b4e0cfc9824_2B0F\/authorbiobox_thumb.jpg?resize=665%2C150\" border=\"0\" alt=\"Filling WordPress User Bio Box\" width=\"665\" height=\"150\" \/><\/a><\/p>\n<p>When you have completed your bio and tested, you are finished. Do you have an avatar in your bio box? You can have one, the code will call for your avatar if you are registered with <a href=\"http:\/\/en.gravatar.com\/\" target=\"_blank\">Gravatar<\/a>. Just head over to their site and register for one. Anyone that uses <strong>Gravatar<\/strong> on their site, will give you an easy way to add your avatar to their site.<\/p>\n<h3>Conclusion<\/h3>\n<p>After installing and modifying the code as needed, I found that it was actually simple to set this up, but it does take some time. If you have no issues, it should take about ten or fifteen minutes. If you have issues with the styling it could take a little a longer if you have to figure out what you need to match the box to your site. For my site my only real issue was getting the comment box to line up with the other boxes around it. It took me about an hour to get it lined up the way I wanted it.<\/p>\n<p><input id=\"gwProxy\" type=\"hidden\" \/><\/p>\n<p><!--Session data--><\/p>\n<p><input id=\"jsProxy\" onclick=\"jsCall();\" type=\"hidden\" \/><\/p>\n<div class=\"zemanta-pixie\" style=\"margin-top: 10px; height: 15px;\"><img data-recalc-dims=\"1\" decoding=\"async\" class=\"zemanta-pixie-img\" style=\"float: right; border-style: none;\" src=\"https:\/\/i0.wp.com\/img.zemanta.com\/pixy.gif\" alt=\"\" \/><\/div>\n","protected":false},"excerpt":{"rendered":"<p>If you been reading my blog over the last month you may have noticed some design changes on my post pages. Today I wanted to tell you about one of those changes. That change is the author bio box at the end of the content of the post. I added the box to give a [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[14],"tags":[356,290,296,357,132,1481],"class_list":["post-596","post","type-post","status-publish","format-standard","hentry","category-tutorials","tag-author-bio-box","tag-cascading-style-sheets","tag-famous-bloggers","tag-how-to-manually-author-bio-box-to-wordpress","tag-php","tag-wordpress","entry"],"aioseo_notices":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/pJPdG-9C","jetpack_sharing_enabled":true,"jetpack-related-posts":[],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/posts\/596","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/comments?post=596"}],"version-history":[{"count":0,"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/posts\/596\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/media?parent=596"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/categories?post=596"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.evolutionarydesigns.net\/blog\/wp-json\/wp\/v2\/tags?post=596"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}