{"id":2868,"date":"2013-09-14T15:38:49","date_gmt":"2013-09-14T20:38:49","guid":{"rendered":"http:\/\/rockylouproductions.com\/blog_wp\/?p=2868"},"modified":"2013-09-14T15:40:45","modified_gmt":"2013-09-14T20:40:45","slug":"html-borders","status":"publish","type":"post","link":"https:\/\/rockylouproductions.com\/blog_wp\/2013\/09\/14\/html-borders\/","title":{"rendered":"Tiptoeing thru HTML to Make Borders"},"content":{"rendered":"<p>Thanks to a recent post by John Johnston <a href=\"http:\/\/johnjohnston.info\/106\/flicking-a-five-card-story\/\">&#8220;Flicking a Five Card Story&#8221; <\/a>\u00a0I brushed aside my anxiety, took the leap and dived into the HTML.\u00a0Well, let\u2019s be real\u2026 I just dipped my toes in the shallow end\u2026 but I did it. I created borders around all of my images in my 5 Card Flickr Story post, \u00a0<a href=\"http:\/\/wp.me\/p3zfrO-JF\">5 Card Poetry &#8211; Sharing My Story<\/a>\u00a0YAY!!!!!!!<\/p>\n<p>I&#8217;d been wanting to do this since my first WordPress based blog post. \u00a0It was very easy to do when I was programming my websites using RapidWeaver. \u00a0I just clicked on a picture formatting box, chose my style, \u00a0and it was all done for me. \u00a0That hasn&#8217;t been the case with this blog. \u00a0Maybe I just haven&#8217;t located the right WordPress widgets and plug-ins yet. \u00a0But I agree with John (and Alan Levine) that it is good to know how to work directly with the code. \u00a0What was it Alan said? &#8220;Code or Be Coded&#8221;.\u00a0Let me show you what I did. \u00a0And then you can give it a try too.<\/p>\n<p>I wanted to take this image I had taken in February 2010 outside a small cafe in Salisbury England, and give it a border and a shadow to produce a more finished 3D look.<\/p>\n<p><a href=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg\"><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"2841\" data-permalink=\"https:\/\/rockylouproductions.com\/blog_wp\/2013\/09\/14\/five-card-poetry-my-story\/englandrainchair\/\" data-orig-file=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?fit=3264%2C2448&amp;ssl=1\" data-orig-size=\"3264,2448\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;5&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;Canon PowerShot SX20 IS&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1267002694&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;54.877&quot;,&quot;iso&quot;:&quot;400&quot;,&quot;shutter_speed&quot;:&quot;0.0666666666667&quot;,&quot;title&quot;:&quot;&quot;}\" data-image-title=\"EnglandRainChair\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?fit=625%2C469&amp;ssl=1\" loading=\"lazy\" class=\"size-medium wp-image-2841 alignnone\" alt=\"EnglandRainChair\" src=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=300%2C225\" width=\"300\" height=\"225\" srcset=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=1024%2C768&amp;ssl=1 1024w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=624%2C467&amp;ssl=1 624w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?w=1250 1250w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?w=1875 1875w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>By opening the text editor tab, I located the code that inserts this image into my post.<\/p>\n<p><span style=\"color: #888888;\">&lt;a href=&#8221;http:\/\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg&#8221;&gt;<\/span><strong>&lt;img<\/strong> <span style=\"color: #800000;\"><span style=\"color: #339966;\">c<em>lass=&#8221;size-medium wp-image-2841 alignnone&#8221; alt=&#8221;EnglandRainChair&#8221;<\/em><\/span><\/span> <span style=\"color: #888888;\"><span style=\"color: #000000;\"><strong>src<\/strong><\/span>=&#8221;http:\/\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair-300&#215;225.jpg&#8221; width=&#8221;300&#8243; height=&#8221;225&#8243; \/&gt;&lt;\/a&gt;<\/span><\/p>\n<p>What I needed to do was to add an extra bit of HTML code to add some\u00a0<span style=\"color: #ff0000;\">STYLE<\/span> to the image. I found a quick tutorial on-line on how to create borders around stuff at:\u00a0\u00a0<a href=\"http:\/\/wpbtips.wordpress.com\/2009\/10\/14\/borders-pt-1\/\">http:\/\/wpbtips.wordpress.com\/2009\/10\/14\/borders-pt-1\/<\/a><\/p>\n<p>For a border around an image, you insert a style definition between the <strong>img<\/strong> and the <strong>src<\/strong> tags of the image code:\u00a0<em>&lt;<strong>img<\/strong> <span style=\"color: #ff0000;\">style=&#8221;border:1px TYPE #HEX;&#8221;<\/span> <strong>src<\/strong>=[etc. etc.]<\/em><\/p>\n<ul>\n<li>TYPE refers to the border type (solid,\u00a0double,\u00a0dashed,\u00a0dotted,\u00a0outset,\u00a0inset,\u00a0groove,\u00a0ridge). \u00a0You can <a href=\"http:\/\/wpbtips.wordpress.com\/2009\/10\/14\/borders-pt-1\/\">see examples here<\/a>.<\/li>\n<li>#HEX is your color. I used this easy <a href=\"http:\/\/www.colorpicker.com\/\">Hex Color Picker site<\/a> to grab the code.<\/li>\n<\/ul>\n<p>Then I opened John&#8217;s post so that I could <a href=\"view-source:http:\/\/johnjohnston.info\/106\/flicking-a-five-card-story\/\">view his source coding<\/a>. \u00a0He did things a bit differently by doing something with the CSS code I think, but I haven&#8217;t touched that yet. I could still locate where he added the HTML code to create a shadow though.<\/p>\n<p><em>#fivecards{height:320px;width:500px;} #fivecards p{text-align:center;; } #fivecards img{max-width:500px;max-height:300px;<span style=\"color: #ff0000;\">border:solid 1px;padding:10px;box-shadow: 5px 5px 2px #888888;margin:5px<\/span>} #fivecards a{color:#000}<\/em><\/p>\n<p>The final additional code I needed to insert within the text editing view was:<\/p>\n<p><em><span style=\"color: #ff0000;\">style=&#8221;border: 8px ridge #FC0356; box-shadow: 5px 5px 2px #888888;&#8221;<\/span><\/em><\/p>\n<p>This told my blog post to format the picture with&#8230;<\/p>\n<ul>\n<li>an 8px border around the image<\/li>\n<li>formatted as a ridge<\/li>\n<li>with a red color variation identified as #FC0356<\/li>\n<li>Add a box-shadow (<a href=\"http:\/\/www.w3schools.com\/cssref\/css3_pr_box-shadow.asp\">Link to explanation of box shadow properties.<\/a>)<\/li>\n<li>with offset dimensions 5px horizontal shadow, 5 px vertical shadow, and a 2px blur spread<\/li>\n<li>with a greyish color identified as #888888<\/li>\n<\/ul>\n<p>NOTE: It&#8217;s very important you get all of the quotation marks, commas, and semi-colons exactly right.<\/p>\n<p>The final HTML code looks like this:<\/p>\n<p><em>&lt;<strong>img<\/strong> class=&#8221;alignnone size-medium wp-image-2841&#8243; <span style=\"color: #ff0000;\">style=&#8221;border: 8px ridge #FC0356; box-shadow: 5px 5px 2px #888888;&#8221;<\/span> alt=&#8221;EnglandRainChair&#8221; <strong>src<\/strong>=&#8221;http:\/\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair-300&#215;225.jpg&#8221; width=&#8221;300&#8243; height=&#8221;225&#8243; \/&gt;<\/em><\/p>\n<p>Giving me this beautifully red bordered and shadowed image.<\/p>\n<p><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"2841\" data-permalink=\"https:\/\/rockylouproductions.com\/blog_wp\/2013\/09\/14\/five-card-poetry-my-story\/englandrainchair\/\" data-orig-file=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?fit=3264%2C2448&amp;ssl=1\" data-orig-size=\"3264,2448\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;5&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;Canon PowerShot SX20 IS&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1267002694&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;54.877&quot;,&quot;iso&quot;:&quot;400&quot;,&quot;shutter_speed&quot;:&quot;0.0666666666667&quot;,&quot;title&quot;:&quot;&quot;}\" data-image-title=\"EnglandRainChair\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?fit=625%2C469&amp;ssl=1\" loading=\"lazy\" class=\"alignnone size-medium wp-image-2841\" style=\"border: 8px ridge #FC0356; box-shadow: 5px 5px 2px #888888;\" alt=\"EnglandRainChair\" src=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=300%2C225\" width=\"300\" height=\"225\" srcset=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=1024%2C768&amp;ssl=1 1024w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=624%2C467&amp;ssl=1 624w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?w=1250 1250w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?w=1875 1875w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/p>\n<p>or alternately by changing the Hex color number to #6E6E6E I can produce a dark grey border.<\/p>\n<p><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"2841\" data-permalink=\"https:\/\/rockylouproductions.com\/blog_wp\/2013\/09\/14\/five-card-poetry-my-story\/englandrainchair\/\" data-orig-file=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?fit=3264%2C2448&amp;ssl=1\" data-orig-size=\"3264,2448\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;5&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;Canon PowerShot SX20 IS&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1267002694&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;54.877&quot;,&quot;iso&quot;:&quot;400&quot;,&quot;shutter_speed&quot;:&quot;0.0666666666667&quot;,&quot;title&quot;:&quot;&quot;}\" data-image-title=\"EnglandRainChair\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?fit=625%2C469&amp;ssl=1\" loading=\"lazy\" class=\"alignnone size-medium wp-image-2841\" style=\"border: 8px ridge #6E6E6E; box-shadow: 5px 5px 2px #888888;\" alt=\"EnglandRainChair\" src=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=300%2C225\" width=\"300\" height=\"225\" srcset=\"https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=1024%2C768&amp;ssl=1 1024w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?resize=624%2C467&amp;ssl=1 624w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?w=1250 1250w, https:\/\/i0.wp.com\/rockylouproductions.com\/blog_wp\/wp-content\/uploads\/2013\/09\/EnglandRainChair.jpg?w=1875 1875w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/p>\n<p>If you are really ambitious and want to learn how to program with HTML and CSS I found this site\u00a0<a href=\"http:\/\/www.w3schools.com\/\">http:\/\/www.w3schools.com\/<\/a>\u00a0helpful a few years back when I was just starting out. \u00a0Once I started &#8220;programming&#8221; with RapidWeaver I didn&#8217;t feel I had a need for it until now.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Thanks to a recent post by John Johnston &#8220;Flicking a Five Card Story&#8221; \u00a0I brushed aside my anxiety, took the leap and dived into the HTML.\u00a0Well, let\u2019s be real\u2026 I just dipped my toes in the shallow end\u2026 but I did it. I created borders around all of my images in my 5 Card Flickr [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"nf_dc_page":"","_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":[460,189,26,46],"tags":[],"class_list":["post-2868","post","type-post","status-publish","format-standard","hentry","category-ds106","category-headless13-2","category-other-stuff","category-tutorials"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p3zfrO-Kg","jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/posts\/2868","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/comments?post=2868"}],"version-history":[{"count":8,"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/posts\/2868\/revisions"}],"predecessor-version":[{"id":2876,"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/posts\/2868\/revisions\/2876"}],"wp:attachment":[{"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/media?parent=2868"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/categories?post=2868"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rockylouproductions.com\/blog_wp\/wp-json\/wp\/v2\/tags?post=2868"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}