[Solved] Displaying random images on websites [closed]

you can’t randomized image with html , you have to use java script or css5 try this window.onload = choosePic; var myPix = new Array(“images/lion.jpg”,”images/tiger.jpg”,”images/bear.jpg”); function choosePic() { randomNum = Math.floor((Math.random() * myPix.length)); document.getElementById(“myPicture”).src = myPix[randomNum]; } solved Displaying random images on websites [closed]

[Solved] What has the best cross-browser support, JQuery dialogs or HTML5 modal dialogs? [closed]

Sounds like maybe jQuery UI’s Dialogs are what you’re looking for? All you do is set aside some HTML in a container (such as a Div) and then render the dialog box. Link: https://jqueryui.com/dialog/ To “create” the dialog, you’ll just need to create a dialog from the container whenever you need it to be visible. … Read more

[Solved] converting html to image not working [closed]

You have unwanted chars before <?. remove all blank lines and spaces before <? your image is otherwise correct. <? must be the first character first line in your script. you can avoid ?> if you use it it must be the last line last chars. solved converting html to image not working [closed]

[Solved] ie8 with anchor causes crash [closed]

The problem is the href: assortiment.php#top is asking too much. IE8 can’t deal with a link to an element that doesn’t exist yet (the relative anchor is linking to an element on the new page). JS can solve this problem for you, though: window.onload = function() { if (location.href.indexOf(‘#top’) === -1) { location.href += ‘#top’; … Read more

[Solved] css background size zooming? [closed]

css: html, body { height: 100%; width: 100%; padding: 0; margin: 0; } #full-screen-background-image { z-index: -999; min-height: 100%; min-width: 1024px; width: 100%; height: auto; position: fixed; top: 0; left: 0; } #wrapper { position: relative; width: 800px; min-height: 400px; margin: 100px auto; color: #333; } HTML: <body> <img alt=”full screen background image” src=”https://stackoverflow.com/background.jpg” id=”full-screen-background-image” … Read more

[Solved] Javascript uncaught syntaxerror unexpected identifier error

In this line htmlStr += ‘<a id=”searchResult’+i+'” href=”https://stackoverflow.com/questions/29555599/javascript:liveSearch(“+arrOfSuggestText[i]+’)” > ‘+arrOfSuggestText[i]+'</a>’; and concrete here ‘” href=”https://stackoverflow.com/questions/29555599/javascript:liveSearch(“+arrOfSuggestText[i]+’)” > ‘ you try create calling function, but if you see value of this string, for arrOfSuggestText[i] == ‘qwe’ you can see something like href=”https://stackoverflow.com/questions/29555599/javascript:liveSearch(qwe)” and browser raise error what you get on qwe. So you need just add quotes … Read more

[Solved] How to create checkbox looks like font-awesome glyphicon

You can do achieve this even without Javascript. #checkbox{ background:#2f8cab; display:inline-block; padding:15px 18px; border-radius:2px; position:relative; cursor:pointer; } #checkbox-element{ display:block; position:absolute; left:0; top:0; width:100%; height:100%; z-index:99999; opacity:0; } #checkbox>input[type=”checkbox”]+i{ color:rgba(255,255,255,0.2); // color 1 } #checkbox>input[type=”checkbox”]:checked+i{ color:#fff; //color 2 } And here’s the markup, <span id=”checkbox”> <input id=”checkbox-element” type=”checkbox”/> <i class=”glyphicon glyphicon-check”></i> </span> Have a look at … Read more

[Solved] How to get results from php to html option?

I don’t really understand what you mean. But did you mean something like this: <html> <body> <select> <?php $root = realpath($_SERVER[“DOCUMENT_ROOT”]); include “$root/config.php”; $something1 = “something1”; $something2 = “something2”; $stmt = $pdo->prepare(‘SELECT DISTINCT from_mysql FROM customers WHERE something1 = :something1 AND from_mysql != :something2 ORDER BY from_mysql’); $stmt->execute(array(‘:something1’ => $something1, ‘:something2’ => $something2)); $results = … Read more

[Solved] How to change audio tag when I click on radio button?

Updated: <!DOCTYPE html> <html> <head> <title>Events</title> </head> <body> <input type=”radio” value=”test2″ name=”rad” onclick=”boom(this.value);”>test2 <input type=”radio” value=”test3″ name=”rad” onclick=”boom(this.value);”>test3 <input type=”radio” value=”test4″ name=”rad” onclick=”boom(this.value);”>test4 <br> <audio id=”audio” controls> <source src=”” type=”audio/ogg”> <source src=”” type=”audio/mpeg”> <source src=”https://stackoverflow.com/questions/37552235/test1.wav” type=”audio/wav” id=”sound”> </audio> <script type=”text/javascript”> function boom(val){ var audio = document.getElementById(“audio”); var aud = document.getElementById(“sound”); aud.src=val+”.wav”; audio.load(); } </script> </body> … Read more