- Strength to Increase Rep
- +8
- Strength to Decrease Rep
- -2
- Upvotes Received
- 24
- Posts with Upvotes
- 21
- Upvoting Members
- 21
- Downvotes Received
- 13
- Posts with Downvotes
- 12
- Downvoting Members
- 4
I have extreme interest in learning new Technologies.
Currently working in IPTV Domain. Its cool!
- Interests
- Coding, Movies, Chess, Learning new Technologies.
- PC Specs
- Intel i3 2.66 GHz, 6GB Ram, 500 GB Hard Disk.
293 Posted Topics
A simple graphical year calendar. Compiler: Turbo C In main current year is set manually, for more generic way use date function to get current year. | |
Re: http://www.w3schools.com/jsref/met_table_insertrow.asp This is simplest explaination one need to insert row/cell to a table. Can you put your code so that we can find what is wrong in your try? | |
This is a program for Encryption and Decryption This program uses the Simple Data Encryption Standard (SDES) Algorithm. This Algo takes 8-bits of plaintext at a time and produces 8-bits of ciphertext. It uses 10-bits of key for Encryption and Decryption. | |
Re: You can give an unique id to your text area. [code=html] <textarea id="mytext"></textarea> [/code] You can easily get in javascript [code=javascript] var myText = document.getElementById("myText"); var s = myText.value; // This will now contain text of textarea [/code] | |
Re: function getGroups(yourRawArray) { var group1 = []; var group2 = []; for(var i = 0; i < yourRawArray.length; i++) { var obj = yourRawArray[i]; if(obj['2'] == '0') group1.push(obj); if(obj['2'] == '1') group2.push(obj); } return {'group1': group1, 'group2': group2}; } function getGreatest(groupArray) { // To get Greatest you just need to … | |
Hi All, How can we enable HTML code compression in .Net? Is there anything we need to do in web.config or external tool is needed? Thanks! | |
Re: $(".second-form").clone().prependTo("#frmMain"); $("#frmMain").remove(); Use jQuery to make your life easy! First clone the inner form and add it above the outer form. Them remove the outer form. Thanks! | |
Re: You haven't handled ajax error method. I am sure it will be going there. Thanks! ![]() | |
Re: function getParam(paramName) { var url = window.location; var params = url.substring(url.indexOf("?") + 1 , url.length).split("&"); for(var i = 0; i < params.length; i++) { var param = params[i].split("="); if(param[0] == paramName) return param[1]; } return null; } var userName = getParam("name"); $("#welcome").html("Hey " + userName); Hope this will work :) … ![]() | |
Re: var beeped = false; function checkResponseStatus(){ $.getJSON("requestrespond.php", function(data) { ... ... ... if (respond_status == 1) { //request has been made document.getElementById("responseStatus").disabled = false; document.getElementById("responseStatus").innerHTML = "Request Sent on "+ respond_date + " <br /> Time: " + respond_time + "<br /> " + "Click Here To Respond"; if(!beeped) { … | |
Re: height of an relative positoned element in % is caclulated on the basis of its parents. You need to set height of parent. In case parent is body you can add following css to make your dive work:- html,body{height: 100%;} Thanks! | |
Re: This is solved but here is the more clean method to pass argument(s) you should know:- function abc(msg, msg1){ alert(msg + " | " + msg1); } setTimeout(abc, 500, "Hello", " World") Thanks! | |
Here is simple Digital Clock coded in C++ and compiler used is TurboC. A class DIGIT is designed to draw digits. Follwoing are the details for this class: Consructor: DIDGT(); for default settings DIGITE(int s,int c,int st); for user define settings s -> is size of the digit c -> … | |
Hi All, I am in search for some good "Responsive web Designing" CSS frameworks. Kindly Suggest few. I have gone through:- Bootstrap, Foundation and Amazium. All seems same to me. | |
Re: Your are incrementing 'row_no' in addRow() but not decrementing it in deleteRow() [code='javascript'] //Delete Function function deleteRow(r) { var i=r.parentNode.parentNode.rowIndex; document.getElementById('TableMain').deleteRow(i); // Decrementing row_no row_no--; } [/code] | |
Hi all, Please help in middle aligning text in a div without using padding. | |
Re: Its scope problem. Once line 123 get executed it lost the function 'checkSessionTime'. To overcome this pass a copy of that function to setInterval: [code=javascript] checkSessionTimeEvent = setInterval(function({checkSessionTime();},60*1000); [/code] | |
Re: Line 6 have typo, it should be:- [code=javascript] $('input[name="button1"]').click(function(){ [/code] | |
Re: Just before sending ajax request, use your modalpopup to show the loading gif image. Something like this:- [code=javascript] modalPopUp.html("<img src='loading.gif'/>"); ajax.send(onSuccess); function onSuccess(ajaxResponse) { // Data recieved from ajax, update popup modalPopUp.html(data); } [/code] Hope this will give you some idea. | |
Re: This is exact code u want. Its simple. try this. [code="html"] <html> <head> <title>test</title> <script type="text/javascript"> var counter = 0; function addNew() { // Get the main Div in which all the other divs will be added var mainContainer = document.getElementById('mainContainer'); // Create a new div for holding text and … | |
Re: Javascript is client-side scripting language which is used to intract with the client at front ent ie Brower. Where as JSP is server-side scripting which enables us to write code in java and use java classes to perform various operation such as database intraction etc. and to generate HTML on … | |
Re: 0. Create a container html element like <div id="content"></div> 1. Get the form element. There are many ways, please refer 2. With form element get input elements 3. With input elements get there values and show them on some container element Hope I have help you | |
Re: use css: [CODE=css]height:auto;[/CODE] | |
Re: [code=JavaScript]var divEls = document.getElementsByTagName("div"); var i = 0; for(i=0;i<divEls.length;i++) alert(divEls[i].id);[/code] | |
Re: In javascript code line 7, you are always sending search string as 'searchString'. Probably you should try this:- [code=javascript] var data = {'search' : searchString , 'category' : category}; [/code] | |
Re: There was an error while checking on Chrome as on FireFox its messe up, The error was at index.php:139 [COLOR="Red"]Uncaught TypeError: Cannot read property 'value' of null[/COLOR] Resolve this. ![]() | |
Re: Try using FireFox's firebug to find the error. Well I noticed on thing at line 134, where you are creating window html, you have added 'style' attributes like :- document.write('<div id="'+n+'_wnd'+'" class="WINDOW" [COLOR="Red"][B]style="top:'+(y-22)+';left:'+x+';width:'+w+';height:'+h+';"[/B][/COLOR]></div>'); you have not added [COLOR="red"]'px'[/COLOR] for 'top', 'left' etc properties. The right way is:- [code=html] <div style="left: … | |
Re: Sorry you can't do it in javascript alone. | |
Re: There is a dirty way by using cookies. In pop-up window write user choice in cookies before closing it and then read back the cookies in first page. This is not a clean method. You have to use Ajax to bring the content of popup window on the same page … | |
I have seen many beautiful clocks using images and and canvas and flash. So I thought of developing one with pure HTML,CSS3 and javascript, no images at all. This clock can be completely design using CSS. A brief description of Javascript used:- 'AnalogClock' is the name of the class which … | |
Re: Try this:- [code=html] <html> <head> <script> function doInsert(inp) { var v = inp.value; var l = v.length; var maxLen = 17 // Length of mac string including ':' if(l >= 2 && l < maxLen) { var v1; v1 = v; /* Removing all ':' to calculate get actaul text … | |
Re: Use structure to copy at one go without looping. Something like this: [code=c++] struct Phrase { char phrase[50]; }; Phrase codePhrase, inputPhrase; cout << "Please input your code without spaces: "; cin >> inputPhrase.phrase; // Now copy it to your codePhrase codePhrase = inputPhrase; [/code] | |
[CODE=c++] #include <QtGui> class MaskedLabel : public QLabel { protected: void resizeEvent(QResizeEvent* event) { QLabel::resizeEvent(event); QPixmap pixmap(size()); pixmap.fill(Qt::transparent); QPainter::setRedirected(this, &pixmap); QPaintEvent pe(rect()); paintEvent(&pe); QPainter::restoreRedirected(this); setMask(pixmap.mask()); } }; int main(int argc, char* argv[]) { QApplication a(argc, argv); QLabel* label = new MaskedLabel(); label->setText("Qt Centre!"); QFont font = label->font(); font.setPointSize(72); label->setFont(font); label->show(); … | |
This is my first step towards HTML5. This is currently tested on Chrome browser where it is awesome. It will not work on FF and definitely not on IE. I am working on it. Just copy-paste the code in blank html file and run on chrome. 'Scroller' is simple menu … | |
Re: I think the node structure should be like this: [CODE] struct node { void *data; int type; struct node *next; struct node *prev; }LINK; [/CODE] where: [B]type[/B] is used for type. For example type=1 indicates int, type=2 indicates float, type=3 indicates userdefine and so on... and Insert function will look … ![]() | |
Re: [code=javascript] var clickCount = 0; document.onclick = function() {clickCount++}; doucment.onunload = function(){alert("No. of clicks = " + clickCount);}; [/code] | |
| |
Re: I can see one problem. The script to open dialog by clicking '#a1' is defined before the [B]<a id="a1"></a>[/B]. So it might be the case that $("#a1") was not getting captured. Solution: Put your <script></script> code after <a id="a1"></a> tag. OR Best will be to add script code in document … | |
Re: [CODE=javascript]<img src="austria.jpg" name="im1" height="300" width="300" onclick="window.open('http://google.com')"/><br/> <button onclick="document.images.im1.src='austria.jpg'; document.images.im1.onclick='window.open('http://google.com')'">Austria</button> <button onclick="document.images.im1.src='korea.jpg'; document.images.im1.onclick='window.open('http://yahoo.com')'">Korea</button> <button onclick="document.images.im1.src='brazil.jpg'; document.images.im1.onclick='window.open('http://chapo.co.cc')'">Brazil</button>[/CODE] | |
Re: Here is simple javascript fucntion to draw circle. There no efficient algo used here. But you can implement good and efficient algos. [code='html'] <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8" /> <title>TV</title> <style> .pixel { position: absolute; width: 1px; height: 1px; background: red; } </style> <script> function circle(x, y, r, … | |
Re: Hi seblake, There are simple 2 things about a function:- 1. Defining the function 2. Calling the function When you 'Define' a function (as you did in above), it does nothing. Defining means you are just writing logic of the problem to solve in the function. In your case you … | |
Re: Yes it can be done using jQuery. Try it. ![]() | |
Re: error: for loop is going beyond array size. i [COLOR="Red"]<= [/COLOR] result_arr.length | |
Re: If its not alerting anything then clearly there are 2 reasons:- 1. There is an error before if(tableHtml=='true') is executed. 2. Worst case ajaxHandler() not called at all. To debug try this:- [code=javascript] function ajaxhandler() { alert("function called : " + response); tableHtml=response.Text if(tableHtml=='true') alert("Valid Move"); else alert("invalid move") } … | |
Re: Nice job. It would be better if there is indication of current cursor position on the canvas. Something different from background color. | |
Re: Steps:- 1. Get Total number of records in table. (Say: totalRecs = 100) 2. Create a small PHP(say: check.php). Which will compare old total with new total and will echo 'true'/'false' 3. Create a function in javascript(say: getUpdate() ). This method will send an Ajax request with 'totalRecs' as one … | |
Re: Try this: [code=html] <HEAD> <style> .bigcell { background-color:#aa9966; border:4px solid #aa9966; text-align:center; } .cell { width:40px; height:40px; font-family:Verdana, Arial; font-size:10pt; font-weight:bold; background-color:#996633; color:#ffff33; border-top:2px solid #aa9966; border-left:2px solid #aa9966; border-right:2px solid #663300; border-bottom:2px solid #663300; text-align:center; } .hole { width:40px; height:40px; background-color:#aa9966; text-align:center; } body,h1,h2,h3,.msg,capt1,capt2 {font-family:Verdana,Comic Sans MS,Arial;} body {margin:0px;} … | |
Re: Line 1 and 2 in your code is what is needed to change the content on span. BUT you need to put this code after your span tag in the html. HTML is render from top to bottom and so is the embedded javascript. If you put your javascript code … | |
This is Jquery plugin which can be used to change the content a its place. Features: 1. Easy to use 2. Maintain changeability of Jquery Know Issue: 1. Can take html string also as input For example: html: [code=html] <div id="editable">I can be changed right here</div> [/code] javascript: [code=javascritp] $.('#editable').editAtPlace(function(newtext, … | |
Re: Pass current Input Element in ajaxFunction(): ajaxFunction(this); [code=php] <?php $conn = mysql_connect('xxx','hoovdash','xxx'); $db = mysql_select_db('hoov_dashboard',$conn); $sql = "SELECT * FROM invoices WHERE on_hold='1' ORDER BY create_date"; $result = mysql_query($sql,$conn); while($row = mysql_fetch_assoc($result)) { $id = $row['id']; $equip_num = $row['equip_num']; $invoice_num = $row['invoice_num']; $notes = $row['notes']; $row_class = ($row_count % 2) … |
The End.