{"id":5773835,"date":"2015-02-11T01:17:17","date_gmt":"2015-02-11T01:17:17","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/bug-found-fixed\/"},"modified":"2016-08-22T16:23:51","modified_gmt":"2016-08-22T16:23:51","slug":"bug-found-fixed","status":"closed","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/bug-found-fixed\/","title":{"rendered":"Bug Found &amp; Fixed"},"content":{"rendered":"<p>PHP Ver: 5.5.17<br \/>\nOS: Centos 5<br \/>\nApache: 2.2.29<\/p>\n<p>I installed this and not only did it not work (hung in admin), but also created a 458mb error_log file in wp-admin.<\/p>\n<p>I dug into the errors and found that these fields in the Options table had no values (the fields existed, but had no values):<\/p>\n<pre><code>auto_image_width\nauto_image_height\nauto_image_fontsize<\/code><\/pre>\n<p>I fixed that in the db, but it still failed and created a 458mb error_log file.<\/p>\n<p>It now works properly due to these changes.<br \/>\nChanged this:<\/p>\n<pre><code>add_option(&#039;auto_image_fontsize&#039;,&quot;72&quot;);<\/code><\/pre>\n<p>To this:<\/p>\n<pre><code>add_option(&#039;auto_image_fontsize&#039;,72);<\/code><\/pre>\n<p>Added these after the last add_option on line 36:<\/p>\n<pre><code>$auto_image_width = 640;\n$auto_image_height = 360;\n$auto_image_fontsize = 72;<\/code><\/pre>\n<p>Added these after line 137:<\/p>\n<pre><code>$red = 255;\n$grn = 255;\n$blu = 255;\n\n$red = $shadow[&quot;red&quot;];\n$grn = $shadow[&quot;green&quot;];\n$blu = $shadow[&quot;blue&quot;];<\/code><\/pre>\n<p>Changed line 140 to use the new vars:<\/p>\n<pre><code>$shadow_color = imagecolorallocate( $new_featured_img, $red, $grn, $blu);<\/code><\/pre>\n<p>It&#8217;s working for me now.<\/p>\n<p>Thanks for writing it&#8230;was going to create this exact plugin.<\/p>\n<p>Rob<\/p>\n<p>https:\/\/wordpress.org\/plugins\/auto-featured-image-from-title\/<\/p>\n","protected":false},"template":"","class_list":["post-5773835","topic","type-topic","status-closed","hentry","topic-tag-bug-fixed"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/5773835","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/5773835\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=5773835"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}