Numbers Guessing Game
Your Numbers Game
Get
clueYour
answerYour
ScoreClue? Score 0/0
-
Recent Posts
- PHP Exif Quiz Geographicals Tutorial
- PHP Exif Quiz Tutorial
- PHP Exif Retention off iPhone Images Tutorial
- List to Grid Layout CSS Media Query Tutorial
- List to Grid Layout Primer Tutorial
- Out and About WordPress Blog Content Tweaks Just with iPhone Tutorial
- Command Line History By Date Tutorial
- Overseas Travel Global Roaming Mobile Primer Tutorial
Categories
- Ajax
- Android
- Animation
- Anything You Like
- Code::Blocks
- Coding
- Colour Matching
- Data Integration
- Database
- Delphi
- Eclipse
- eLearning
- ESL
- Event-Driven Programming
- Games
- GIMP
- GUI
- Hardware
- Installers
- iOS
- Land Surveying
- Moodle
- Music Poll
- NetBeans
- Networking
- News
- Not Categorised
- OOP
- Operating System
- Photography
- Projects
- Signage Poll
- Software
- SpectroPhotometer
- Tiki Wiki
- Trips
- Tutorials
- Uncategorized
- Visual Studio
- Xcode
Meta
Tags
Ajax animation background button canvas command line CSS Did you know DOM dropdown email emoji event form game Google Google chart hashtag HTML IFRAME image iOS Javascript MAMP media mobile navigation onclick overlay PHP popup programming select share sharing SMS SVG table text textarea tutorial url video web browser webpageYour Background Image
OnTopList
Tag Archives: onmouseover
WordPress Calendar Widget Table Cell Tutorial Image Background Tutorial
The recently increased role for our Word Press Blog 404.php (initially envisaged by WordPress codex as the PHP to address HTTP error 404 “Page Not Found”) has opened the door to many more uses. And thanks here to Lorem Picsum regarding a good role model here. Today’s idea, best suited to non-mobile users (but can work more awkwardly on mobile) is to respond for a mobile hovering over our TwentyTen themed WordPress Blog’s Calendar widget, specifically the active “a” links within “td” table cells, and render a background image into that cell that corresponds to that date’s tutorial picture. In order to achieve this we revisit the “function calendar_pass” Javascript function, within (good ol’) header.php, featuring in Calendar iCal Integration WordPress Tutorial up near the top … <?php echo ” function calendar_pass() { var thisc=”, thiscc=”, thist=”, jiicp=0, thisdate=”, thistime=”, nexttime=”, thishour=0, nexthour=0, thisminute=”, thissecond=’00’, thisurl=”; var h1cps=docgetclass(‘entry-title’,’*’); //document.getElementsByTagName(‘h2’); var tdzs=document.getElementsByTagName(‘td’), itdzs=0; var cps=document.getElementsByTagName(‘a’); var mfnd=false;; for (var ijcal=0; ijcal<cps.length; ijcal++) { // new calendar links background image if (eval(” + (” + cps[ijcal].href).split(‘/’).length) == 8) { if (eval(” + (” + cps[ijcal].href).split(‘/’)[4].length) == 4) { mfnd=false; for (itdzs=0; itdzs<tdzs.length; itdzs++) { if (tdzs[itdzs].innerHTML == cps[ijcal].outerHTML) { tdzs[itdzs].className=cps[ijcal].title.replace(/\ /g,’_’); tdzs[itdzs].onclick=function(evt){ window.open(‘//www.rjmprogramming.com.au/ITblog/’ + evt.target.innerHTML.split(‘ title=”‘)[1].split(‘”‘)[0].toLowerCase().replace(String.fromCharCode(35), “”).replace(“.”, “”).replace(“.”, “”).replace(“.”, “”).replace(“+”, “”).replace(“+”, “”).replace(“‘”, “”).replace(‘%27’,”).replace(/\//g, “”).replace(/,/g, “”).replace(“—“,”-“).replace(“—“,”-“).replace(/–/g,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“).replace(” “,”-“), ‘_blank’, ‘top=50,left=50,width=1200,height=900’); }; mfnd=true; } } if (!mfnd) { cps[ijcal].onmouseover=function(evt){ var pbs=(” + evt.target.href).split(‘/’); if (document.head.innerHTML.indexOf(‘[title=’ + “‘” + evt.target.title + “‘” + ‘]’) == -1) { document.head.innerHTML+=’ <style> [title=’ + “‘” + evt.target.title + “‘” + ‘] { ‘ + ‘ background:url(//www.rjmprogramming.com.au/ITblog/500/500/?random=178654345&mustbedated=’ + pbs[4] + pbs[5] + pbs[6] + ‘) center center no-repeat; background-size:cover; } </style> ‘; } }; } else { cps[ijcal].onmouseover=function(evt){ var pbs=(” + evt.target.href).split(‘/’); if (document.head.innerHTML.indexOf(‘ .’ + evt.target.title.replace(/\ /g,’_’) + ‘ {‘) == -1) { document.head.innerHTML+=’ <style> .’ + evt.target.title.replace(/\ /g,’_’) + ‘ { ‘ + ‘ background:url(//www.rjmprogramming.com.au/ITblog/500/500/?random=178654345&mustbedated=’ + pbs[4] + pbs[5] + pbs[6] + ‘) center center no-repeat !important; background-size:cover; } </style> ‘; } }; } } } } // Rest of calendar_pass as in Calendar iCal Integration WordPress Tutorial below … } “; ?> … in the process … in a first pass adding a classname to those relevant “td” table cells … in same first pass adding an “onmouseover” (ie. hover) event to the relevant “a” link, that when the user hovers, appends to the document “head” some CSS styling that adds the tutorial picture image as the “td” background image and helped out by that “td” table cell classname … in same first pass adding an “onclick” event to the relevant “td” table cell, that when the user clicks the “td” cell, opens the relevant blog posting webpage in a popup window … … helping, a little, previewing a calendar date’s content ahead of navigating to that content. Previous relevant Calendar iCal Integration WordPress … Continue reading
Posted in eLearning, Event-Driven Programming, Tutorials
Tagged background, background image, calendar, callback, cell, date, datetime, DOM, dropdown, email, emoji, event, form, Google Charts, header, hover, HTML, ical, interval, Javascript, link, onclick, onmouseover, PHP, programming, software integration, time, timezone, tutorial, TwentyTen, TwentyTen theme, UIWebView, WebView, Wordpress
Leave a comment
Landing Page Linked Background Images Long Hover Tutorial
Yesterday’s Landing Page Linked Background Images Tutorial introduced linked background (thumbnail) image “onclick” event logic. Today, we extend, rather than impinge in any way, by adding “long hover” linked background (thumbnail) image functionality, which bases itself on a “short hover + delayed logic” paradigm (via the non-mobile “onmouseover” (or hover) and “onmouseout” events) … var bodyrect=null, lastrid=”; function omstill() { var brect=null; if (lastrid != ”) { var alastrid=lastrid.replace(‘e’,’a’); if ((” + document.getElementById(‘tblr’).style.display).toLowerCase().indexOf(‘none’) == 0) { brect=document.body.getBoundingClientRect(); document.getElementById(‘tblr’).style.position=’absolute’; document.getElementById(‘tblr’).style.left=” + bodyrect.right + ‘px’; document.getElementById(‘tblr’).style.top=’0px’; document.getElementById(‘tblr’).style.height=” + brect.height + ‘px’; document.getElementById(‘tblr’).style.display=’block’; } if (document.getElementById(‘if’ + lastrid)) { document.getElementById(alastrid).target=’if’ + lastrid; document.getElementById(‘if’ + lastrid).src=document.getElementById(alastrid).href; } else if (document.getElementById(” + lastrid)) { if (!brect) { brect=document.getElementById(‘tblr’).getBoundingClientRect(); } document.getElementById(alastrid).target=’if’ + lastrid; document.getElementById(” + lastrid).innerHTML='<iframe style=”width:’ + bodyrect.right + ‘px;’ + ‘height:’ + brect.height + ‘px;” id=if’ + lastrid + ‘ name=if’ + lastrid + ‘ src=”‘ + document.getElementById(alastrid).href + ‘”></iframe>’; } lastrid=”; } } function omright(aois) { lastrid=aois.id.replace(‘a’,’e’); if ((” + aois.title) != ” && (” + aois.title).indexOf(‘ong hover’) == -1) { aois.title+=’ Long hover of 7 seconds on thumbnails opens iframes to right.’; } if ((” + document.getElementById(‘style_3’).title) != ” && (” + document.getElementById(‘style_3’).title).indexOf(‘ong hover’) == -1) { document.getElementById(‘style_3′).title+=’ Long hover of 7 seconds on thumbnails opens iframes to right.’; } setTimeout(omstill, 7000); } function moright(aois) { lastrid=”; } … allowing blog posts to be presented in iframe elements off to the right within the one webpage way of amending … function noandmaybe(iois) { var aconto=null, jps=[]; if (!navigator.userAgent.match(/Android|BlackBerry|iPhone|iPod|Opera Mini|IEMobile/i)) { // it is a mobile device if (iois != null) { aconto = (iois.contentWindow || iois.contentDocument); if (aconto != null) { if (aconto.document) { aconto = aconto.document; } if (aconto.body != null) { aconto.body.innerHTML=aconto.body.innerHTML.replace(/\#andabit\=\-70/g,”); } } } } if (document.getElementById(‘style_3’) && (” + document.getElementById(‘style_3′).title) == ”) { if (!aconto) { aconto = (iois.contentWindow || iois.contentDocument); if (aconto != null) { if (aconto.document) { aconto = aconto.document; } } } var omover=’ onmouseover=”omright(this);” ‘, omout=’ onmouseout=”moright(this);” ‘, bdapp='<table id=tblr style=display:none><tr></tr></table>’; var rdbit=’?rand=’ + Math.floor(Math.random() * 1985676); if (aconto) { if (aconto.body != null) { if (document.getElementById(‘p_style_3’)) { document.getElementById(‘style_3’).innerHTML=document.getElementById(‘p_style_3’).outerHTML.replace(/\.jpg/g, ‘.jpg’ + rdbit); } var hrefs=aconto.body.innerHTML.split(‘ href=’); var style_3r=document.getElementById(‘style_3’).getBoundingClientRect(); document.getElementById(‘style_3′).title=’Feel free to visit thumbnail links to our WordPress Tutorial blog!’; for (var ihrefs=1; ihrefs<hrefs.length; ihrefs++) { //document.body.innerHTML+='<div id=ediv’ + ihrefs + ‘></div>’; bdapp=bdapp.replace(‘</tr>’, ‘<td id=ediv’ + ihrefs + ‘></td></tr>’); jps=hrefs[ihrefs].split(‘.jpeg?rand=’); console.log(jps[0].slice(-9)); if (jps[0].slice(-3).indexOf(‘-‘) != -1) { jps[0]=jps[0].split(‘-‘)[eval(-2 + eval(” + jps[0].split(‘-‘).length))]; } switch (jps[0].slice(-3)) { case ‘ght’: document.body.innerHTML+='<a id=adiv5′ + omover + omout + ‘ target=_blank style=”opacity:0.5;background-repeat:no-repeat;background-size:30px 20px;background-image:url(/PHP/eight.jpg’ + rdbit + ‘);position:absolute;z-index:99;top:’ + style_3r.top + ‘px;width:30px;height:20px;background-color:transparent;left:’ + style_3r.left + ‘px;” title=”‘ + hrefs[ihrefs].substring(1).split(‘ title=’)[1].substring(1).split(hrefs[ihrefs].substring(0,1))[0] + ‘” href=”‘ + hrefs[ihrefs].substring(1).split(hrefs[ihrefs].substring(0,1))[0] + ‘”></a>’; break; case ‘ven’: document.body.innerHTML+='<a id=adiv4′ + omover + omout + ‘ target=_blank style=”opacity:0.5;background-repeat:no-repeat;background-size:30px 20px;background-image:url(/PHP/seven.jpg’ + rdbit + ‘);position:absolute;z-index:99;top:’ + style_3r.top + ‘px;width:30px;height:20px;background-color:transparent;left:’ + eval(eval(eval(style_3r.left + style_3r.right) / 2) – 15) + ‘px;” title=”‘ + hrefs[ihrefs].substring(1).split(‘ title=’)[1].substring(1).split(hrefs[ihrefs].substring(0,1))[0] + ‘” href=”‘ + hrefs[ihrefs].substring(1).split(hrefs[ihrefs].substring(0,1))[0] + ‘”></a>’; break; … Continue reading
Posted in eLearning, Event-Driven Programming, Tutorials
Tagged background, background image, background-position, CSS, delay, event, hover, HTML, IFRAME, image, Javascript, linear gradient, link, long hover, onclick, onmouseout, onmouseover, programming, setTimeout, thumbnail, tutorial
Leave a comment


Thanks. Since then, a Shower Songs project at https://www.rjmprogramming.com.au/HTMLCSS/shower_songs.html is an improvement regarding "Radio Play" on mobile platforms.