{"id":55991,"date":"2022-05-29T03:01:45","date_gmt":"2022-05-28T17:01:45","guid":{"rendered":"http:\/\/www.rjmprogramming.com.au\/ITblog\/?p=55991"},"modified":"2022-06-07T15:19:17","modified_gmt":"2022-06-07T05:19:17","slug":"landing-page-autocompletion-blog-regexp-finds-tutorial","status":"publish","type":"post","link":"https:\/\/www.rjmprogramming.com.au\/ITblog\/landing-page-autocompletion-blog-regexp-finds-tutorial\/","title":{"rendered":"Landing Page Autocompletion Blog RegExp Finds Tutorial"},"content":{"rendered":"<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/index.htm\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Landing Page Autocompletion Blog RegExp Finds Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/landing_page_regexp_find.jpg\" title=\"Landing Page Autocompletion Blog RegExpFinds Tutorial\"  style=\"float:left;\" \/><\/a><p class=\"wp-caption-text\">Landing Page Autocompletion Blog RegExp Finds Tutorial<\/p><\/div>\n<p>Yesterday&#8217;s <a title='Landing Page Autocompletion Blog Finds Tutorial' href='#lpabft'>Landing Page Autocompletion Blog Finds Tutorial<\/a> needed work &#8230;<\/p>\n<ul>\n<li>tweaking for user driven <a target=_blank title='Javascript RegExp information from W3schools' href='https:\/\/www.w3schools.com\/js\/js_regexp.asp'>RegExp<\/a> (via Javascript) blog post finding from the RJM Programming Landing Pages, the old top codeline relying on string matching string length, a concept that does not gel with RegExp &#8230;<\/p>\n<p><code><br \/>\n    bigs=selcontis.split(new RegExp(('\\>' + acsofar.toLowerCase()<font color=blue>.replace(\/\\ \/g,\"\\\\s\")<\/font>), 'i'));<br \/>\n<\/code><\/p>\n<p> &#8230; object usage, while the second better codeline uses &#8220;&lt;\/option&gt;&#8221; as an end delimiter allowing for any length of blog posting title which receives a RegExp match &#8230;<br \/>\n<code><br \/>\n    \/\/testc='&lt;option ' + bigs[eval(-1 + jbigs)].split('&lt;option ')[eval(-1 + bigs[eval(-1 + jbigs)].split('&lt;option ').length)] + selcontis.split('&lt;option ' + bigs[eval(-1 + jbigs)].split('&lt;option ')[eval(-1 + bigs[eval(-1 + jbigs)].split('&lt;option ').length)])[1].substring(0, ('&gt;' + acsofar).length) + bigs[eval(0 + jbigs)].split('&lt;\/option&gt;')[0] + '&lt;\/option&gt;';<br \/>\n    testc='&lt;option ' + bigs[eval(-1 + jbigs)].split('&lt;option ')[eval(-1 + bigs[eval(-1 + jbigs)].split('&lt;option ').length)] + selcontis.split('&lt;option ' + bigs[eval(-1 + jbigs)].split('&lt;option ')[eval(-1 + bigs[eval(-1 + jbigs)].split('&lt;option ').length)])[1].split('&lt;\/option&gt;')[0] + '&lt;\/option&gt;'; \/\/ + bigs[eval(0 + jbigs)].split('&lt;\/option&gt;')[0] + '&lt;\/option&gt;';<br \/>\n<\/code><br \/>\n &#8230; and we <font color=blue>add a textbox title<\/font> so that a user can know this RegExp can be used &#8230;<br \/>\n<code><br \/>\n   document.getElementById('id3').innerHTML=document.getElementById('id3').innerHTML.replace(document.getElementById('tuts').outerHTML,'&lt;input <font color=blue>title=\"To match a third word you would prefix your word entry by \\\\w+\\\\s\\\\w+\\\\s\"<\/font> autocomplete=\"off\" type=text id=autokey onkeydown=\"zotzmaybe(event);\" style=\"display:inline-block;z-index:99;width:' + Math.floor(eval(0.4 * eval('' + tutselrect.width))) + 'px;\" placeholder=\"Type tutorial finding word(s)\" value=\"\" autofocus=\"\"&gt;&lt;\/input&gt;' + document.getElementById('tuts').outerHTML.split('&gt;')[0].replace('none','inline-block').replace('90%', Math.floor(eval(0.4 * eval('' + tutselrect.width))) + 'px').replace(\/\\\"\\ on\/g, '\" data-on') + '&gt;&lt;option id=selfirstopt value=\" \"&gt;Your finding options below ...&lt;\/option&gt;&lt;\/select&gt;');<br \/>\n<\/code><br \/>\n &#8230; to find strings within the blog post title as well as at the start, as needs be &#8230; and &#8230;<\/li>\n<li>overcoming the crontab PHP clobbering of our efforts by, for the meantime, shoring up a Javascript defence as mentioned in yesterday&#8217;s <a href=#ysp>Stop Press<\/a> &#8230; and &#8230;<\/li>\n<li>mobile platform <font color=blue>issues<\/font> &#8230;<br \/>\n<code><br \/>\n&lt;select onchange=\" if (('' + this.title).indexOf('.') != -1 && this.value.length &lt;= 2) {  autokeyway(); } else { if (1 == 1) {  document.body.style.cursor='progress'; setTimeout(preChangeTutNow, 7000);  } else { ChangeTutNow(this); } }\" class='mytuts' id='tuts' style='margin-top:4px;width: 90%; background-color:pink;' title='Tutorials' onblur=\"if (document.getElementById('selfirstopt').innerHTML.indexOf('autocompletion keyboard') != -1) { document.getElementById('selfirstopt').innerHTML=document.getElementById('selfirstopt').innerHTML.replace('autocompletion keyboard','keyboard autocompletion'); if (this.value.length == 1) { <font color=blue>this.title=this.title.split('.')[0] + '.';<\/font> this.value='  '; }  } else if (('' + this.title).indexOf('.') != -1 && this.value.length == 1) { autokeyway(); }\" onmouseout=\"this.title=this.title.split('.')[0] + '.';\" ontouchstart=\"if (document.getElementById('selfirstopt').innerHTML.indexOf('autocompletion keyboard') != -1) { document.getElementById('selfirstopt').innerHTML=document.getElementById('selfirstopt').innerHTML.replace('autocompletion keyboard','keyboard autocompletion');  if (this.value.length == 1) { <font color=blue>this.title=this.title.split('.')[0] + '.';<\/font> this.value='  '; }  } else if (('' + this.title).indexOf('.') != -1 && this.value.length == 1) { autokeyway(); }\" onmousedown=\"if (document.getElementById('selfirstopt').innerHTML.indexOf('autocompletion keyboard') != -1) {  document.getElementById('selfirstopt').innerHTML=document.getElementById('selfirstopt').innerHTML.replace('autocompletion keyboard','keyboard autocompletion');  if (this.value.length == 1) { <font color=blue>this.title=this.title.split('.')[0] + '.';<\/font> this.value='  '; }  } else if (('' + this.title).indexOf('.') != -1 && this.value.length == 1) { autokeyway(); }\" onclick=\" if (document.getElementById('selfirstopt').innerHTML.indexOf('autocompletion keyboard') != -1) {  document.getElementById('selfirstopt').innerHTML=document.getElementById('selfirstopt').innerHTML.replace('autocompletion keyboard','keyboard autocompletion');  if (this.value.length == 1) {  <font color=blue>this.title=this.title.split('.')[0] + '.';<\/font> this.value='  '; }  } else if (('' + this.title).indexOf('.') != -1 && this.value.length == 1) { autokeyway(); }\"&gt;&lt;option id=selfirstopt selected='selected' value=' '&gt;Tutorials (show blog, toggle sort order, click for autocompletion keyboard) ...&lt;\/option&gt;<br \/>\n<\/code>\n<\/li>\n<\/ul>\n<p> &#8230; in <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/PHP\/Geographicals\/diff.php?one=http:\/\/www.rjmprogramming.com.au\/Welcome_files\/WelcomeIndex.js---GETME\" title=\"WelcomeIndex.js\">the changed<\/a> <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Welcome_files\/WelcomeIndex.js---GETME\" title=\"WelcomeIndex.js\">external Javascript WelcomeIndex.js<\/a> &#8220;all Landing Pages helper&#8221; external Javascript code.<\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=_blank  href='\/\/www.rjmprogramming.com.au\/ITblog\/landing-page-autocompletion-blog-regexp-finds-tutorial\/'>Landing Page Autocompletion Blog RegExp Finds Tutorial<\/a>.<\/p-->\n<hr>\n<p id='lpabft'>Previous relevant <a target=_blank title='Landing Page Autocompletion Blog Finds Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/landing-page-autocompletion-blog-finds-tutorial\/'>Landing Page Autocompletion Blog Finds Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/index.htm\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Landing Page Autocompletion Blog Finds Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/landing_page_autocompletion.jpg\" title=\"Landing Page Autocompletion Blog Finds Tutorial\"  style=\"float:left;\" \/><\/a><p class=\"wp-caption-text\">Landing Page Autocompletion Blog Finds Tutorial<\/p><\/div>\n<p>Two recent themes, and another we like, and enjoy using, combine today, as per &#8230;<\/p>\n<ul>\n<li>the <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/index.htm\" title=\"RJM Programming Landing Page\">&#8220;Landing Page&#8221;<\/a> theme of yesterday&#8217;s <a title='Blog Posting Filtering Background Date Interfacing Tutorial' href='#bpfbdit'>Blog Posting Filtering Background Date Interfacing Tutorial<\/a> &#8230; along with &#8230;<\/li>\n<li>not that we&#8217;ve said it in so many words, but, &#8220;the <a target=_blank title='Hotkey information from Wikipedia ... thanks' href='https:\/\/en.wikipedia.org\/wiki\/Keyboard_shortcut'>hotkey<\/a>&#8221; work behind the scenes with the web application in the recent <a target=_blank href='https:\/\/www.rjmprogramming.com.au\/ITblog\/keyboard-based-cursor-image-blog-source-link-tutorial\/' title='Keyboard Based Cursor Image Blog Source Link Tutorial'>Keyboard Based Cursor Image Blog Source Link Tutorial<\/a>&#8216;s thread of blog postings &#8230; and today&#8217;s &#8230;<\/li>\n<li><a target=_blank title='Autocompletion information from Wikipedia ... thanks' href='https:\/\/en.wikipedia.org\/wiki\/Autocomplete'>&#8220;autocompletion&#8221;<\/a> textbox (and associated dropdown) usage<\/li>\n<\/ul>\n<p> &#8230; (along with <font size=1>good ol&#8217;<\/font> Javvascript DOM) to improve the functionality of the RJM Programming Landing Page means by which it connects to the RJM Programming WordPress Blog tutorial content.<\/p>\n<p>Autocompletion is good primarily because it is quite a human response to fill in something given a &#8220;smaller&#8221; start, even given a modern baby&#8217;s likely first word &#8230;<\/p>\n<blockquote><p>\ngoo &#8230; goog &#8230; googl &#8230; google\n<\/p><\/blockquote>\n<p>And so, if you have data at your disposal you would not have to wait for the baby to spout &#8220;google&#8221;.  You might gather all the &#8220;google&#8221; relevant tutorials (and maybe some others) at the &#8220;goo&#8221; stage (or even earlier).<\/p>\n<p>In our Landing Pages we do have this data available courtesy of the dropdown over to the right and down aways, populated by crontab PHP tasks undertaken each day up at the RJM Programming Apache\/PHP\/MySql web server.  We&#8217;ve decided to copy that dropdown&#8217;s innerHTML content into the Javascript var<font size=1>iable<\/font> <i>selcontis<\/i> in <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/PHP\/Geographicals\/diff.php?one=http:\/\/www.rjmprogramming.com.au\/Welcome_files\/WelcomeIndex.js--GETME\" title=\"WelcomeIndex.js\">the changed<\/a> <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Welcome_files\/WelcomeIndex.js--GETME\" title=\"WelcomeIndex.js\">external Javascript WelcomeIndex.js<\/a> &#8220;all Landing Pages helper&#8221; code below, where we add some new functions as well &#8230;<\/p>\n<p><code><br \/>\nvar selcontis='';<br \/>\nvar acstr='';<br \/>\nvar acsofar='';<br \/>\n<br \/>\nfunction zotzmaybe(evt) {<br \/>\n    var bigsih=document.getElementById('tuts').innerHTML.split('&lt;\/option&gt;')[0] + '&lt;\/option&gt;';<br \/>\n    var bigs=[], jbigs=0, itot=0;<br \/>\n    var testc='';<br \/>\n    acstr=evt.target.value;<br \/>\n    if (evt.keyCode &gt;= 48 && evt.keyCode &lt;= 57) {<br \/>\n     acsofar=acstr + ('' + eval(-48 + evt.keyCode));<br \/>\n    } else if (evt.keyCode &gt;= 65 && evt.keyCode &lt;= 90) {<br \/>\n     acsofar=acstr + String.fromCharCode(evt.keyCode); \/\/('' + eval(-65 + evt.keyCode));<br \/>\n    } else if (evt.keyCode &gt;= 97 && evt.keyCode &lt;= 122) {<br \/>\n     acsofar=acstr +  + String.fromCharCode(evt.keyCode); \/\/('' + eval(-97 + evt.keyCode));<br \/>\n    } else {<br \/>\n     acsofar+=' ';<br \/>\n    }<br \/>\n    \/\/alert('acstr=' + acstr + ' and acsofar=' + acsofar);<br \/>\n    if (selcontis.toLowerCase().indexOf('&gt;' + acsofar.toLowerCase()) != -1) {<br \/>\n    bigs=selcontis.split(new RegExp(('\\&gt;' + acsofar.toLowerCase()), 'i'));<br \/>\n    for (jbigs=1; jbigs&lt;bigs.length; jbigs++) {<br \/>\n    testc='&lt;option ' + bigs[eval(-1 + jbigs)].split('&lt;option ')[eval(-1 + bigs[eval(-1 + jbigs)].split('&lt;option ').length)] + selcontis.split('&lt;option ' + bigs[eval(-1 + jbigs)].split('&lt;option ')[eval(-1 + bigs[eval(-1 + jbigs)].split('&lt;option ').length)])[1].substring(0, ('&gt;' + acsofar).length) + bigs[eval(0 + jbigs)].split('&lt;\/option&gt;')[0] + '&lt;\/option&gt;';<br \/>\n    if (testc.indexOf(')<\/option>') != -1) {<br \/>\n    itot++;<br \/>\n    bigsih+=testc;<br \/>\n     }<br \/>\n     }<br \/>\n    document.getElementById('tuts').innerHTML=bigsih;<br \/>\n    document.getElementById('oneopti').innerHTML='Found ' + itot + ' for ' + acsofar + ' below ...';<br \/>\n    } else {<br \/>\n    document.getElementById('tuts').innerHTML=bigsih;<br \/>\n    document.getElementById('oneopti').innerHTML='None found  for ' + acsofar + ' ...';<br \/>\n    }<br \/>\n}<br \/>\n<br \/>\nfunction muchlater() {<br \/>\n  document.getElementById('tuts').size='1';<br \/>\n}<br \/>\n<br \/>\nfunction preChangeTutNow() {<br \/>\n  if (!document.getElementById('autokey')) {<br \/>\n    ChangeTutNow(document.getElementById('tuts'));<br \/>\n  } else if (document.getElementById('tuts').outerHTML.indexOf(' data-onblur=') != -1 && document.getElementById('tuts').outerHTML.indexOf(' size=') != -1) {<br \/>\n    ChangeTutNow(document.getElementById('tuts'));<br \/>\n  }<br \/>\n  document.body.style.cursor='pointer';<br \/>\n}<br \/>\n<br \/>\nfunction autokeyway() {<br \/>\n   var tutselrect=document.getElementById('tuts').getBoundingClientRect();<br \/>\n   if (!document.getElementById('autokey') && document.getElementById('id3')) {<br \/>\n   selcontis=document.getElementById('tuts').innerHTML;<br \/>\n   var wasd=document.getElementById('id3').innerHTML.length;<br \/>\n   document.getElementById('tuts').style.display='none';<br \/>\n<br \/>   document.getElementById('id3').innerHTML=document.getElementById('id3').innerHTML.replace(document.getElementById('tuts').outerHTML,'&lt;input autocomplete=\"off\" type=text id=autokey onkeydown=\"zotzmaybe(event);\" style=\"display:inline-block;z-index:99;width:' + Math.floor(eval(0.5 * eval('' + tutselrect.width))) + 'px;\" placeholder=\"Type tutorial finding word(s)\" value=\"\" autofocus=\"\"&gt;&lt;\/input&gt;' + document.getElementById('tuts').outerHTML.split('&gt;')[0].replace('none','inline-block').replace('90%', Math.floor(eval(0.48 * eval('' + tutselrect.width))) + 'px').replace(\/\\\"\\ on\/g, '\" data-on') + '&gt;&lt;option id=oneopti value=\" \"&gt;Your finding options below ...&lt;\/option&gt;&lt;\/select&gt;');<br \/>\n   setTimeout(muchlater, 10000);<br \/>\n   \/\/alert('' + tutselrect.width + ' was=' + wasd + ' vs ' + document.getElementById('id3').innerHTML.length);<br \/>\n   } else if (!document.getElementById('autokey') && document.getElementById('i268')) {<br \/>\n   selcontis=document.getElementById('tuts').innerHTML;<br \/>\n   document.getElementById('i268').innerHTML+='&lt;input autocomplete=\"off\" type=text id=autokey onkeyup=\"otzmaybe(this);\" onchange=\"otzmaybe(this); \" onblur=\" justcheck(this.value);  \"  style=\"z-index:99;position:absolute;top:' + tutselrect.top + 'px;left:' + tutselrect.left + 'px;width:' + tutselrect.width + 'px;\" placeholder=\"Type tutorial finding word(s)\" value=\"\" autofocus=\"\"&gt;&lt;\/input&gt;';<br \/>\n   \/\/alert('' + tutselrect.top);<br \/>\n   }<br \/>\n}<br \/>\n<\/code>  <\/p>\n<p> &#8230; the &#8220;red rag to a bull&#8221; clue that hotkeys are involved  being the use of the <a target=_blank title='Event onkeydown information from w3schools' href='http:\/\/www.w3schools.com\/tags\/ev_onkeydown.asp'>&#8220;onkeydown&#8221;<\/a> <font size=1>(and\/or sometimes you see <a target=_blank title='Event onkeypress information from w3schools' href='http:\/\/www.w3schools.com\/tags\/ev_onkeypress.asp'>&#8220;onkeypress&#8221;<\/a><\/font>) keyboard event pointing at function zotzmaybe.  In &#8220;function zotzmaybe&#8221; too, autocompletion compares a hotkey result to data ahead of the display of the keystroke, by which time the incarnation of the original dropdown can be populated with appropriate entries, along with the original calls and ways of functioning.  You need to see how a Landing Page caller of the WelcomeIndex.js external Javascript changed to allow for this, as per &#8230;<\/p>\n<ul>\n<li>Tell the cache <font color=blue>we&#8217;ve changed<\/font> WelcomeIndex.js &#8230;<br \/>\n<code><br \/>\n&lt;script async=\"async\" type=\"text\/javascript\" src=\"Welcome_files\/WelcomeIndex.js?Lawson=Now<font color=blue>&rand=76987<\/font>\"&gt;&lt;\/script&gt;<br \/>\n<\/code>\n<\/li>\n<li>Substantially <font color=blue>rearrange the tutorial dropdown&#8217;s attributes and first option element<\/font> &#8230;<br \/>\n<code><br \/>\n&lt;select onchange=\" <font color=blue>if (('' + this.title).indexOf('.') != -1 && this.value.length &lt;= 2) {  autokeyway(); } else { if (1 == 1) {  document.body.style.cursor='progress'; setTimeout(preChangeTutNow, 7000);  } else { <\/font>ChangeTutNow(this); <font color=blue>} }<\/font>\" class='mytuts' id='tuts' style='margin-top:4px;width: 90%; background-color:pink;' title='Tutorials' <font color=blue>onblur=\"if (document.getElementById('selfirstopt').innerHTML.indexOf('autocompletion keyboard') != -1) { document.getElementById('selfirstopt').innerHTML=document.getElementById('selfirstopt').innerHTML.replace('autocompletion keyboard','keyboard autocompletion'); if (this.value.length == 1) { this.value='  '; }  } else if (('' + this.title).indexOf('.') != -1 && this.value.length == 1) { autokeyway(); }\" onmouseout=\"this.title=this.title.split('.')[0] + '.';\" ontouchdown=\"if (document.getElementById('selfirstopt').innerHTML.indexOf('autocompletion keyboard') != -1) { document.getElementById('selfirstopt').innerHTML=document.getElementById('selfirstopt').innerHTML.replace('autocompletion keyboard','keyboard autocompletion');  if (this.value.length == 1) { this.value='  '; }  } else if (('' + this.title).indexOf('.') != -1 && this.value.length == 1) { autokeyway(); }\" onmousedown=\"if (document.getElementById('selfirstopt').innerHTML.indexOf('autocompletion keyboard') != -1) {  document.getElementById('selfirstopt').innerHTML=document.getElementById('selfirstopt').innerHTML.replace('autocompletion keyboard','keyboard autocompletion');  if (this.value.length == 1) { this.value='  '; }  } else if (('' + this.title).indexOf('.') != -1 && this.value.length == 1) { autokeyway(); }\" onclick=\"if (document.getElementById('selfirstopt').innerHTML.indexOf('autocompletion keyboard') != -1) {  document.getElementById('selfirstopt').innerHTML=document.getElementById('selfirstopt').innerHTML.replace('autocompletion keyboard','keyboard autocompletion');  if (this.value.length == 1) { this.value='  '; }  } else if (('' + this.title).indexOf('.') != -1 && this.value.length == 1) { autokeyway(); }\"<\/font>&gt;&lt;option <font color=blue>id=selfirstopt<\/font> title=\"First option\" selected='selected' value=' '&gt;Tutorials (show blog, toggle sort order<font color=blue>, click for autocompletion keyboard<\/font>) ...&lt;\/option&gt;<br \/>\n<\/code>\n<\/li>\n<li>And <font color=blue>a small tweak<\/font> to the next option regarding toggling &#8230;<br \/>\n<code><br \/>\n&lt;option value='  '&gt;Tutorials (toggle sort order<font color=blue> and reselect and click first for autocompletion keyboard<\/font>) ...&lt;\/option&gt;<br \/>\n<\/code><br \/>\n<\/lu>\n<\/ul>\n<p> &#8230; to add in a textbox and dropdown way for a user to use an autocompletion approach to finding topics of interest to filter the RJM Programming WordPress Blog tutorials via, in order to hone in on information and content of interest.<\/p>\n<p id=ysp><b><i>Stop Press<\/i><\/b><\/p>\n<p>Until we line up our crontab PHP work (which effectively wipes out the tweaks above &#8230; sorry, viewers, earlier this morning) &#8230; we have the WelcomeIndex.js fix up as per &#8230;<\/p>\n<p><code><br \/>\nfunction jsonloadf() {<br \/>\n  var firsto=false, secondo=false;<br \/>\n  var optsare=document.getElementsByTagName('option');<br \/>\n  for (var ioptsare=0; ioptsare&lt;optsare.length; ioptsare++) {<br \/>\n    if (optsare[ioptsare].innerHTML.indexOf('toggle sort order') != -1) {<br \/>\n      if (!firsto) {<br \/>\n        if (optsare[ioptsare].innerHTML.indexOf('click for ') == -1 && optsare[ioptsare].innerHTML.indexOf(')') != -1) {<br \/>\n          optsare[ioptsare].innerHTML=optsare[ioptsare].innerHTML.replace(')', ', click for autocompletion keyboard)');<br \/>\n          optsare[ioptsare].id='selfirstopt';<br \/>\n        }<br \/>\n        firsto=true;<br \/>\n      } else if (!secondo) {<br \/>\n        if (optsare[ioptsare].innerHTML.indexOf('click first ') == -1 && optsare[ioptsare].innerHTML.indexOf(')') != -1) {<br \/>\n          optsare[ioptsare].innerHTML=optsare[ioptsare].innerHTML.replace(')', ' and reselect and click first for autocompletion keyboard)');<br \/>\n        }<br \/>\n        secondo=true;<br \/>\n      }<br \/>\n    }<br \/>\n  }<br \/>\n}<br \/>\n<br \/>\nsetTimeout(jsonloadf, 3000);<br \/>\n<\/code><\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=_blank  href='\/\/www.rjmprogramming.com.au\/ITblog\/landing-page-autocompletion-blog-finds-tutorial\/'>Landing Page Autocompletion Blog Finds Tutorial<\/a>.<\/p-->\n<hr>\n<p id='bpfbdit'>Previous relevant <a target=_blank title='Blog Posting Filtering Background Date Interfacing Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/blog-posting-filtering-background-date-interfacing-tutorial\/'>Blog Posting Filtering Background Date Interfacing Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/index.htm\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Blog Posting Filtering Background Date Interfacing Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/date_search.jpg\" title=\"Blog Posting Filtering Background Date Interfacing Tutorial\"  style=\"float:left;\" \/><\/a><p class=\"wp-caption-text\">Blog Posting Filtering Background Date Interfacing Tutorial<\/p><\/div>\n<p>We wanted to nuance the Blog Content filtering functionality of <a title='Blog Posting Filtering Background Interfacing Tutorial' href='#bpfbit'>Blog Posting Filtering Background Interfacing Tutorial<\/a> by &#8230;<\/p>\n<ul>\n<li>adding to the existant <i>word within blog posting title<\/i> filtering prowess &#8230; with &#8230;<\/li>\n<li><i>date (YYYYMMDD) based date filtering<\/i> of blog posting<\/li>\n<\/ul>\n<p> &#8230; and needed to purloin <font size=1>(good ol&#8217;)<\/font> WordPress codex 404.php PHP code functionality changes below &#8230;<\/p>\n<p><code><br \/>\n29d28<br \/>\n&lt;   $mbd=\"\";<br \/>\n32,148d30<br \/>\n&lt;       \/\/file_put_contents('zac.zac', $_SERVER['QUERY_STRING']);<br \/>\n&lt;   if (isset($_GET['mustbedated'])) {<br \/>\n&lt;     $mbd=str_replace('+',' ',urldecode($_GET['mustbedated']));<br \/>\n&lt;     $mzs=explode(\" \", $mbd);<br \/>\n&lt;     if (sizeof($mzs) &gt; 1) {<br \/>\n&lt;       $newid=\"\";<br \/>\n&lt;       $suffn=\"\";<br \/>\n&lt;       if (strpos($mbd, \")\") !== false) { $suffn=\")\"; }<br \/>\n&lt;       for ($imzs=0; $imzs&lt;sizeof($mzs); $imzs++) {<br \/>\n&lt;         if (substr($mzs[$imzs],0,1) == '(') {<br \/>\n&lt;           $newid='(' . $newid;<br \/>\n&lt;           $mzs[$imzs]=substr($mzs[$imzs],1);<br \/>\n&lt;         }<br \/>\n&lt;         if ($mzs[$imzs] != '') {<br \/>\n&lt;           if (1 == 1 || (substr($mzs[$imzs],0,1) &gt;= '0' && substr($mzs[$imzs],0,1) &lt;= '9')) {<br \/>\n&lt;             if (substr($mzs[$imzs],0,1) &gt;= '0' && substr($mzs[$imzs],0,1) &lt;= '9' && strlen(str_replace(')','',$mzs[$imzs])) == 4) {<br \/>\n&lt;               $newid.=str_replace(')','',$mzs[$imzs]);<br \/>\n&lt;             } else if (substr($mzs[$imzs],0,1) &gt;= '0' && substr($mzs[$imzs],0,1) &lt;= '9' && strlen(str_replace(')','',$mzs[$imzs])) == 8) {<br \/>\n&lt;               $newid.=str_replace(')','',$mzs[$imzs]);<br \/>\n&lt;             } else if (substr($mzs[$imzs],0,1) &gt;= '0' && substr($mzs[$imzs],0,1) &lt;= '9' && strlen(str_replace(')','',$mzs[$imzs])) == 2 && strlen($newid) &gt;= 4) {<br \/>\n&lt;               $newid.=str_replace(')','',$mzs[$imzs]);<br \/>\n&lt;             } else if (substr($mzs[$imzs],0,1) &gt;= '0' && substr($mzs[$imzs],0,1) &lt;= '9' && strlen(str_replace(')','',$mzs[$imzs])) == 2) {<br \/>\n&lt;               $suffn=str_replace(')','',$mzs[$imzs]) . $suffn;<br \/>\n&lt;             } else if (substr($mzs[$imzs],0,1) &gt;= '0' && substr($mzs[$imzs],0,1) &lt;= '9' && strlen(str_replace(')','',$mzs[$imzs])) == 1 && strlen($newid) &gt;= 4) {<br \/>\n&lt;               $newid.='0' . str_replace(')','',$mzs[$imzs]);<br \/>\n&lt;             } else if (substr($mzs[$imzs],0,1) &gt;= '0' && substr($mzs[$imzs],0,1) &lt;= '9' && strlen(str_replace(')','',$mzs[$imzs])) == 1) {<br \/>\n&lt;               $suffn='0' . str_replace(')','',$mzs[$imzs]) . $suffn;<br \/>\n&lt;<br \/>\n&lt;           } else if (strpos(strtolower($mzs[$imzs]), 'jan') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='01';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='01' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;           } else if (strpos(strtolower($mzs[$imzs]), 'feb') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='02';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='02' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;           } else if (strpos(strtolower($mzs[$imzs]), 'mar') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='03';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='03' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;           } else if (strpos(strtolower($mzs[$imzs]), 'apr') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='04';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='04' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;           } else if (strpos(strtolower($mzs[$imzs]), 'may') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='05';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='05' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;           } else if (strpos(strtolower($mzs[$imzs]), 'jun') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='06';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='06' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;             } else if (strpos(strtolower($mzs[$imzs]), 'jul') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='07';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='07' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;             } else if (strpos(strtolower($mzs[$imzs]), 'aug') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='08';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='08' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;             } else if (strpos(strtolower($mzs[$imzs]), 'sep') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='09';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='09' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;             } else if (strpos(strtolower($mzs[$imzs]), 'oct') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='10';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='10' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;             } else if (strpos(strtolower($mzs[$imzs]), 'nov') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='11';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='11' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;             } else if (strpos(strtolower($mzs[$imzs]), 'dec') !== false) {<br \/>\n&lt;               if (strlen($newid) &gt;= 4) {<br \/>\n&lt;                 $newid.='12';<br \/>\n&lt;               } else {<br \/>\n&lt;                 $suffn='12' . $suffn;<br \/>\n&lt;               }<br \/>\n&lt;             }<br \/>\n&lt;<br \/>\n&lt;           }<br \/>\n&lt;         }<br \/>\n&lt;       }<br \/>\n&lt;       $newid.=$suffn;<br \/>\n&lt;       if ($newid != \"\") { if (strlen($newid) == 8) { $mbd='(' . $newid . ')';  } else { $mbd=$newid; }  }<br \/>\n&lt;     }<br \/>\n&lt;       if (strlen($mbd) == 8) { $mbd='(' . $mbd . ')';  }<br \/>\n&lt;       \/\/file_put_contents('zab.zab', $mbd . ' ... ' . $mc);<br \/>\n&lt;     if (strpos($icontis, $mbd) !== false && sizeof($ideaarray) &gt; 1) {<br \/>\n&lt;       $mc=$mbd;<br \/>\n&lt;       $iicontis=substr(explode($mc, $icontis)[0],-500,500) . $mc . explode($mc, $icontis)[1];<br \/>\n&lt;       $ideaarray=explode('&amp;pp=&amp;pn=&amp;title=', $iicontis);<br \/>\n&lt;       \/\/file_put_contents('zaa.zaa', $ideaarray[1]);<br \/>\n&lt;     }<br \/>\n&lt;   }<br \/>\n153,155c35,36<br \/>\n&lt;     if (isset($_GET['mustcontain']) || $mc != \"\") {<br \/>\n&lt;     if (strlen(trim($_GET['mustcontain'])) &gt; 0 || $mc != \"\") {<br \/>\n&lt;       if ($mc == \"\") {<br \/>\n---<br \/>\n&gt;     if (isset($_GET['mustcontain'])) {<br \/>\n&gt;     if (strlen(trim($_GET['mustcontain'])) &gt; 0) {<br \/>\n157,158d37<br \/>\n&lt;       }<br \/>\n&lt;       \/\/file_put_contents('zaq.zaq', $mc);<br \/>\n161c40<br \/>\n&lt;       if (@preg_match($mc, null) === false || $mbd != \"\") { \/\/ not regexp<br \/>\n---<br \/>\n&gt;       if (@preg_match($mc, null) === false) { \/\/ not regexp<br \/>\n170,171d48<br \/>\n&lt;         } else {<br \/>\n&lt;           $mcs=explode(\",\", $mc);<br \/>\n175,178d51<br \/>\n&lt;         if ($mbd != \"\") {<br \/>\n&lt;         $numf=explode($mc, $icontis);<br \/>\n&lt;       \/\/file_put_contents('zas.zas', '' . sizeof($numf));<br \/>\n&lt;         } else {<br \/>\n180d52<br \/>\n&lt;         }<br \/>\n184d55<br \/>\n&lt;       \/\/file_put_contents('zat.zat', '' . sizeof($numf));<br \/>\n186d56<br \/>\n&lt;       \/\/file_put_contents('zad.zad', '' . sizeof($numf) . ' ... ' . $ideaarray[2]);<br \/>\n190,199c60<br \/>\n&lt;       $nmc=sizeof($ideaarray);<br \/>\n&lt;       $oned=\"&gt;\";<br \/>\n&lt;       $twod=\"'\";<br \/>\n&lt;       $threed='\"';<br \/>\n&lt;       $allok=true;<br \/>\n&lt;       if ($mbd != \"\") { $nmc=(1 + sizeof($numf)); $oned=\"&lt;\/option&gt;\";  $twod=\"&lt;\/option&gt;\";  $threed=\"&lt;\/option&gt;\"; $jmc=1;  }<br \/>\n&lt;<br \/>\n&lt;       \/\/if ($mbd != \"\") { file_put_contents('zar.zar', '' . sizeof($mcs) . ' ' . sizeof($mcss) . ' ' . $nmc . ' ' . $mbd); }<br \/>\n&lt;<br \/>\n&lt;       for ($imc=$jmc; $imc&lt;$nmc; $imc++) {<br \/>\n---<br \/>\n&gt;       for ($imc=$jmc; $imc&lt;sizeof($ideaarray); $imc++) {<br \/>\n203d63<br \/>\n&lt;       \/\/file_put_contents('zag.zag', '' . sizeof($mcs) . ' ' . sizeof($mcss) . ' ' . $imc . ' ' . $mc);<br \/>\n206c66<br \/>\n&lt;               if (strpos(str_replace('_',' ',explode($threed,explode($twod,explode($oned, $ideaarray[$imc])[0])[0])[0]), $mcs[$sdf]) === false) {<br \/>\n---<br \/>\n&gt;               if (strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcs[$sdf]) === false) {<br \/>\n213c73<br \/>\n&lt;               if (strpos(str_replace('_',' ',explode($threed,explode($twod,explode($oned, $ideaarray[$imc])[0])[0])[0]), $mcss[$sdf]) === false) {<br \/>\n---<br \/>\n&gt;               if (strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcss[$sdf]) === false) {<br \/>\n220c80<br \/>\n&lt;                 if (strpos(str_replace('_',' ',explode($threed,explode($twod,explode($oned, $ideaarray[$imc])[0])[0])[0]), $mcss[$sdf]) &gt; strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcss[-1 + $sdf])) {<br \/>\n---<br \/>\n&gt;                 if (strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcss[$sdf]) &gt; strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcss[-1 + $sdf])) {<br \/>\n232,236c92<br \/>\n&lt;           \/\/if (trim($ideaarray[$imc]) != '' && strpos($ideaarray[$imc],'(') !== false) {<br \/>\n&lt;       \/\/file_put_contents('zah.zah', '' . $mc . ' ' . $ideaarray[$imc]);<br \/>\n&lt;           \/\/}<br \/>\n&lt;           if (strpos(strtolower($ideaarray[$imc]), strtolower($mc)) !== false && $allok && ($mbd == \"\" || strpos(strtolower($ideaarray[$imc]), \"tutorial (\") !== false)) {<br \/>\n&lt;        \/\/if ($mbd != \"\") { file_put_contents('zaf.zaf', '' . $mc); }<br \/>\n---<br \/>\n&gt;           if (strpos(strtolower($ideaarray[$imc]), strtolower($mc)) !== false && $allok) {<br \/>\n243c99<br \/>\n&lt;           if (($hd % 2) == 0 || $mbd != \"\") {<br \/>\n---<br \/>\n&gt;           if (($hd % 2) == 0) {<br \/>\n265c121<br \/>\n&lt;           if (($hd % 2) == 0 || $mbd != \"\") {<br \/>\n---<br \/>\n&gt;           if (($hd % 2) == 0) {<br \/>\n275c131<br \/>\n&lt;         if (sizeof($fhuhs) == 20 || (sizeof($fhuhs) == 1 && strlen($mbd) &gt; 6)) { break; }<br \/>\n---<br \/>\n&gt;         if (sizeof($fhuhs) == 20) { break; }<br \/>\n281,282c137<br \/>\n&lt;         if (sizeof($fhuhs) == 1 && ($mbd != \"\" || $imc &gt; (sizeof($ideaarray) \/ 2))) {<br \/>\n&lt;        \/\/if ($mbd != \"\") {  $huhrand=$forcedhuh;   file_put_contents('zae.zae', '' . $mbd . ' ' . $fhuhs[0] . ' ' . $ideaarray[$fhuhs[0]]); }<br \/>\n---<br \/>\n&gt;         if (sizeof($fhuhs) == 1 && $imc &gt; (sizeof($ideaarray) \/ 2)) {<br \/>\n293d147<br \/>\n&lt;     if ($mbd == \"\") {<br \/>\n306d159<br \/>\n&lt;     }<br \/>\n308,323d160<br \/>\n&lt;     if ($mbd != \"\") {<br \/>\n&lt;       $huhrand=$fhuhs[0];<br \/>\n&lt;       \/\/file_put_contents('zan.zan', '' . $huhrand . ' ' . $ideaarray[$huhrand]);<br \/>\n&lt;     if (strpos(strtolower($ideaarray[$huhrand]), \"tutorial (\") !== false) {<br \/>\n&lt;     \/\/$ptis=str_replace('_',' ',$ideaarray[$huhrand] . \")\");<br \/>\n&lt;     $ptis=str_replace('_',' ',explode('Tutorial', explode('&gt;', explode('\"', $ideaarray[$huhrand])[0])[0])[0] . \"Tutorial\");<br \/>\n&lt;       \/\/file_put_contents('zao.zao', '' . $ptis);<br \/>\n&lt;     } else if (strpos(strtolower($ideaarray[1 + $huhrand]), \"tutorial (\") !== false) {<br \/>\n&lt;     $huhrand++;<br \/>\n&lt;       \/\/file_put_contents('zau.zau', '  ' . $huhrand . ' ' . $ideaarray[$huhrand]);<br \/>\n&lt;     \/\/$ptis=str_replace('_',' ',$ideaarray[$huhrand] . \")\");<br \/>\n&lt;     $ptis=str_replace('_',' ',explode('Tutorial', explode('&gt;', explode('\"', $ideaarray[$huhrand])[0])[0])[0] . \"Tutorial\");<br \/>\n&lt;       \/\/file_put_contents('zav.zav', ' ' . $ptis);<br \/>\n&lt;     }<br \/>\n&lt;       \/\/file_put_contents('zaw.zaw', '' . $ptis);<br \/>\n&lt;     } else {<br \/>\n327d163<br \/>\n&lt;     }<br \/>\n329,332c165<br \/>\n&lt;     if ($mbd != \"\") {<br \/>\n&lt;        $tdt=str_replace('(','',str_replace(')','',$mbd));<br \/>\n&lt;        $tutdate=' (' . substr($tdt,6,2) . ' ' . str_replace(\"01\",\"January\",str_replace(\"02\",\"February\",str_replace(\"03\",\"March\",str_replace(\"04\",\"April\",str_replace(\"05\",\"May\",str_replace(\"06\",\"June\",str_replace(\"07\",\"July\",str_replace(\"08\",\"August\",str_replace(\"09\",\"September\",str_replace(\"10\",\"October\",str_replace(\"11\",\"November\",str_replace(\"12\",\"December\",substr($tdt,4,2))))))))))))) . ' ' . substr($tdt,0,4) . ')';<br \/>\n&lt;     } else if (strpos($ideaarray[-1 + $huhrand], 'MyNew-') !== false) {<br \/>\n---<br \/>\n&gt;     if (strpos($ideaarray[-1 + $huhrand], 'MyNew-') !== false) {<br \/>\n335d167<br \/>\n&lt;       \/\/if ($mbd != \"\") { file_put_contents('zak.zak', '' . $tutdate); }<br \/>\n342d173<br \/>\n&lt;       \/\/if ($mbd != \"\") { file_put_contents('zam.zam', '' . $tutdate); }<br \/>\n351d181<br \/>\n&lt;        if ($mbd != \"\") { $ptis=explode(' (', $ptis)[0]; }<br \/>\n<\/code><\/p>\n<p> &#8230; in conjunction with <font color=blue>small changes<\/font> amongst the RJM Programming landing pages &#8230;<\/p>\n<p><code><br \/>\n&lt;span style=\"cursor:pointer;font-size:18px;\" title=\"Open a random date WordPress Blog post\" onclick=\"window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&andclickme=y','_blank','top=20,left=100,width=900,height=800');\"&gt;&amp;nbsp;&amp;#128197;&lt;\/span&gt;&lt;sup onclick=\"var thuh=prompt('Optionally enter a topic of interest you find in the relevant blog posting title where you can use comma delimiter for a list of find strings or semicolon for list of find strings in nominated order, else for no RJM Programming blog navigations click\/tap Cancel.<font color=blue> An 8 numeric YYYYMMDD entry will look at that date.<\/font>',' '); if (thuh != null) { <font color=blue>if (thuh.trim().length == 8 && thuh.trim().replace(\/0\/g,'').replace(\/1\/g,'').replace(\/2\/g,'').replace(\/3\/g,'').replace(\/4\/g,'').replace(\/5\/g,'').replace(\/6\/g,'').replace(\/7\/g,'').replace(\/8\/g,'').replace(\/9\/g,'') == '') {  window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&andclickme=y&mustbedated=' + encodeURIComponent(thuh.trim()),'_blank','top=20,left=100,width=900,height=800');   } else<\/font> if (thuh.trim() == '') { window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&andclickme=y','_blank','top=20,left=100,width=900,height=800'); } else { window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&andclickme=y&mustcontain=' + encodeURIComponent(thuh),'_blank','top=20,left=100,width=900,height=800'); }  }\" style=\"cursor:pointer;font-size:8px;\" title=\"Open a random date WordPress Blog post filtered by your entered topic\"&gt;&amp;#10067;&lt;\/sup&gt;<br \/>\n<\/code><\/p>\n<p> &#8230; to make all this happen.<\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=_blank  href='\/\/www.rjmprogramming.com.au\/ITblog\/blog-posting-filtering-background-date-interfacing-tutorial\/'>Blog Posting Filtering Background Date Interfacing Tutorial<\/a>.<\/p-->\n<hr>\n<p id='bpfbit'>Previous relevant <a target=_blank title='Blog Posting Filtering Background Interfacing Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/blog-posting-filtering-background-interfacing-tutorial\/'>Blog Posting Filtering Background Interfacing Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"https:\/\/www.rjmprogramming.com.au\/ITblog\/more404.jpg\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Blog Posting Filtering Background Interfacing Tutorial\" src=\"https:\/\/www.rjmprogramming.com.au\/ITblog\/more404.jpg\" title=\"Blog Posting Filtering Background Interfacing Tutorial\"  style=\"float:left;\" \/><\/a><p class=\"wp-caption-text\">Blog Posting Filtering Background Interfacing Tutorial<\/p><\/div>\n<p>With <a title='Image Pair Fitting into a Given Dimension Sources Tutorial' href='#ipfgdst'>Image Pair Fitting into a Given Dimension Sources Tutorial<\/a>, below, we identified this WordPress Blog&#8217;s TwentyTen theme&#8217;s 404.php code as (an example of) &#8230;<\/p>\n<blockquote cite='\/\/www.rjmprogramming.com.au\/ITblog\/image-pair-fitting-into-a-given-dimension-sources-tutorial\/'><p>\n&#8220;code lazy <font size=1>(for us)<\/font>&#8221; &#8220;intervention points&#8221; that mean most of the hard part of the job is done for you\n<\/p><\/blockquote>\n<p> &#8230; means by which we could mimic a little of the brilliant <a target=_blank title='Lorem Picsum' href='https:\/\/picsum.photos'>Lorem Picsum<\/a>&#8216;s modus operandi providing a random image resource, providing our own inhouse RJM Programming WordPress Blog Posting Image resource.<\/p>\n<p>Since then, we&#8217;ve leant on that start, nuancing it to allow &#8220;filtering&#8221; of that total &#8220;RJM Programming WordPress Blog Posting Image resource&#8221; dataset via a user nominated string that should appear in the Blog Posting Title.   This led us, in <a target=_blank title='Landing Page Random Blog Post Topic Link Tutorial' href='https:\/\/www.rjmprogramming.com.au\/ITblog\/landing-page-random-blog-post-topic-link-tutorial'>Landing Page Random Blog Post Topic Link Tutorial<\/a> to make the change &#8230;<\/p>\n<p><code><br \/>\n&lt;option id='MyNew-20110314' onclick='windowopen(\"\/\/www.rjmprogramming.com.au\/wordpress\/?p=58&amp;pp=&amp;pn=&amp;title=News_from_RJM_Programming\",\"_blank\"); ' value='\/\/www.rjmprogramming.com.au\/wordpress\/?p=58&amp;pp=&amp;pn=&amp;title=News_from_RJM_Programming'&gt;News from RJM Programming (20110314)&lt;\/option&gt;&lt;\/select&gt;&lt;\/span&gt;&lt;span style=\"cursor:pointer;font-size:18px;\" title=\"Open a random date WordPress Blog post\" onclick=\"window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&andclickme=y','_blank','top=20,left=100,width=900,height=800');\"&gt;&amp;nbsp;&amp;#128197;<font color=blue>&lt;\/span&gt;<\/font>&lt;sup<font color=blue> onclick=\"var thuh=prompt('Optionally enter a topic of interest you find in the relevant blog posting title, else for no RJM Programming blog navigations click\/tap Cancel.',' '); if (thuh != null) { if (thuh.trim() == '') { window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&andclickme=y','_blank','top=20,left=100,width=900,height=800'); } else { window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&andclickme=y&mustcontain=' + encodeURIComponent(thuh),'_blank','top=20,left=100,width=900,height=800'); }  }\"<\/font> style=\"cursor:pointer;font-size:8px;\"<font color=blue> title=\"Open a random date WordPress Blog post filtered by your entered topic\"<\/font>&gt;&amp;#10067;&lt;\/sup&gt;&lt;\/p&gt;<br \/>\n<\/code> <\/p>\n<p> &#8230; these days, on <a target=_blank title='RJM Programming Landing Page' href='\/\/www.rjmprogramming.com.au\/'>Landing Page<\/a>s appearing like <span style=\"cursor: pointer; font-size: 15px;\" title=\"Open a random date WordPress Blog post\" onclick=\"window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&amp;andclickme=y','_blank','top=20,left=100,width=900,height=800');\">&nbsp;&#128197;<\/span><sup onclick=\"var thuh=prompt('Optionally enter a topic of interest you find in the relevant blog posting title where you can use comma delimiter for a list of find strings or semicolon for list of find strings in nominated order, else for no RJM Programming blog navigations click\/tap Cancel.',' '); if (thuh != null) { if (thuh.trim() == '') { window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&amp;andclickme=y','_blank','top=20,left=100,width=900,height=800'); } else { window.open('\/\/www.rjmprogramming.com.au\/ITblog\/500\/500?random=' + Math.floor(Math.random() * 19875643) + '&amp;andclickme=y&amp;mustcontain=' + encodeURIComponent(thuh),'_blank','top=20,left=100,width=900,height=800'); }  }\" style=\"cursor:pointer;font-size:8px;\" title=\"Open a random date WordPress Blog post filtered by your entered topic\">&#10067;<\/sup>, as an example of how we interface the new 404.php &#8220;background helper&#8221; changes, below, into (one example of) &#8220;forward user interfacer&#8221; user of that &#8220;background helper&#8221; with its <font color=blue>new code<\/font> parts below &#8230;<\/p>\n<p>&lt;?php<br \/>\n<code><br \/>\n\/\/ WordPress \"codex\" PHP comments precede<br \/>\n<br \/>\n$ioff=0;<br \/>\n$imfnameafterdomainsep=\"random_background_fadeinout.jpg\";<br \/>\n$ptitle=\"Random Background Webpage Fade Tutorial<font color=blue> (10 May 2022)<\/font>\";<br \/>\n$bonl=\"\";<br \/>\n<font color=blue>$tonl=\"\";<br \/>\n$mcs=[];<br \/>\n$mcss=[];<br \/>\n$bigmc=\"\";<\/font><br \/>\n<br \/>\nfunction selectNewBlogPostingTutorialPicture() {<br \/>\n  global $imfnameafterdomainsep, $ptitle, $bonl<font color=blue>, $tonl, $mcs, $mcss<\/font>;<br \/>\n  $forcedhuh=-1;<br \/>\n  $fhuhs=[];<br \/>\n  <font color=blue>$mc=\"\";<br \/>\n  $mcs=[];<br \/>\n  $mcss=[];<br \/>\n  $isregexp=false;<br \/>\n  $numf=[];<\/font><br \/>\n  $foundipath=\"\";<br \/>\n  $icontis=file_get_contents(explode('ITblog' . DIRECTORY_SEPARATOR, dirname(__FILE__) . DIRECTORY_SEPARATOR)[0] . \"index.html\");<br \/>\n  $ideaarray=explode('&amp;pp=&amp;pn=&amp;title=', $icontis);<br \/>\n  if (sizeof($ideaarray) <font color=blue>&lt;=<\/font> 1) {<br \/>\n    $imfnameafterdomainsep=\"random_background_fadeinout.jpg\";<br \/>\n    $ptitle=\"Random Background Webpage Fade Tutorial (10 May 2022)\";<br \/>\n  } else if (sizeof($ideaarray) &gt; 1) {<br \/>\n    <font color=blue>if (isset($_GET['mustcontain'])) {<br \/>\n    if (strlen(trim($_GET['mustcontain'])) &gt; 0) {<br \/>\n      $mc=str_replace('@#$','',str_replace('  ','+ ',str_replace('  @#$','++',str_replace('   ','++ ',(str_replace('+', ' ', urldecode($_GET['mustcontain']))) . '@#$'))));<br \/>\n      $bigmc=str_replace(\";\",\"*\",str_replace(\",\",\"*\",$mc));<br \/>\n      if (@preg_match($mc, null) === false) { \/\/ not regexp<br \/>\n        if (strpos($mc, \",\") !== false || strpos($mc, \";\") !== false) {<br \/>\n          if (strpos($mc, ';') !== false) {<br \/>\n          $mcss=explode(\";\", $mc);<br \/>\n          $mc=$mcss[0];<br \/>\n          } else {<br \/>\n          $mcs=explode(\",\", $mc);<br \/>\n          $mc=$mcs[0];<br \/>\n          }<br \/>\n        }<br \/>\n        $mc=strtolower($mc);<br \/>\n        $numf=explode($mc, strtolower(explode($ideaarray[0], $icontis)[1]));<br \/>\n      } else {  \/\/ regexp<br \/>\n        $isregexp=true;<br \/>\n        $numf[0]=$icontis;<br \/>\n      }<br \/>\n      if (sizeof($numf) &gt; 1 || $isregexp) { \/\/ && sizeof($numf) &lt; 10) {<br \/>\n      $jmc=(-1 + sizeof(explode('&amp;pp=&amp;pn=&amp;title=', $numf[0])));<br \/>\n      for ($imc=$jmc; $imc&lt;sizeof($ideaarray); $imc++) {<br \/>\n        if ($oktoloop) {<br \/>\n        if (!$isregexp) {<br \/>\n          $allok=true;<br \/>\n          if (sizeof($mcs) &gt; 1) {<br \/>\n            for ($sdf=1; $sdf&lt;sizeof($mcs); $sdf++) {<br \/>\n              if (strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcs[$sdf]) === false) {<br \/>\n                $allok=false;<br \/>\n              }<br \/>\n            }<br \/>\n          } elseif (sizeof($mcss) &gt; 1) {<br \/>\n            for ($sdf=1; $sdf&lt;sizeof($mcss); $sdf++) {<br \/>\n              if ($allok) {<br \/>\n              if (strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcss[$sdf]) === false) {<br \/>\n                $allok=false;<br \/>\n              } else {<br \/>\n                if (strpos(strtolower($ideaarray[$imc]), strtolower($mc)) !== false) {<br \/>\n                if (strpos(strtolower($ideaarray[$imc]), strtolower($mc)) &gt; strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcss[$sdf])) {<br \/>\n                $allok=false;<br \/>\n                } else if ($sdk &gt; 1) {<br \/>\n                if (strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcss[$sdf]) &gt; strpos(str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]), $mcss[-1 + $sdf])) {<br \/>\n                $allok=false;<br \/>\n                }<br \/>\n                }<br \/>\n                } else {<br \/>\n                $allok=false;<br \/>\n                }<br \/>\n              }<br \/>\n              }<br \/>\n            }<br \/>\n          }<br \/>\n          if ($allok) {<br \/>\n          if (strpos(strtolower($ideaarray[$imc]), strtolower($mc)) !== false && $allok) {<br \/>\n          $hd=rand(2, (-1 + sizeof($ideaarray)));<br \/>\n          $hdd=1;<br \/>\n          if (sizeof($numf) &gt; 20) {<br \/>\n          $hdd=rand(2, (-1 + sizeof($ideaarray)));<br \/>\n          }<br \/>\n          if (($hdd % 2) == 1) {<br \/>\n          if (($hd % 2) == 0) {<br \/>\n            array_push($fhuhs, $imc);<br \/>\n          } else {<br \/>\n            array_unshift($fhuhs, $imc);<br \/>\n          }<br \/>\n          }<br \/>\n          }<br \/>\n          }<br \/>\n        } else if ($isregexp) {<br \/>\n          \/\/$arrsp=preg_split($mc, explode(\"&gt;\", $ideaarray[$imc])[0]);<br \/>\n          \/\/$arrsp=preg_split('\/Javascript\/',  str_replace('_',' ',explode(\"&gt;\", $ideaarray[$imc])[0]));<br \/>\n          \/\/if (!$arrsp) { $arrsp=[]; }<br \/>\n          $mystr=str_replace('_',' ',explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]);<br \/>\n          if (preg_match($mc, $mystr)) { \/\/ !== false) {<br \/>\n          \/\/if (sizeof($arrsp) &gt; 1) {<br \/>\n          if ($isregexp) { file_put_contents('iregtwo.found', '\/Javascript\/' . $mc . ' ... 1 ... ' . explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]); }<br \/>\n          $hd=rand(2, (-1 + sizeof($ideaarray)));<br \/>\n          $hdd=1;<br \/>\n          if (sizeof($numf) &gt; 20) {<br \/>\n          $hdd=rand(2, (-1 + sizeof($ideaarray)));<br \/>\n          }<br \/>\n          if (($hdd % 2) == 1) {<br \/>\n          if (($hd % 2) == 0) {<br \/>\n            array_push($fhuhs, $imc);<br \/>\n          } else {<br \/>\n            array_unshift($fhuhs, $imc);<br \/>\n          }<br \/>\n          }<br \/>\n          } else {<br \/>\n          file_put_contents('jregtwo.found', '\/Javascript\/' . $mc . ' ... ' . ' ... ' . explode('\"',explode(\"'\",explode(\"&gt;\", $ideaarray[$imc])[0])[0])[0]);<br \/>\n          }<br \/>\n        }<br \/>\n        if (sizeof($fhuhs) == 20) { break; }<br \/>\n      }<br \/>\n      }<br \/>\n      }<br \/>\n      if (sizeof($fhuhs) &gt; 0) {<br \/>\n        $forcedhuh=$fhuhs[0];<br \/>\n        if (sizeof($fhuhs) == 1 && $imc &gt; (sizeof($ideaarray) \/ 2)) {<br \/>\n          $oktoloop=false; \/\/break;<br \/>\n        }<br \/>\n      }<br \/>\n     }<br \/>\n    }<\/font><br \/>\n    if (trim($mc) != \"\" && $forcedhuh == -1 && sizeof($numf) &lt;= 1 && sizeof($fhuhs) == 0) {<br \/>\n     $imfnameafterdomainsep=\"random_background_fadeinout.jpg\";<br \/>\n     $ptitle=\"Random Background Webpage Fade Tutorial<font color=blue> (10 May 2022)<\/font>\";<br \/>\n    } else {<br \/>\n    while ($foundipath == \"\") {<br \/>\n    if ($forcedhuh &gt;= 1) {<br \/>\n    $huhrand=$forcedhuh;<br \/>\n    array_shift($fhuhs);<br \/>\n    if (sizeof($fhuhs) &gt; 0) {<br \/>\n        $forcedhuh=$fhuhs[0];<br \/>\n    } else {<br \/>\n        $forcedhuh=-1;<br \/>\n        $foundipath=\" \";<br \/>\n    }<br \/>\n    } else {<br \/>\n    $huhrand=rand(2, (-1 + sizeof($ideaarray)));<br \/>\n    }<br \/>\n    $ptis=\"\";<br \/>\n    if (strpos(explode('&gt;', explode('\"', $ideaarray[$huhrand])[0])[0], \"Tutorial\") !== false) {<br \/>\n    $ptis=str_replace('_',' ',explode('Tutorial', explode('&gt;', explode('\"', $ideaarray[$huhrand])[0])[0])[0] . \"Tutorial\");<br \/>\n    }<br \/>\n    $tutdate=\"\";<br \/>\n    if (strpos($ideaarray[-1 + $huhrand], 'MyNew-') !== false) {<br \/>\n       $tdt=substr(explode('MyNew-', $ideaarray[-1 + $huhrand])[-1 + sizeof(explode('MyNew-', $ideaarray[-1 + $huhrand]))],0,8);<br \/>\n       $tutdate=' (' . substr($tdt,6,2) . ' ' . str_replace(\"01\",\"January\",str_replace(\"02\",\"February\",str_replace(\"03\",\"March\",str_replace(\"04\",\"April\",str_replace(\"05\",\"May\",str_replace(\"06\",\"June\",str_replace(\"07\",\"July\",str_replace(\"08\",\"August\",str_replace(\"09\",\"September\",str_replace(\"10\",\"October\",str_replace(\"11\",\"November\",str_replace(\"12\",\"December\",substr($tdt,4,2))))))))))))) . ' ' . substr($tdt,0,4) . ')';<br \/>\n    if (trim($mc) != \"\") {<br \/>\n        <font color=blue>if (!$isregexp) {<\/font><br \/>\n      if (strpos(strtolower($ptis), $mc) === false) { $tutdate=\"\"; }<br \/>\n        } <font color=blue>else {<br \/>\n      if (!preg_match($mc, $ptis)) { $tutdate=\"\"; }<br \/>\n        }<\/font><br \/>\n    }<br \/>\n    }<br \/>\n    $pnumis=explode('&', explode('?p=', $ideaarray[-1 + $huhrand]   )[-1 + sizeof(explode('?p=', $ideaarray[-1 + $huhrand]   ))])[0];<br \/>\n    $thisbpc=file_get_contents('https:\/\/www.rjmprogramming.com.au\/ITblog\/?p=' . $pnumis);<br \/>\n    if (strpos($thisbpc, ' class=\"wp-caption') !== false) {<br \/>\n     $thatbpc=explode('\"', explode(' src=\"', explode(' class=\"wp-caption', $thisbpc)[1])[1])[0]; \/\/ www.rjmprogramming.com.au\/PHP\/emoji_animation_css_block.jpg<br \/>\n     if (strpos($thatbpc, \"rjmprogramming.com.au\/\") !== false) {<br \/>\n      if (strpos($thatbpc, \".jp\") !== false || strpos($thatbpc, \".png\") !== false || strpos($thatbpc, \".gif\") !== false) {<br \/>\n       if ($tutdate != \"\" && strpos($ptis, \" Tutorial\") !== false && strpos($ptis, \" (\") === false && strpos($ptis, \"%\") === false && strpos($ptis, \"&\") === false && file_exists(explode('ITblog' . DIRECTORY_SEPARATOR, dirname(__FILE__) . DIRECTORY_SEPARATOR)[0] .   explode(\"rjmprogramming.com.au\/\", $thatbpc)[1]   )) {<br \/>\n        $ptis.=$tutdate;<br \/>\n        $foundipath=explode('ITblog' . DIRECTORY_SEPARATOR, dirname(__FILE__) . DIRECTORY_SEPARATOR)[0] .   explode(\"rjmprogramming.com.au\/\", $thatbpc)[1];<br \/>\n        if ($foundipath != \"\") {<br \/>\n          $imfnameafterdomainsep=explode(\"rjmprogramming.com.au\/\", $thatbpc)[1];<br \/>\n          $ptitle=$ptis;<br \/>\n          $onlme=\"\";<br \/>\n          if (strpos(('' . $_SERVER['QUERY_STRING']), 'andclickme=') !== false) {<br \/>\n            if ($mc != \"\") {<br \/>\n              $onlme=' onload=\" window.open(' . \"'\/\/www.rjmprogramming.com.au\/ITblog\/?p=\" . $pnumis . \"','_blank','top=200,left=0,height=700,width=900'); \" . '\" ';<br \/>\n              <font color=blue>if ($isregexp) {<br \/>\n              $zis=0;<br \/>\n              $zzis=strlen($mc);<br \/>\n              if (strpos(($mc . '~'), '\/~') !== false) { $zzis--; }<br \/>\n              if (strpos(('~' . $mc), '~\/') !== false) { $zzis--; $zis=1; }<br \/>\n              $onlme=str_replace('; \"', '; window.open(' . \"'\/\/www.rjmprogramming.com.au\/itnewblog\/match\/mapper.php?pm=\" . urlencode(substr($mc,$zis,$zzis)) . \"','_blank','top=250,left=1200,height=650,width=900');  \" . '\"', $onlme);<br \/>\n              } else {<br \/>\n              $onlme=str_replace('; \"', '; window.open(' . \"'\/\/www.rjmprogramming.com.au\/itnewblog\/match\/mapper.php?pm=\" . urlencode(explode('*',$bigmc)[0]) . \"','_blank','top=250,left=1200,height=650,width=900');  \" . '\"', $onlme);<br \/>\n              }<\/font><br \/>\n            } else {<br \/>\n              $onlme=' onload=\" window.open(' . \"'\/\/www.rjmprogramming.com.au\/ITblog\/?p=\" . $pnumis . \"','_blank','top=200,left=100,height=700,width=900'); \" . '\" ';<br \/>\n            }<br \/>\n          }<br \/>\n          $bonl=$onlme . ' title=' . \"'\" . 'Click opens relevant blog post called ' . $ptis . ' and double click opens relevant blog post action item' . \"'\" . ' onclick=\" window.open(' . \"'\/\/www.rjmprogramming.com.au\/ITblog\/?p=\" . $pnumis . \"','_blank'); \" . '\" ondblclick=\" window.open(' . \"'\/\/www.rjmprogramming.com.au\/slideshow.html?title=\" . str_replace(urlencode('|'), '%20', urlencode(str_replace(' ','|',$ptis))) . \"','_blank'); \" . '\"';<br \/>\n          <font color=blue>$tonl='&lt;head&gt;&lt;title&gt;' . $ptis . '&lt;\/title&gt;&lt;\/head&gt;';<\/font><br \/>\n        }<br \/>\n       }<br \/>\n      }<br \/>\n     }<br \/>\n    }<br \/>\n    }<br \/>\n    }<br \/>\n  }<br \/>\n}<br \/>\n<br \/> <br \/>\nfunction createScaledImage($newWidth,$newHeight,$path,$datauri) { \/\/ thanks to <a target=_blank title='https:\/\/stackoverflow.com\/questions\/16774521\/scale-image-using-php-and-maintaining-aspect-ratio' href='https:\/\/stackoverflow.com\/questions\/16774521\/scale-image-using-php-and-maintaining-aspect-ratio'>https:\/\/stackoverflow.com\/questions\/16774521\/scale-image-using-php-and-maintaining-aspect-ratio<\/a><br \/>\n<br \/>\n    $image_name=explode(DIRECTORY_SEPARATOR, $path)[-1 + sizeof(explode(DIRECTORY_SEPARATOR, $path))];<br \/>\n<br \/> <br \/>\n    $mime = getimagesize($path);<br \/>\n<br \/>\n    if ($mime['mime']=='image\/png') {<br \/>\n        $src_img = imagecreatefrompng($path);<br \/>\n    }<br \/>\n    if ($mime['mime']=='image\/jpg' || $mime['mime']=='image\/jpeg' || $mime['mime']=='image\/pjpeg') {<br \/>\n        $src_img = imagecreatefromjpeg($path);<br \/>\n    }<br \/>\n    if ($mime['mime']=='image\/gif') {<br \/>\n        $src_img = imagecreatefromgif($path);<br \/>\n    }<br \/>\n<br \/>\n    $old_x          =   imageSX($src_img);<br \/>\n    $old_y          =   imageSY($src_img);<br \/>\n<br \/>\n    if ($old_x &gt; $old_y) {<br \/>\n        $thumb_w    =   $newWidth;<br \/>\n        $thumb_h    =   $old_y\/$old_x*$newWidth;<br \/>\n    }<br \/>\n<br \/>\n    if ($old_x &lt; $old_y) {<br \/>\n        $thumb_w    =   $old_x\/$old_y*$newHeight;<br \/>\n        $thumb_h    =   $newHeight;<br \/>\n    }<br \/>\n<br \/>\n    if ($old_x == $old_y) {<br \/>\n        $thumb_w    =   $newWidth;<br \/>\n        $thumb_h    =   $newHeight;<br \/>\n    }<br \/>\n<br \/>\n    $dst_img        =   imagecreatetruecolor($thumb_w,$thumb_h);<br \/>\n<br \/>\n    imagecopyresampled($dst_img,$src_img,0,0,0,0,$thumb_w,$thumb_h,$old_x,$old_y);<br \/>\n<br \/>\n    \/\/ New save location<br \/>\n    $new_thumb_loc = '\/tmp\/' . $image_name;<br \/>\n<br \/>\n    if (!$datauri) {<br \/>\n    if($mime['mime']=='image\/png') {<br \/>\n      header('Content-Type: image\/png');<br \/>\n      imagepng($dst_img); \/\/,$new_thumb_loc,8);<br \/>\n    if (file_exists($new_thumb_loc)) {<br \/>\n    unlink($new_thumb_loc);<br \/>\n    }<br \/>\n    imagedestroy($dst_img);<br \/>\n    imagedestroy($src_img);<br \/>\n      exit;<br \/>\n    } else if ($mime['mime']=='image\/jpg' || $mime['mime']=='image\/jpeg' || $mime['mime']=='image\/pjpeg') {<br \/>\n      header('Content-Type: image\/jpeg');<br \/>\n      imagejpeg($dst_img); \/\/,$new_thumb_loc,80);<br \/>\n    if (file_exists($new_thumb_loc)) {<br \/>\n    unlink($new_thumb_loc);<br \/>\n    }<br \/>\n    imagedestroy($dst_img);<br \/>\n    imagedestroy($src_img);<br \/>\n      exit;<br \/>\n    } else if ($mime['mime']=='image\/gif') {<br \/>\n      header('Content-Type: image\/gif');<br \/>\n      imagegif($dst_img); \/\/,$new_thumb_loc,80);<br \/>\n    if (file_exists($new_thumb_loc)) {<br \/>\n    unlink($new_thumb_loc);<br \/>\n    }<br \/>\n    imagedestroy($dst_img);<br \/>\n    imagedestroy($src_img);<br \/>\n      exit;<br \/>\n    }<br \/>\n    exit;<br \/>\n    }<br \/>\n<br \/>\n    $result=\"\";<br \/>\n    if ($mime['mime']=='image\/png') {<br \/>\n        imagepng($dst_img,$new_thumb_loc,8);<br \/>\n        $result = file_get_contents($new_thumb_loc);<br \/>\n    }<br \/>\n    if ($mime['mime']=='image\/jpg' || $mime['mime']=='image\/jpeg' || $mime['mime']=='image\/pjpeg') {<br \/>\n        imagejpeg($dst_img,$new_thumb_loc,80);<br \/>\n        $result = file_get_contents($new_thumb_loc);<br \/>\n    }<br \/>\n    if ($mime['mime']=='image\/gif') {<br \/>\n        imagegif($dst_img,$new_thumb_loc);<br \/>\n        $result = file_get_contents($new_thumb_loc);<br \/>\n    }<br \/>\n<br \/>\n    imagedestroy($dst_img);<br \/>\n    imagedestroy($src_img);<br \/>\n<br \/> <br \/>\n    if (file_exists($new_thumb_loc)) {<br \/>\n    unlink($new_thumb_loc);<br \/>\n    }<br \/>\n<br \/>\n    return $result;<br \/>\n}<br \/>\n<\/code><br \/>\n?&gt;<\/p>\n<p> &#8230; called within <font color=blue>&#8220;new if section URL analysis code&#8221;<\/font> &#8230;<\/p>\n<p>&lt;?php<br \/>\n<code><br \/>\n$uparts=explode(\"\/\", $_SERVER['REQUEST_URI']);<br \/>\nif (sizeof($uparts) &gt;= 2) {<br \/>\n  if (trim(explode('#',explode('?',$uparts[-1 + sizeof($uparts)])[0])[0]) == '') {<br \/>\n    $ioff=-1;<br \/>\n  }<br \/>\n  if (1 == 1 || ('' . $_SERVER['QUERY_STRING']) == '') {<br \/>\n    $usz=sizeof($uparts);<br \/>\n    if (str_replace('?' . $_SERVER['QUERY_STRING'],'',trim($uparts[-1 + sizeof($uparts)])) == '') { $usz--; }<br \/>\n    if ($usz == 3 && strpos($uparts[-1 + $usz], \"%20\") !== false || strpos($uparts[-1 + $usz], \"+\") !== false) { \/\/ fix \/ITblog\/Linux%20mailx%20Primer%20Tutorial\/ 18\/1\/2022 RM<br \/>\n     $oky=true;<br \/>\n     if (substr(trim($uparts[$ioff - 1 + sizeof($uparts)]) . ' ',0,1) &gt;= '0' && substr(trim($uparts[$ioff - 1 + sizeof($uparts)]) . ' ',0,1) &lt;= '9') {<br \/>\n     if (substr(trim($uparts[$ioff - 2 + sizeof($uparts)]) . ' ',0,1) &gt;= '0' && substr(trim($uparts[$ioff - 2 + sizeof($uparts)]) . ' ',0,1) &lt;= '9') {<br \/>\n     $oky=false;<br \/>\n     }<br \/>\n     }<br \/>\n     if ($oky) {<br \/>\n     if (('' . $_SERVER['QUERY_STRING']) == '') {<br \/>\n       header('Location: ' . str_replace('~``','\/ITblog\/',str_replace('\/','',str_replace('\/ITBLOG\/','~``',str_replace('\/itblog\/','~``',str_replace('\/ITblog\/','~``',str_replace('--','-',str_replace('---','-',str_replace('+','-',str_replace('%20','-',$_SERVER['REQUEST_URI']))))))))));<br \/>\n     } else {<br \/>\n       header('Location: ' . explode('?',str_replace('~``','\/ITblog\/',str_replace('\/','',str_replace('\/ITBLOG\/','~``',str_replace('\/itblog\/','~``',str_replace('\/ITblog\/','~``',str_replace('--','-',str_replace('---','-',str_replace('+','-',str_replace('%20','-',$_SERVER['REQUEST_URI']))))))))))[0] . '?' . $_SERVER['QUERY_STRING']);<br \/>\n     }<br \/>\n     exit;<br \/>\n     }<br \/>\n    }<br \/>\n  }<br \/>\n  if (str_replace(\"category\",\"cat\",strtolower($uparts[-2 + sizeof($uparts)])) == \"cat\" || strtolower($uparts[-2 + sizeof($uparts)]) == \"category\") {<br \/>\n    $catsare=[\"\",\"Not Categorised\",\"Ajax\",\"Android\",\"Animation\",\"Anything You Like\",\"Code::Blocks\",\"Colour Matching\",\"Data Integration\",\"Database\",\"Delphi\",\"Eclipse\",\"eLearning\",\"ESL\",\"Event-Driven Programming\",\"Games\",\"GIMP\",\"GUI\",\"Hradware\",\"Installers\",\"iOS\",\"Land Surveying\",\"Moodle\",\"Music Poll\",\"NetBeans\",\"Networking\",\"News\",\"ontop\",\"OOP\",\"Operating System\",\"Photography\",\"Projects\",\"Signage Poll\",\"Software\",\"SpectroPhotometer\",\"Tiki Wiki\",\"Trips\",\"Tutorials\",\"Uncategorized\",\"Visual Studio\",\"Xcode\"];<br \/>\n    for ($ibh=1; $ibh&lt;sizeof($catsare); $ibh++) {<br \/>\n      if (explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0] == strtolower($catsare[$ibh])) {<br \/>\n        if (strtolower($catsare[$ibh]) == \"ontop\") {<br \/>\n          header('Location: https:\/\/www.rjmprogramming.com.au\/ITblog\/category\/' . str_replace(\" \",\"-\",explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0])) . '#' . $ibh;<br \/>\n        } else {<br \/>\n          header('Location: https:\/\/www.rjmprogramming.com.au\/ITblog\/category\/' . str_replace(\" \",\"-\",explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0])) . '#' . $ibh;<br \/>\n        }<br \/>\n      } else if (explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0] == ('' . $ibh)) {<br \/>\n        if (strtolower($catsare[$ibh]) == \"ontop\") {<br \/>\n          header('Location: https:\/\/www.rjmprogramming.com.au\/ITblog\/?cat=' . str_replace(\" \",\"-\",explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0])) . '#' . $ibh;<br \/>\n        } else {<br \/>\n          header('Location: https:\/\/www.rjmprogramming.com.au\/ITblog\/?cat=' . str_replace(\" \",\"-\",explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0])) . '#' . $ibh;<br \/>\n        }<br \/>\n      }<br \/>\n    }<br \/>\n  } else if (substr(trim($uparts[$ioff - 1 + sizeof($uparts)]) . ' ',0,1) &gt;= '0' && substr(trim($uparts[$ioff - 1 + sizeof($uparts)]) . ' ',0,1) &lt;= '9') {<br \/>\n    if (substr(trim($uparts[$ioff - 2 + sizeof($uparts)]) . ' ',0,1) &gt;= '0' && substr(trim($uparts[$ioff - 2 + sizeof($uparts)]) . ' ',0,1) &lt;= '9') {<br \/>\n      $uwidth=trim($uparts[$ioff - 2 + sizeof($uparts)]);<br \/>\n      $uheight=trim(explode('#',explode('?',$uparts[$ioff - 1 + sizeof($uparts)])[0])[0]);<br \/>\n      $imfnameafterdomainsep=\"random_background_fadeinout.jpg\";<br \/>\n      $ptitle=\"Random Background Webpage Fade Tutorial\";<br \/>\n      selectNewBlogPostingTutorialPicture();<br \/>\n      $postingiurl=explode('ITblog' . DIRECTORY_SEPARATOR, dirname(__FILE__) . DIRECTORY_SEPARATOR)[0] . $imfnameafterdomainsep;<br \/>\n      list($iwidth, $iheight, $itype, $iattr) = getimagesize($postingiurl);<br \/>\n      $amime = getimagesize($postingiurl);<br \/>\n      if ($ioff == 0) {<br \/>\n      \/\/header('Content-Type: image\/jpeg');<br \/>\n      echo \"&lt;html&gt;\" . $tonl . \"&lt;body\" . $bonl . \"&gt;&lt;pre&gt;data:image\/jpeg;base64,\" . base64_encode(createScaledImage($uwidth,$uheight,$postingiurl,true)) . \"#\" . str_replace('+','%20',urlencode($ptitle)) . \"&lt;\/pre&gt;&lt;\/body&gt;&lt;\/html&gt;\";<br \/>\n      } else if (1 == 2) {<br \/>\n      \/\/header('Content-Type: image\/jpeg');<br \/>\n      echo '&lt;img src=\"' . \"data:image\/jpeg;base64,\" . base64_encode(file_get_contents($postingiurl)) . \"#\" . str_replace('+','%20',urlencode($ptitle)) . '\"&gt;&lt;\/img&gt;';<br \/>\n      } else {<br \/>\n      createScaledImage($uwidth,$uheight,$postingiurl,false); \/\/imagecreatefromjpeg($postingiurl);<br \/>\n      }<br \/>\n      exit;<br \/>\n    }<br \/>\n  }<br \/>\n}<br \/>\n<br \/>\nget_header(); ?&gt;<br \/>\n<br \/>\n\/\/ more WordPress \"codex\" PHP code follows<br \/>\n<\/code><br \/>\n?&gt;<\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=_blank  href='\/\/www.rjmprogramming.com.au\/ITblog\/blog-posting-filtering-background-interfacing-tutorial\/'>Blog Posting Filtering Background Interfacing Tutorial<\/a>.<\/p-->\n<hr>\n<p id='ipfgdst'>Previous relevant <a target=_blank title='Image Pair Fitting into a Given Dimension Sources Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/image-pair-fitting-into-a-given-dimension-sources-tutorial\/'>Image Pair Fitting into a Given Dimension Sources Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.htm\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Image Pair Fitting into a Given Dimension Sources Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension_rjm_source.jpg\" title=\"Image Pair Fitting into a Given Dimension Sources Tutorial\"  style=\"float:left;\" \/><\/a><p class=\"wp-caption-text\">Image Pair Fitting into a Given Dimension Sources Tutorial<\/p><\/div>\n<p>Thinking &#8220;layers of functionality&#8221; here, we think that progress onto yesterday&#8217;s <a title='Image Pair Fitting into a Given Dimension Primer Tutorial' href='#ipfgdpt'>Image Pair Fitting into a Given Dimension Primer Tutorial<\/a> would go &#8230;<\/p>\n<ul>\n<li>as well as the wonderful <a target=_blank title='Lorem Picsum' href='https:\/\/picsum.photos'>Lorem Picsum<\/a> resource for beautiful images &#8220;source&#8221; &#8230; we might add &#8230;<\/li>\n<li>new <a target=_blank href=\"https:\/\/www.rjmprogramming.com.au\/ITblog\/\">RJM Programming WordPress Blog<\/a> <font size=1>(that you are probably reading from, now)<\/font> tutorial picture &#8220;source&#8221; of images<\/li>\n<\/ul>\n<p> &#8230; the functionality for which we have been trying to envisage for many years, and seeing the excellent <a target=_blank title='Lorem Picsum' href='https:\/\/picsum.photos'>Lorem Picsum<\/a> arrangements being a catalyst, to give it a go.<\/p>\n<p>Kludgy feeling or not, we are happy to be linking into the &#8220;last talked about&#8221; <a target=_blank href='https:\/\/www.rjmprogramming.com.au\/ITblog\/wordpress-blog-search-within-search-posting-progress-context-tutorial\/' title='WordPress Blog Search Within Search Posting Progress Context Tutorial'>WordPress Blog Search Within Search Posting Progress Context Tutorial<\/a> WordPress &#8220;URL not found&#8221; 404.php code methodologies here, as a great &#8220;intervention point&#8221;.  We often find the biggest joy in web application code modifications is to identify &#8220;code lazy <font size=1>(for us)<\/font>&#8221; &#8220;intervention points&#8221; that mean most of the hard part of the job is done for you, by others (here, that being the great <a target=_blank title='WordPress blog' href='\/\/wordpress.org'>WordPress<\/a> TwentyTen theme <a target=_blank title='WordPress codex' href='https:\/\/codex.wordpress.org\/Main_Page'>&#8220;codex&#8221;<\/a> PHP code helped out by Apache web server <a target=_blank title='Apache .htaccess information' href='https:\/\/httpd.apache.org\/docs\/2.4\/howto\/htaccess.html'>.htaccess<\/a> permalink configurations) before you add your own &#8220;situation specific&#8221; interventional code.<\/p>\n<p>And so, once at 404.php code, we add new global variables and functions &#8230;<\/p>\n<p>&lt;?php<br \/>\n<code><br \/>\n\/\/ WordPress \"codex\" PHP comments precede<br \/>\n<br \/>\n$ioff=0;<br \/>\n$imfnameafterdomainsep=\"random_background_fadeinout.jpg\";<br \/>\n$ptitle=\"Random Background Webpage Fade Tutorial\";<br \/>\n$bonl=\"\";<br \/>\n$tonl=\"\";<br \/>\n<br \/>\nfunction selectNewBlogPostingTutorialPicture() {<br \/>\n  global $imfnameafterdomainsep, $ptitle, $bonl, $tonl;<br \/>\n  $foundipath=\"\";<br \/>\n  $icontis=file_get_contents(explode('ITblog' . DIRECTORY_SEPARATOR, dirname(__FILE__) . DIRECTORY_SEPARATOR)[0] . \"index.html\");<br \/>\n  $ideaarray=explode('&amp;pp=&amp;pn=&amp;title=', $icontis);<br \/>\n  if (sizeof($ideaarray) &gt; 1) {<br \/>\n    while ($foundipath == \"\") {<br \/>\n    $huhrand=rand(2, (-1 + sizeof($ideaarray)));<br \/>\n    $ptis=\"\";<br \/>\n    if (strpos(explode('&gt;', explode('\"', $ideaarray[$huhrand])[0])[0], \"Tutorial\") !== false) {<br \/>\n    $ptis=str_replace('_',' ',explode('Tutorial', explode('&gt;', explode('\"', $ideaarray[$huhrand])[0])[0])[0] . \"Tutorial\");<br \/>\n    }<br \/>\n    $tutdate=\"\";<br \/>\n    if (strpos($ideaarray[-1 + $huhrand], 'MyNew-') !== false) {<br \/>\n       $tdt=substr(explode('MyNew-', $ideaarray[-1 + $huhrand])[-1 + sizeof(explode('MyNew-', $ideaarray[-1 + $huhrand]))],0,8);<br \/>\n       $tutdate=' (' . substr($tdt,6,2) . ' ' . str_replace(\"01\",\"January\",str_replace(\"02\",\"February\",str_replace(\"03\",\"March\",str_replace(\"04\",\"April\",str_replace(\"05\",\"May\",str_replace(\"06\",\"June\",str_replace(\"07\",\"July\",str_replace(\"08\",\"August\",str_replace(\"09\",\"September\",str_replace(\"10\",\"October\",str_replace(\"11\",\"November\",str_replace(\"12\",\"December\",substr($tdt,4,2))))))))))))) . ' ' . substr($tdt,0,4) . ')';<br \/>\n    }<br \/>\n    $pnumis=explode('&', explode('?p=', $ideaarray[-1 + $huhrand]   )[-1 + sizeof(explode('?p=', $ideaarray[-1 + $huhrand]   ))])[0];<br \/>\n    $thisbpc=file_get_contents('HTTP:\/\/www.rjmprogramming.com.au\/ITblog\/?p=' . $pnumis);<br \/>\n    if (strpos($thisbpc, ' class=\"wp-caption') !== false) {<br \/>\n     $thatbpc=explode('\"', explode(' src=\"', explode(' class=\"wp-caption', $thisbpc)[1])[1])[0]; \/\/ www.rjmprogramming.com.au\/PHP\/emoji_animation_css_block.jpg<br \/>\n     if (strpos($thatbpc, \"rjmprogramming.com.au\/\") !== false) {<br \/>\n      if (strpos($thatbpc, \".jp\") !== false || strpos($thatbpc, \".png\") !== false || strpos($thatbpc, \".gif\") !== false) {<br \/>\n       if ($tutdate != \"\" && strpos($ptis, \" Tutorial\") !== false && strpos($ptis, \" (\") === false && strpos($ptis, \"%\") === false && strpos($ptis, \"&\") === false && file_exists(explode('ITblog' . DIRECTORY_SEPARATOR, dirname(__FILE__) . DIRECTORY_SEPARATOR)[0] .   explode(\"rjmprogramming.com.au\/\", $thatbpc)[1]   )) {<br \/>\n        $ptis.=$tutdate;<br \/>\n        $foundipath=explode('ITblog' . DIRECTORY_SEPARATOR, dirname(__FILE__) . DIRECTORY_SEPARATOR)[0] .   explode(\"rjmprogramming.com.au\/\", $thatbpc)[1];<br \/>\n        if ($foundipath != \"\") {<br \/>\n          $imfnameafterdomainsep=explode(\"rjmprogramming.com.au\/\", $thatbpc)[1];<br \/>\n          $ptitle=$ptis;<br \/>\n          $onlme=\"\";<br \/>\n          if (strpos(('' . $_SERVER['QUERY_STRING']), 'andclickme=') !== false) {<br \/>\n            $onlme=' onload=\" window.open(' . \"'\/\/www.rjmprogramming.com.au\/ITblog\/?p=\" . $pnumis . \"','_blank','top=200,left=100,height=700,width=900'); \" . '\" ';<br \/>\n          }<br \/>\n          $bonl=$onlme . ' title=' . \"'\" . 'Click opens relevant blog post called ' . $ptis . ' and double click opens relevant blog post action item' . \"'\" . ' onclick=\" window.open(' . \"'\/\/www.rjmprogramming.com.au\/ITblog\/?p=\" . $pnumis . \"','_blank'); \" . '\" ondblclick=\" window.open(' . \"'\/\/www.rjmprogramming.com.au\/slideshow.html?title=\" . str_replace(urlencode('|'), '%20', urlencode(str_replace(' ','|',$ptis))) . \"','_blank'); \" . '\"';<br \/>\n          $tonl='&lt;head&gt;&lt;title&gt;' . $ptis . '&lt;\/title&gt;&lt;\/head&gt;';<br \/>\n        }<br \/>\n       }<br \/>\n      }<br \/>\n     }<br \/>\n    }<br \/>\n    }<br \/>\n  }<br \/>\n}<br \/>\n<br \/> <br \/>\nfunction createScaledImage($newWidth,$newHeight,$path,$datauri) { \/\/ thanks to <a target=_blank title='https:\/\/stackoverflow.com\/questions\/16774521\/scale-image-using-php-and-maintaining-aspect-ratio' href='https:\/\/stackoverflow.com\/questions\/16774521\/scale-image-using-php-and-maintaining-aspect-ratio'>https:\/\/stackoverflow.com\/questions\/16774521\/scale-image-using-php-and-maintaining-aspect-ratio<\/a><br \/>\n<br \/>\n    $image_name=explode(DIRECTORY_SEPARATOR, $path)[-1 + sizeof(explode(DIRECTORY_SEPARATOR, $path))];<br \/>\n<br \/> <br \/>\n    $mime = getimagesize($path);<br \/>\n<br \/>\n    if ($mime['mime']=='image\/png') {<br \/>\n        $src_img = imagecreatefrompng($path);<br \/>\n    }<br \/>\n    if ($mime['mime']=='image\/jpg' || $mime['mime']=='image\/jpeg' || $mime['mime']=='image\/pjpeg') {<br \/>\n        $src_img = imagecreatefromjpeg($path);<br \/>\n    }<br \/>\n    if ($mime['mime']=='image\/gif') {<br \/>\n        $src_img = imagecreatefromgif($path);<br \/>\n    }<br \/>\n<br \/>\n    $old_x          =   imageSX($src_img);<br \/>\n    $old_y          =   imageSY($src_img);<br \/>\n<br \/>\n    if ($old_x &gt; $old_y) {<br \/>\n        $thumb_w    =   $newWidth;<br \/>\n        $thumb_h    =   $old_y\/$old_x*$newWidth;<br \/>\n    }<br \/>\n<br \/>\n    if ($old_x &lt; $old_y) {<br \/>\n        $thumb_w    =   $old_x\/$old_y*$newHeight;<br \/>\n        $thumb_h    =   $newHeight;<br \/>\n    }<br \/>\n<br \/>\n    if ($old_x == $old_y) {<br \/>\n        $thumb_w    =   $newWidth;<br \/>\n        $thumb_h    =   $newHeight;<br \/>\n    }<br \/>\n<br \/>\n    $dst_img        =   imagecreatetruecolor($thumb_w,$thumb_h);<br \/>\n<br \/>\n    imagecopyresampled($dst_img,$src_img,0,0,0,0,$thumb_w,$thumb_h,$old_x,$old_y);<br \/>\n<br \/>\n    \/\/ New save location<br \/>\n    $new_thumb_loc = '\/tmp\/' . $image_name;<br \/>\n<br \/>\n    if (!$datauri) {<br \/>\n    if($mime['mime']=='image\/png') {<br \/>\n      header('Content-Type: image\/png');<br \/>\n      imagepng($dst_img); \/\/,$new_thumb_loc,8);<br \/>\n    if (file_exists($new_thumb_loc)) {<br \/>\n    unlink($new_thumb_loc);<br \/>\n    }<br \/>\n    imagedestroy($dst_img);<br \/>\n    imagedestroy($src_img);<br \/>\n      exit;<br \/>\n    } else if ($mime['mime']=='image\/jpg' || $mime['mime']=='image\/jpeg' || $mime['mime']=='image\/pjpeg') {<br \/>\n      header('Content-Type: image\/jpeg');<br \/>\n      imagejpeg($dst_img); \/\/,$new_thumb_loc,80);<br \/>\n    if (file_exists($new_thumb_loc)) {<br \/>\n    unlink($new_thumb_loc);<br \/>\n    }<br \/>\n    imagedestroy($dst_img);<br \/>\n    imagedestroy($src_img);<br \/>\n      exit;<br \/>\n    } else if ($mime['mime']=='image\/gif') {<br \/>\n      header('Content-Type: image\/gif');<br \/>\n      imagegif($dst_img); \/\/,$new_thumb_loc,80);<br \/>\n    if (file_exists($new_thumb_loc)) {<br \/>\n    unlink($new_thumb_loc);<br \/>\n    }<br \/>\n    imagedestroy($dst_img);<br \/>\n    imagedestroy($src_img);<br \/>\n      exit;<br \/>\n    }<br \/>\n    exit;<br \/>\n    }<br \/>\n<br \/>\n    $result=\"\";<br \/>\n    if ($mime['mime']=='image\/png') {<br \/>\n        imagepng($dst_img,$new_thumb_loc,8);<br \/>\n        $result = file_get_contents($new_thumb_loc);<br \/>\n    }<br \/>\n    if ($mime['mime']=='image\/jpg' || $mime['mime']=='image\/jpeg' || $mime['mime']=='image\/pjpeg') {<br \/>\n        imagejpeg($dst_img,$new_thumb_loc,80);<br \/>\n        $result = file_get_contents($new_thumb_loc);<br \/>\n    }<br \/>\n    if ($mime['mime']=='image\/gif') {<br \/>\n        imagegif($dst_img,$new_thumb_loc);<br \/>\n        $result = file_get_contents($new_thumb_loc);<br \/>\n    }<br \/>\n<br \/>\n    imagedestroy($dst_img);<br \/>\n    imagedestroy($src_img);<br \/>\n<br \/> <br \/>\n    if (file_exists($new_thumb_loc)) {<br \/>\n    unlink($new_thumb_loc);<br \/>\n    }<br \/>\n<br \/>\n    return $result;<br \/>\n}<br \/>\n<\/code><br \/>\n?&gt;<\/p>\n<p> &#8230; called within <font color=blue>&#8220;new if section URL analysis code&#8221;<\/font> &#8230;<\/p>\n<p>&lt;?php<br \/>\n<code><br \/>\n$uparts=explode(\"\/\", $_SERVER['REQUEST_URI']);<br \/>\nif (sizeof($uparts) >= 2) {<br \/>\n  <font color=blue>if (trim(explode('#',explode('?',$uparts[-1 + sizeof($uparts)])[0])[0]) == '') {<br \/>\n    $ioff=-1;<br \/>\n  }<\/font><br \/>\n  if (1 == 1 || ('' . $_SERVER['QUERY_STRING']) == '') {<br \/>\n    $usz=sizeof($uparts);<br \/>\n    if (str_replace('?' . $_SERVER['QUERY_STRING'],'',trim($uparts[-1 + sizeof($uparts)])) == '') { $usz--; }<br \/>\n    if ($usz == 3 && strpos($uparts[-1 + $usz], \"%20\") !== false || strpos($uparts[-1 + $usz], \"+\") !== false) { \/\/ fix \/ITblog\/Linux%20mailx%20Primer%20Tutorial\/ 18\/1\/2022 RM<br \/>\n     if (('' . $_SERVER['QUERY_STRING']) == '') {<br \/>\n       header('Location: ' . str_replace('~``','\/ITblog\/',str_replace('\/','',str_replace('\/ITBLOG\/','~``',str_replace('\/itblog\/','~``',str_replace('\/ITblog\/','~``',str_replace('--','-',str_replace('---','-',str_replace('+','-',str_replace('%20','-',$_SERVER['REQUEST_URI']))))))))));<br \/>\n     } else {<br \/>\n       header('Location: ' . explode('?',str_replace('~``','\/ITblog\/',str_replace('\/','',str_replace('\/ITBLOG\/','~``',str_replace('\/itblog\/','~``',str_replace('\/ITblog\/','~``',str_replace('--','-',str_replace('---','-',str_replace('+','-',str_replace('%20','-',$_SERVER['REQUEST_URI']))))))))))[0] . '?' . $_SERVER['QUERY_STRING']);<br \/>\n     }<br \/>\n     exit;<br \/>\n    }<br \/>\n  }<br \/>\n  if (str_replace(\"category\",\"cat\",strtolower($uparts[-2 + sizeof($uparts)])) == \"cat\" || strtolower($uparts[-2 + sizeof($uparts)]) == \"category\") {<br \/>\n    $catsare=[\"\",\"Not Categorised\",\"Ajax\",\"Android\",\"Animation\",\"Anything You Like\",\"Code::Blocks\",\"Colour Matching\",\"Data Integration\",\"Database\",\"Delphi\",\"Eclipse\",\"eLearning\",\"ESL\",\"Event-Driven Programming\",\"Games\",\"GIMP\",\"GUI\",\"Hradware\",\"Installers\",\"iOS\",\"Land Surveying\",\"Moodle\",\"Music Poll\",\"NetBeans\",\"Networking\",\"News\",\"ontop\",\"OOP\",\"Operating System\",\"Photography\",\"Projects\",\"Signage Poll\",\"Software\",\"SpectroPhotometer\",\"Tiki Wiki\",\"Trips\",\"Tutorials\",\"Uncategorized\",\"Visual Studio\",\"Xcode\"];<br \/>\n    for ($ibh=1; $ibh&lt;sizeof($catsare); $ibh++) {<br \/>\n      if (explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0] == strtolower($catsare[$ibh])) {<br \/>\n        if (strtolower($catsare[$ibh]) == \"ontop\") {<br \/>\n          header('Location: https:\/\/www.rjmprogramming.com.au\/ITblog\/category\/' . str_replace(\" \",\"-\",explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0])) . '#' . $ibh;<br \/>\n        } else {<br \/>\n          header('Location: https:\/\/www.rjmprogramming.com.au\/ITblog\/category\/' . str_replace(\" \",\"-\",explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0])) . '#' . $ibh;<br \/>\n        }<br \/>\n      } else if (explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0] == ('' . $ibh)) {<br \/>\n        if (strtolower($catsare[$ibh]) == \"ontop\") {<br \/>\n          header('Location: https:\/\/www.rjmprogramming.com.au\/ITblog\/?cat=' . str_replace(\" \",\"-\",explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0])) . '#' . $ibh;<br \/>\n        } else {<br \/>\n          header('Location: https:\/\/www.rjmprogramming.com.au\/ITblog\/?cat=' . str_replace(\" \",\"-\",explode(\"&\",strtolower($uparts[-1 + sizeof($uparts)]))[0])) . '#' . $ibh;<br \/>\n        }<br \/>\n      }<br \/>\n    }<br \/>\n  } <font color=blue>else if (substr(trim($uparts[$ioff - 1 + sizeof($uparts)]) . ' ',0,1) &gt;= '0' && substr(trim($uparts[$ioff - 1 + sizeof($uparts)]) . ' ',0,1) &lt;= '9') {<br \/>\n    if (substr(trim($uparts[$ioff - 2 + sizeof($uparts)]) . ' ',0,1) &gt;= '0' && substr(trim($uparts[$ioff - 2 + sizeof($uparts)]) . ' ',0,1) &lt;= '9') {<br \/>\n      $uwidth=trim($uparts[$ioff - 2 + sizeof($uparts)]);<br \/>\n      $uheight=trim(explode('#',explode('?',$uparts[$ioff - 1 + sizeof($uparts)])[0])[0]);<br \/>\n      $imfnameafterdomainsep=\"random_background_fadeinout.jpg\";<br \/>\n      $ptitle=\"Random Background Webpage Fade Tutorial\";<br \/>\n      selectNewBlogPostingTutorialPicture();<br \/>\n      $postingiurl=explode('ITblog' . DIRECTORY_SEPARATOR, dirname(__FILE__) . DIRECTORY_SEPARATOR)[0] . $imfnameafterdomainsep;<br \/>\n      list($iwidth, $iheight, $itype, $iattr) = getimagesize($postingiurl);<br \/>\n      $amime = getimagesize($postingiurl);<br \/>\n      if ($ioff == 0) {<br \/>\n      echo \"&lt;html&gt;\" . $tonl . \"&lt;body\" . $bonl . \"&gt;&lt;pre&gt;data:image\/jpeg;base64,\" . base64_encode(createScaledImage($uwidth,$uheight,$postingiurl,true)) . \"#\" . str_replace('+','%20',urlencode($ptitle)) . \"&lt;\/pre&gt;&lt;\/body&gt;&lt;\/html&gt;\";<br \/>\n      } else if (1 == 2) {<br \/>\n      echo '&lt;img src=\"' . \"data:image\/jpeg;base64,\" . base64_encode(file_get_contents($postingiurl)) . \"#\" . str_replace('+','%20',urlencode($ptitle)) . '\"&gt;&lt;\/img&gt;';<br \/>\n      } else {<br \/>\n      createScaledImage($uwidth,$uheight,$postingiurl,false); \/\/imagecreatefromjpeg($postingiurl);<br \/>\n      }<br \/>\n      exit;<br \/>\n    }<br \/>\n  }<br \/>\n}<\/font><br \/>\n<br \/>\nget_header(); ?&gt;<br \/>\n<br \/>\n\/\/ more WordPress \"codex\" PHP code follows<br \/>\n<\/code><br \/>\n?&gt;<\/p>\n<p> &#8230; that amount to changes which enable two types of newly functional URLs that, without the changes, used to result in a WordPress webpage explaining that the URL could not be found &#8230;<\/p>\n<ol>\n<li>a URL such as <a target=_blank title='https:\/\/www.rjmprogramming.com.au\/ITblog\/537\/500' href='https:\/\/www.rjmprogramming.com.au\/ITblog\/537\/500'>https:\/\/www.rjmprogramming.com.au\/ITblog\/537\/500<\/a> will pick a random RJM Programming Blog tutorial picture and show &#8230;<br \/>\n<code><br \/>\n[image data URI of tutorial picture]#[blog posting title]<br \/>\n<\/code><br \/>\n &#8230; along with the happy discovery along the way that the &#8220;#[blog posting title]&#8221; can be tagged onto a base64 data URI and still successfully display the image\n<\/li>\n<li>whereas a URL such as <a target=_blank title='https:\/\/www.rjmprogramming.com.au\/ITblog\/537\/500\/' href='https:\/\/www.rjmprogramming.com.au\/ITblog\/537\/500\/'>https:\/\/www.rjmprogramming.com.au\/ITblog\/537\/500\/<\/a> will pick a random RJM Programming Blog tutorial picture and show it<\/li>\n<\/ol>\n<p> &#8230; the combination allowing <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/PHP\/Geographicals\/diff.php?one=http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.html-GETME\">our changed<\/a> <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.html-GETME\">proof of concept<\/a> <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.htm\">CSS (styling) &#8220;object-fit&#8221; experimenting web application<\/a> to be now allowing for two sources of image data which the user can select between, themselves, with the RJM Programming WordPress Blog images also containing clickable links back to the WordPress Blog post of relevance.  You can also try this <a title='Iframe usage' href='#myifagd'>here<\/a>.<\/p>\n<p><b><i>Stop Press<\/i><\/b><\/p>\n<p>And then there is some optional filtering of RJM Programming blog image topic, as we make happen with <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/PHP\/Geographicals\/diff.php?one=http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.html--GETME\">our changed<\/a> <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.html--GETME\">proof of concept<\/a> <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.htm\">CSS (styling) &#8220;object-fit&#8221; experimenting web application<\/a>.<\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=_blank  href='\/\/www.rjmprogramming.com.au\/ITblog\/image-pair-fitting-into-a-given-dimension-sources-tutorial\/'>Image Pair Fitting into a Given Dimension Sources Tutorial<\/a>.<\/p-->\n<hr>\n<p id='ipfgdpt'>Previous relevant <a target=_blank title='Image Pair Fitting into a Given Dimension Primer Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/image-pair-fitting-into-a-given-dimension-primer-tutorial\/'>Image Pair Fitting into a Given Dimension Primer Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.html\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Image Pair Fitting into a Given Dimension Primer Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.jpg\" title=\"Image Pair Fitting into a Given Dimension Primer Tutorial\"  style=\"float:left;\" \/><\/a><p class=\"wp-caption-text\">Image Pair Fitting into a Given Dimension Primer Tutorial<\/p><\/div>\n<p>One of the most &#8220;catered for&#8221; part of webpage design involves the display of images.  Our recent &#8220;stumbling upon&#8221; &#8230;<\/p>\n<ul>\n<li>the excellent <a target=_blank title='Lorem Picsum' href='https:\/\/picsum.photos'>Lorem Picsum<\/a> resource for beautiful images suiting a given width x height &#8230; had us looking around for an interesting image related theme to &#8220;tutorialize&#8221; and &#8220;stumbled upon&#8221; &#8230;<\/li>\n<li>the excellent <a target=_blank title='CSS object-fit Property' href='https:\/\/www.w3schools.com\/css\/css3_object-fit.asp'>CSS object-fit Property<\/a> explanation of CSS &#8220;object-fit&#8221; property &#8230;<\/li>\n<\/ul>\n<p> &#8230; facilitating the interest in the scenario &#8230;<\/p>\n<ul>\n<li>you are presented with &#8220;webpage real estate&#8221; of a given width x height &#8230; into which &#8230;<\/li>\n<li>you want to display two images side by side &#8230;<\/li>\n<\/ul>\n<p> &#8230; and in this scenario the use of &#8220;object-fit&#8221; property values &#8230;<\/p>\n<blockquote cite='https:\/\/www.w3schools.com\/css\/css3_object-fit.asp'><p>\nHere is where the object-fit property comes in. The object-fit property can take one of the following values:<br \/>\n<br \/>\nfill &#8211; This is default. The image is resized to fill the given dimension. If necessary, the image will be stretched or squished to fit<br \/>\ncontain &#8211; The image keeps its aspect ratio, but is resized to fit within the given dimension<br \/>\ncover &#8211; The image keeps its aspect ratio and fills the given dimension. The image will be clipped to fit<br \/>\nnone &#8211; The image is not resized<br \/>\nscale-down &#8211; the image is scaled down to the smallest version of none or contain\n<\/p><\/blockquote>\n<p> &#8230; creates interesting variety in how you can configure this scenario depending on your (constraint) interest in &#8230;<\/p>\n<ul>\n<li>you are constrained by fact you must see all the image&#8217;s content in original <a target=_blank title='Aspect ratio information from Wikipedia ... thanks' href='https:\/\/en.wikipedia.org\/wiki\/Aspect_ratio_(image)'>aspect ratio<\/a> &#8230; think &#8230; contain or scale-down<\/li>\n<li>you are constrained by fact you must see all the image&#8217;s content but not necessarily with original aspect ratio &#8230; think &#8230; fill or contain or scale-down<\/li>\n<li>you are constrained by fact that your &#8220;webpage real estate&#8221; of the given width x height must be filled (by image<font size=1>ry<\/font>) &#8230; think &#8230; fill or cover (or <font size=1>(quite often, but not always)<\/font> none)<\/li>\n<li>you must keep original image dimensions but clipping okay &#8230; think &#8230; none<\/li>\n<li>you must keep original aspect ratio of images but clipping okay &#8230; think &#8230; contain or cover or none or scale-down<\/li>\n<\/ul>\n<p> &#8230; and then there is &#8230;<\/p>\n<blockquote><p>\nWhat happens when you resize your webpage window?\n<\/p><\/blockquote>\n<p>Feel free to try our <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.html_GETME\">proof of concept<\/a> <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.html\">CSS (styling) &#8220;object-fit&#8221; experimenting web application<\/a> &#8230;<\/p>\n<p><iframe id=myifagd src=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/images_fitting_a_given_dimension.html\" style=\"width:100%;height:800px;\"><\/iframe><\/p>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d55687' onclick='var dv=document.getElementById(\"d55687\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/resize\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d55687' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d55703' onclick='var dv=document.getElementById(\"d55703\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/wordpress\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d55703' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d55796' onclick='var dv=document.getElementById(\"d55796\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/404.php\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d55796' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d55957' onclick='var dv=document.getElementById(\"d55957\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/date\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d55957' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d55961' onclick='var dv=document.getElementById(\"d55961\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/hotkey\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d55961' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d55991' onclick='var dv=document.getElementById(\"d55991\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/regexp\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d55991' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Yesterday&#8217;s Landing Page Autocompletion Blog Finds Tutorial needed work &#8230; tweaking for user driven RegExp (via Javascript) blog post finding from the RJM Programming Landing Pages, the old top codeline relying on string matching string length, a concept that does &hellip; <a href=\"https:\/\/www.rjmprogramming.com.au\/ITblog\/landing-page-autocompletion-blog-regexp-finds-tutorial\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12,14,37],"tags":[1695,274,354,367,400,432,573,576,652,673,2097,680,1705,997,2226,1866,1200,1675,1319,1411,1452,1622],"class_list":["post-55991","post","type-post","status-publish","format-standard","hentry","category-elearning","category-event-driven-programming","category-tutorials","tag-autocompletion","tag-crontab","tag-dom","tag-dropdown","tag-event","tag-filtering","tag-hotkey","tag-html","tag-javascript","tag-keyboard","tag-keystroke","tag-landing-page","tag-onkeydown","tag-programming","tag-regexp","tag-select","tag-stop-press","tag-textbox","tag-tutorial","tag-web-server","tag-word","tag-words"],"_links":{"self":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/55991"}],"collection":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/comments?post=55991"}],"version-history":[{"count":9,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/55991\/revisions"}],"predecessor-version":[{"id":56042,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/55991\/revisions\/56042"}],"wp:attachment":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/media?parent=55991"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/categories?post=55991"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/tags?post=55991"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}