[Solved] php How to save post and save show to php file like this [closed]

Without knowing your full requirements, this should get you started. I imagine you are going to want to store the saved/changed text into a database. If this is the case, you need to build upon what is provided below. Hope this helps. Enter Text Here… <?php if( isset( $_POST[‘my_text’], $_POST[‘save’] ) && strlen( $_POST[‘my_text’] ) … Read more

[Solved] How to create an highlight animation when a control gets focused [closed]

I could do it myself!!! First you have to draw the four cornerĀ“s highlights on HTML: <img id=”clt” src=”https://stackoverflow.com/questions/17506028/img/clt.png” border=”0″ style=”position:absolute;visibility:hidden”></span> <img id=”crt” src=”img/crt.png” border=”0″ style=”position:absolute;visibility:hidden”></span> <img id=”crb” src=”img/crb.png” border=”0″ style=”position:absolute;visibility:hidden”></span> <img id=”clb” src=”img/clb.png” border=”0″ style=”position:absolute;visibility:hidden”></span> After, create a JavaScript function: function getFocusFunct(){ $(“input[type=text], input[type=password], textarea”).focus(function(){ var ctl=$(this); var offset=ctl.offset(); var clt=$(“#clt”); var crt=$(“#crt”); var … Read more

[Solved] jQuery add html content in hidden div [closed]

You can use jQuery’s hide() and show() function to accomplish this, which is a little cleaner than the .css() ZeJur used. Have a look at my Plunker example Example: <div class=”hiddenContent”>I am hidden div</div> <button class=”addDynamicContent”>Add dynamic content to div – hide while doing</button> Script: <script> $(‘.addDynamicContent’).click(function() { $.ajax({ url: “http://api.icndb.com/jokes/random”, beforeSend: function() { $(‘.hiddenContent’).hide(); … Read more

[Solved] javascript and json object [closed]

Here’s how you could do it: var json = ‘[{“curUrl”:”acme.com”, “nextUrl”:”acme2.com”, “relation”:”none”},{“curUrl”:”acme3.com”, “nextUrl”:”acme4.com”, “relation”:”none”},{“curUrl”:”acme5.com”, “nextUrl”:”acme6.com”, “relation”:”none”}]’; var arrCurUrls = new Array(); function getCurUrls(){ var parsedJSON = JSON.parse(json); for(var i=0; i<parsedJSON.length; i++){ arrCurUrls.push(parsedJSON[i][‘curUrl’]); } alert(arrCurUrls); } solved javascript and json object [closed]

[Solved] Javascript On hover

Hope this helps: http://jsbin.com/podip/2/edit // IE6 does not support getElementsByClassName so… function getElementsByClassName(className) { // http://stackoverflow.com/questions/6584635/getelementsbyclassname-doesnt-work-in-ie6 var elz = []; var elements = document.getElementsByTagName(“*”); for (var i = 0; i < elements.length; i++) { var names = elements[i].className.split(‘ ‘); for (var j = 0; j < names.length; j++) { if (names[j] == className) elz.push(elements[i]); } … Read more

[Solved] When I run this PHP code nothing prints to the screen [closed]

There are multiple problems with your latest revision: Problem #1: You should use some variant of mysql_fetch_ in order to fetch the rows from the resource returned by mysql_query(). Using mysql_result can be inefficient. Usually, people use mysql_fetch_assoc(). This will return an array, which you can then access using its key, which depends on which … Read more

[Solved] Vertical Timeline with CSS

You could use the ::after property. .history-tl-container ul.tl li.achieved::after { content: “”; width: 24px; height: 24px; position: absolute; top: 0; left: -14px; background-repeat: no-repeat; background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAABGdBTUEAALGPC/xhBQAAAnFJREFUSA3tU01oE0EUnpndVBKjNGkKelLpxYOg4MlSEW9RqCVZEMEfFFEP/mDQ2lSK4Ck/RCh40YseBEHtbmovXuoPeO3Jiz/0okKFStJqBUmyO883WyZMdjdtSb3pHObN+74335uZ94aQ/2OVF6Cr8Gumq8ND+6mmZVAw7AB/2FOYfCo2/5UElWwqqRE2hWoheSIgcCqWsx4xCXRqF68P7kDxx6q4qwU0I+y6EnzN7AtDqMtC8ZjvgBQS604Q3bD1Pr7xHp+4AIC8FkYXUyejmjUuUUpOBu4FqPC6Mya4jopcGRnq16j+xvfuQhGIg3OyO29OC7d5g+83jmzSmW4AwEanRq3eceubCPCO+eHDWxjTJhBvdowaw4GMxQvL4gJ3bzB3bTAR6Qq9RXenAIGQX4TzE7FC+bnw5Zg5vzfUF9/2ilI6IDHV4j4rljMNFXO7KBLSr0pxQWLWKKXMrI6kL6jBffHtpXbieKwPttM4rcaLtZsACNvtJTCLxhi9tzCaui24ajZ1HIt6xReHAD7rku1Aurc4teTll2sA/BOhwV+CEnZrcdTYhT8z6d0sfUromUTRei991bqqdo2W8BjzKuFZp1Ek4sFclxMoYseYQZzA3ASiY+wGPYCn/NwuMAjHor6cnrVuBnESa75L4o6JRbL7cdM7Sa5kAciX3/X6saPP3L5vG+q2qcpWLh/azKLhSXySgyresgaoNbg9gEWdacEDnOYNJNdz98XPudmPSazJE4n5LCcX1yIu9vluoIhRbNEJ7KK0gmFP8gfd+fLZFmwFx3cDJRZiubKBX7+AX3sBe/0H57w0ni+fU2L+geUfUZTBZo5OpcoAAAAASUVORK5CYII=); background-repeat: no-repeat; left: -14px; } Note, you must add “achieved” class to the li where the check should be displayed. Also, you might use this class for highlighting the … Read more

[Solved] Set checked checkbox from array [closed]

Try this code – <?php $all_data = [“admin”,”member”,”editor”]; $selected = [“admin”,”member”]; foreach($all_data as $value) { $checked = in_array($value, $selected) ? ‘checked=”checked”‘ : ”; echo ‘<input type=”checkbox” name=”chk[]” value=”‘ . $value .'” ‘ . $checked . ‘>’; } ?> solved Set checked checkbox from array [closed]

[Solved] How do I make a audio play onclicked with one thumbnailed image HTML

The code you need will be something like this: <head> <script> function play(){ var myAudio = document.getElementById(“audio”); if(myAudio.paused) myAudio.play(); else myAudio.pause(); } </script> </head> <body> <img src=”https://stackoverflow.com/questions/35963057/SoundWave.gif” width=”200″ height=”200″ onclick=”play();”> <audio id=”audio” src=”01.mp3″></audio> </body> you can get more information about html5 audio element and how to work with it using this link P.S. <img> tag … Read more