IE vs FF Working with dynamic Tables

Today I am gonna write another thing I came across while working on Javascript.
Sometimes, even if it’s easier to work with list <li> elements in HTML, but the design department may make a
design using tables.
Well what I wanted to do was read some information and dynamically create table and assign correct info to its
rows, columns.
Lets write the basic HTML code for table element:

<td>Row1 Column1</td>
<td>Row1 Column2</td>
<td>Row2 Column1</td>
<td>Row2 Column2</td>

So, looking at the table and other tags used with table, I made those elements using the Javascript Code.
The Code used to create table is as follows:

var myTable = document.createElement("table");
var myRow = document.createElement("tr");
var myCell = document.createElement("td");
myCell.innerHTML = "Hello World!";
myRow .appendChild(myCell);

Now, for this Javascript, Firefox was fine, but it did not worked on IE. So, I searched on Internet and then using
Firebug I noticed one thing that we also have another element inside table as <tbody> and this was the actual problem.
On FF it makes this element and adds it to the table tag. But, IE does not.
So, the new code that worked for both IE and FF is as under:

var myTable = document.createElement("table");
var myTbody = document.createElement("tbody");
var myRow = document.createElement("tr");
var myCell = document.createElement("td");
myCell.innerHTML = "Hello World!";

And, as you can see in the code above, I am manually creating the tbody element and appending it to the table.
And, the row element is appended to this tbody element.
Finally, the problem with creating tables dynamically was solved. πŸ™‚
May this help you when u face similar problem.
Cheers.. πŸ™‚

Reliance Wireless

i guyz. So here I am again with a new post. I have been busy with my training and so no time to post. Though being free bcos of weekend, I thought of downloading somethings from internet and i was very happy with the download speed which i was getting.

I have been using Reliance Broadband+ since last 2 months. Its little costly, but the service and connection i am getting is worth it, as you can see in the pic. After using You Telecom(Pune) and BSNL(Pune) wired broadband service, this Reliance Broadband plus that too wireless is extremely fabulous. and excellent connectivity.
The software I am using for downloading is Bit Comet. Sometimes, i feel software also matter to get good download speed. So, if your plannin to get some connection. just give reliance a thought.. πŸ™‚

Google Docs… New

Hello.. I am here to provide you with something which will help you to plan out a “Date” or probably ask someone for “date”.. Well and hows that goin to happen.. πŸ˜›
Twitter helped me to find that out with a tweet, I have nt yet used the idea, but it may be helpful for you.
This video(Link) is worth watchin to understand its importance:
Google now trying to help you in some other activities too….other than Searching πŸ˜›
and that is for College goin people.. πŸ™‚ its

google docs:

Use USB Modem on Ubuntu

Hey Hi..everyone.. Again I am back with a post after many days.. I just got my Dell Studio Laptop few days back..
Actually due to some reasons, I got the Reliance USB modem to access internet..
Reliance provides USB modem of Huawei Company. When I got it, some people told me that USB modem drivers are not available on Ubuntu and It will not be possible to use internet on Ubuntu. But i got some references from net and when i tried with these steps and packages, I got access of Internet on Linux too.. πŸ™‚ πŸ˜€ .. Again thanks to google, it helped me to get the solution and thanks to ubuntu forums and debian package.
So now let me come to the point. I used “wvdial” command to connect through the USB modem and for this I have to make some changes in /etc/wvdial.conf .
So first of all you need “wvdial” installed on ur PC..
OS installed on my Laptop is Ubuntu 9.04..

Steps you need to follow:

  • Install wvdial:

command: Β  Β Β sudo apt-get install wvdial
OR download debian package of wvdial and you will also need to download some of the dependencies. You will get wvdial package here.

  • Add device configuration to device file in /etc/wvdial.conf

Replace with your 10 digit Reliance connection number in place of phonenumber.

[Dialer Defaults]
Phone =
Username =
Password =
New PPPD = yes[Modem0]
Modem = /dev/ttyUSB0
Baud = 115200
SetVolume = 0
Dial Command = ATDT
Init1 = ATZ
FlowControl = Hardware (CRTSCTS)

[Dialer cdma]
Username = phonenumber
Password = phonenumber
Phone = #777
Stupid Mode = 1
Inherits = Modem0

  • Run wvdial

Run the Command on Terminal: Β sudo wvdial cdma

You will see some output like this:

~$ sudo wvdial cdma
–> WvDial: Internet dialer version 1.60
–> Cannot get information for serial port.
–> Initializing modem.
–> Sending: ATZ
–> Modem initialized.
–> Sending: ATDT#777
–> Waiting for carrier.
CONNECT 230400
–> Carrier detected. Starting PPP immediately.
–> Starting pppd at Sat Jul 11 22:56:19 2009
–> Pid of pppd: 4299
–> Using interface ppp0
–> pppd: ????[18][18]m X[19]m
–> pppd: ????[18][18]m X[19]m
–> pppd: ????[18][18]m X[19]m
–> pppd: ????[18][18]m X[19]m
–> local IP address
–> pppd: ????[18][18]m X[19]m
–> remote IP address
–> pppd: ????[18][18]m X[19]m
–> primary DNS address
–> pppd: ????[18][18]m X[19]m
–> secondary DNS address
–> pppd: ????[18][18]m X[19]m
–> pppd: ????[18][18]m X[19]m
–> pppd: ????[18][18]m X[19]m

Well thats it, your connected to Internet….

How to enable sharing of internet from Ubuntu

I was busy trying to enable internet sharing on a computer with Ubuntu to other computers having Windows/Ubuntu as OS. I was searching for solution from many days.
One solution i got was Firestarter: Firestarter has the ability to share the firewall host’s Internet connection among all the computers on your local network. This is done through a technique called Network Address Translation, or NAT. To the outside world the cluster of machines will look like a single machine with a single IP address.
but. The Firewall/gateway machine connected to the Internet will need two network cards and the clients need one each if u need to enable internet sharing using firestarter..
So i had to find another solution.. and when i read one of my friends recent post, it helped how to find a solution to any problem by urself, rather knocking others door or searching for solution in a wrong way or style..
Even you can read the post and learn something good to search solutions of problems in better ways:
How to ask questions?

And the solution which helped to solve my above problem(to enable internet sharing on a computer with Ubuntu to other computers having Windows/Ubuntu as OS) is as:

Note: Type all the following commands in a root terminal, DO NOT use sudo.
First be root by typing ‘su’ on terminal and enter your root password..
1. Start by configuring the network card that interfaces to the other computers on you network:
(here in place u can put 0 in place of X if you are using eth0 for LAN connection)
# ifconfig ethX ip

where ethX is the network card and ip is your desired server ip address (Usually is used)

2. Then configure the NAT as follows:

# iptables -t nat -A POSTROUTING -o ethX -j MASQUERADE

where ethX is the network card that the Internet is coming from

# echo 1 > /proc/sys/net/ipv4/ip_forward

3. Install dnsmasq and ipmasq using apt-get:

# apt-get install dnsmasq ipmasq

4. Restart dnsmasq:

# /etc/init.d/dnsmasq restart

5. Reconfigure ipmasq to start after networking has been started:

# dpkg-reconfigure ipmasq

6. Repeat steps 1 and 2.

7: step:
# gedit /etc/sysctl.conf
(see the screenshots below..)
remove the comment(i.e. remove the ‘#’ at the start of the lines) of the lines marked in orange in the screenshots below.

8. Reboot. (Optional)

I hope this helps.