Search Results

Showing results 1 to 40 of 79
Search took 0.02 seconds.
Search: Posts Made By: Luckychap
Forum: JavaScript / DHTML / AJAX Oct 22nd, 2009
Replies: 3
Views: 395
Posted By Luckychap
Try this example:


<html>
<head>
<title>Handling onClick for links</title>
<script>
<!--
function confirmLink()
{
Forum: JavaScript / DHTML / AJAX Oct 22nd, 2009
Replies: 3
Views: 395
Posted By Luckychap
NO, both will behave differently if you click 'cancel' on confirmation dialog instead of clicking 'ok'.

Now its ur job to figure out something from this.
Forum: C Sep 2nd, 2009
Replies: 3
Views: 512
Posted By Luckychap
You can use {} with arrays only when initializing.

char ba[25][12] = {"item[0][0]", "item[0][1]", "item[0][2]",......, "item[0][11]",
"item[1][0]", "item[1][1]",...
Forum: JavaScript / DHTML / AJAX Aug 10th, 2009
Replies: 3
Views: 469
Posted By Luckychap
Hope this little code will help you:


<html>
<head>
<style>
div#clock {
position: absolute;
border: 2px solid ccc;
background-color: c0f;
Forum: C Jul 31st, 2009
Replies: 10
Views: 741
Posted By Luckychap
As far as I know:

Alt + f9 -> just complile
use:
Ctrl + f9 -> compile + run

:)
Forum: C Jul 31st, 2009
Replies: 21
Views: 1,862
Posted By Luckychap
I just wrote this code to give you an idea for how to do conversion manually (In fact this logic can be used in any language).
you may have to change the code as per you requirements: ...

Done...
Forum: C Jul 31st, 2009
Replies: 21
Views: 1,862
Posted By Luckychap
I have no idea about any available method to convert Hexa String to unsigned char. But can also be done manually.

maintain a array for all possible hexa numbers :


char hexa[] = {'0', '1',...
Forum: C Jul 30th, 2009
Replies: 21
Views: 1,862
Posted By Luckychap
Hey all,
Posting code based on assumptions is totally useless.
Why we take pain when post starter is not bothered at all, after so many assumptions posted.
Forum: C Jul 30th, 2009
Replies: 21
Views: 1,862
Posted By Luckychap
What you really want to do? Explain more.
Forum: JavaScript / DHTML / AJAX Jul 26th, 2009
Replies: 18
Views: 1,336
Posted By Luckychap
This may work for you:


var dgebi = document.getElementById;
// This function takes elements not elements id.
error_appname(dgebi ('application_name'+i), dgebi ('erSpan' + i));
Forum: JavaScript / DHTML / AJAX Jul 25th, 2009
Replies: 18
Views: 1,336
Posted By Luckychap
This can be done in many ways, but I will tell you easiest way:

Your function error_appname(inputField, erSpan), requires 2 argument, so maintain global arrays for those.


// Global arrays...
Forum: JavaScript / DHTML / AJAX Jul 23rd, 2009
Replies: 18
Views: 1,336
Posted By Luckychap
No problem bros....

Everybody starts with:

'printf(''Hello World");'

BEST OF LUCK!
Forum: JavaScript / DHTML / AJAX Jul 23rd, 2009
Replies: 18
Views: 1,336
Posted By Luckychap
Simple, pass the date element gl also in validation function


// Passing erSpan, so that we can easily show error message
gl.onblur= function() {error_appname(gl, erSpan)};


function...
Forum: JavaScript / DHTML / AJAX Jul 23rd, 2009
Replies: 18
Views: 1,336
Posted By Luckychap
Yes indeed you can.

Add a span element in every row in ur addRow() method


function addRow()
{
// Some of your code

gl.type = 'text';
Forum: JavaScript / DHTML / AJAX Jul 22nd, 2009
Replies: 18
Views: 1,336
Posted By Luckychap
You assigned:
var dt=document.getElementById("application_doj" + iteration).value

dt has already got value. So pass only dt in isDate(dt).



function ValidateForm()
{
alert("hi...
Forum: JavaScript / DHTML / AJAX Jul 9th, 2009
Replies: 5
Views: 697
Posted By Luckychap
You are doing all the manipulation at server side, where javascript can not help you.

Sorry :(
Forum: JavaScript / DHTML / AJAX Jul 4th, 2009
Replies: 5
Views: 697
Posted By Luckychap
You can use this simple method to add new text boxes: -

/* container - HTML element in which textBox needs to be added
labelString - (optional) Label string for text box
textValue -...
Forum: JavaScript / DHTML / AJAX Jun 5th, 2009
Replies: 4
Solved: I have a form
Views: 621
Posted By Luckychap
From servlet you send response as true or false. But at client end ie javascript the response will be string 'true' or 'false'. So u need to compare as something like this:


var result =...
Forum: JavaScript / DHTML / AJAX May 25th, 2009
Replies: 9
Views: 676
Posted By Luckychap
Hey, you can always have hidden input tag to which you can set values in form.
For example:-


<form action="page.php" method="post">
<input type='hidden' name='var1' value='param1'/>
...
Forum: JavaScript / DHTML / AJAX May 24th, 2009
Replies: 5
Views: 1,497
Posted By Luckychap
Hi essential,

I think he do not want root to be appended to body.
Forum: JavaScript / DHTML / AJAX May 24th, 2009
Replies: 5
Views: 1,497
Posted By Luckychap
getElementById() only works with document. To parse your HTML can use childNodes;

Modifying your code all little bit:


function parseHTML(html) {
var root = document.createElement("div");...
Forum: JavaScript / DHTML / AJAX May 24th, 2009
Replies: 12
Views: 840
Posted By Luckychap
You have to use getElementById() not only for company but all the other HTML element you are using in the code like: screenshot, url and line.
And You do not have to use different name from id's of...
Forum: C++ May 23rd, 2009
Replies: 11
Solved: stop loop
Views: 440
Posted By Luckychap
I was not blaming anyone I was just addressing a common mistake which anyone can make.

Come on Man!!
Forum: C++ May 23rd, 2009
Replies: 11
Solved: stop loop
Views: 440
Posted By Luckychap
Very common mistake in for loop:


for(i=0; inputDone == 'y'; i++)


did u get this!!
Forum: JavaScript / DHTML / AJAX May 23rd, 2009
Replies: 12
Views: 840
Posted By Luckychap
Can we have some code from you
Forum: Java May 23rd, 2009
Replies: 4
Solved: Linked List
Views: 385
Posted By Luckychap
Where are you adding first node (head)?
If addValue() is suppose to add new nodes then head should also be added in this function. But it seems you are adding is manually something like this:

...
Forum: C May 15th, 2009
Replies: 5
Views: 575
Posted By Luckychap
Forum: JavaScript / DHTML / AJAX Mar 22nd, 2009
Replies: 2
Views: 563
Posted By Luckychap
may this help you: http://developer.yahoo.com/yui/examples/carousel/csl_imagentext_source.html
Forum: C Mar 20th, 2009
Replies: 4
Views: 794
Posted By Luckychap
for simplification returned array will be of type:

int array[100][20] ;

or u can modify above function to get variable 2D array:

int** foo(int row, int col)
{
int i;
int** array =...
Forum: C Feb 4th, 2009
Replies: 4
Solved: Prime numbers
Views: 449
Posted By Luckychap
In line no 9: for (i=2; i==num; i++)
It should be: for (i=2; i<num; i++)

AND

your logic for prime number is absolutely wrong.

Should be like this:
Forum: C Dec 13th, 2008
Replies: 5
Views: 983
Posted By Luckychap
WOW!!

More assignments for daniweb!!! :D
Forum: C++ Dec 10th, 2008
Replies: 5
Views: 406
Posted By Luckychap
Best way to learn is to practice. So start coding!! Do not waste 69$.

Wait a sec....why 69$ and not 60$ OR 70$. :D
Forum: C Dec 10th, 2008
Replies: 8
Views: 1,259
Posted By Luckychap
HAHAHA cool catches!!
Forum: C Dec 9th, 2008
Replies: 8
Views: 1,259
Posted By Luckychap
For simplicity just want to add that, loops are just loops. The loop statement is used to execute same piece of code number times.

Further its fully up to you to decide how to loop the number of...
Forum: HTML and CSS Dec 3rd, 2008
Replies: 4
Views: 634
Posted By Luckychap
use HTML frames to do this. http://www.w3schools.com/html/html_frames.asp
Forum: C Dec 2nd, 2008
Replies: 1
Views: 342
Posted By Luckychap
In line:20 ie

printf("%d",psd.y);


psd is used to access y by dot(.) operator which is wrong because psd is a pointer and to access y you must use ->(arrow operator) ie

...
Forum: C Dec 2nd, 2008
Replies: 5
Views: 1,128
Posted By Luckychap
Forum: C Dec 2nd, 2008
Replies: 5
Views: 1,128
Posted By Luckychap
there is a simple function to calculate a string length strlen(str) defined in string.h where str is the pointer to string of which you want to calculate the length.


#include <stdio.h>
#include...
Forum: JavaScript / DHTML / AJAX Nov 29th, 2008
Replies: 3
Solved: Ajax Help
Views: 679
Posted By Luckychap
Simply you have to parse the server response manually.

For example you get this a client side:

responseText = "field1||fiel2||field||......";

Then using javascipt string-functions to...
Forum: JavaScript / DHTML / AJAX Nov 29th, 2008
Replies: 2
Views: 886
Posted By Luckychap
You have to just set the focus to the first input box after the page is loaded. And that can be done by simple javascript code.

Write an event-handler for <body onload="setInputFocus()">

...
Showing results 1 to 40 of 79

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC