[Solved] Running constant scripts [closed]

Your question seems terribly inconsistent, but it appears that you have the completely wrong approach. To have expiring items, you do not manually deactivate them when the expiry date comes or something like that. You simply have the expiry date as part of the item (say, a column in your database) and you select items … Read more

[Solved] jQuery toggle() with dynamic div ID’s

This is the best way I could come up with: var divs = $(‘div[id^=”category-“]’); var num = divs.length; for (i=1; i<=num; i++) { $(‘<button class=”toggles” />’) .text(‘Toggle div ‘ + i) .appendTo(‘#divToAddButtonsTo’); } $(‘.toggles’).live(‘click’, function(){ var thisIs = $(this).index(); $(‘div[id^=”category-“]’).eq(thisIs).toggle(); }); JS Fiddle demo. Obviously this is run inside the $(document).ready(). References: attribute-starts-with ^= selector. … Read more

[Solved] Reset a Radio button inside a Radio group

This is how I did it: It is in C# but I think it is easy to convert it to Java. I used tag to know if this radio button checked before or not. False => It is not checked True => It is checked radiobutton.Tag = false; radiobutton.Click += SingleChoiceQuestionAlternativeClick; Then: private void SingleChoiceQuestionAlternativeClick(object … Read more

[Solved] Toogle icon (play/pause), and stop when another button is clicked

Well, after a lot of research i could get something that for now it’s ok for me. I just want to share if anybody else gets my same problem This are my scripts (i needed to use 2) <script language=”javascript”> var currentsound; function play_pause(player) { var myAudio = document.getElementById(player); if(myAudio.paused) { myAudio.play(); } else{ myAudio.pause(); … Read more

[Solved] how to create a jquery toggle using existing html code [closed]

HTML: <input type=”button” value=”click me” id=”click”> <div id=”info”>This is what you are expecting or may not , but im doing this just for fun</div> Jquery: $(“#click”).click(function () { $(“#info”).toggle(‘slow’); }); CSS: #info{ width:200px; background-color:#9494B8; border-radius:3px; padding:5px; display:none; } See the DEMO 5 solved how to create a jquery toggle using existing html code [closed]