Saturday, October 10, 2009

How to dial a dial-up connection on windows startup

It is a headache to dial a dial-up connection each time we start windows to surf internet. Is there any way that we can dial a dial-up connection automatically when windows starts?

The answer is yes..

1. First go to Control Panel > Network Connections

Then right click on the connection that should be dialed automatically and click on Create Shortcut from the pop-up menu. Then click yes when you asked to create the shortcut on desktop.

2. Again Right-click on the connection and click on properties. In properties dialog go to Options tab. In Dialing Options pane uncheck all options as shown in the figure.

3. Copy shortcut created in step 1 which is in the Desktop to the Startup in Start menu.

Now you are done.. Try restarting the computer.. When are login the connection should be made already..

Tuesday, January 29, 2008

Marked as spam while sending emails using php mail() function to yahoo or hotmail?

It is a common problem for all using php mail function. To solve this there
are so many answers I have seen in the internet and they do not hit problem

Actually the problem here is if we send mails using php mail function we do
not have a signature and other mailing systems thinks that we are spamers.

So the solution is using a free remote smtp host like gmail to send our mails.
It is not hard because we have a free php smtp project called PHPMailer. You
can download it from here.
You do not need to install it on your server. Just you have to upload it with your code.

It is very easy to understand how it is used to send mails using examples
zipped with PHPMailer. The following code is to send emails using gmail and
to do that you have to have a gmail mail account. Which can easily be created
by visiting Your mails will
send using that mail account and they will never become spams...


// example on using PHPMailer with GMAIL



$mail=new PHPMailer();


$mail->SMTPAuth = true; // enable SMTP authentication

$mail->SMTPSecure = "ssl"; // sets the prefix to the servier

$mail->Host = ""; // sets GMAIL as the SMTP server

$mail->Port = 465; // set the SMTP port

$mail->Username = ""; // GMAIL username

$mail->Password = "password"; // GMAIL password

$mail->From = "";

$mail->FromName = "Webmaster";

$mail->Subject = "This is the subject";

$mail->Body = "Hi,<br>This is the HTML BODY<br>"; //HTML

$mail->AltBody = "This is the body when user views in plain text format";
//Text Body

$mail->WordWrap = 50; // set word wrap

$mail->AddAddress("","First Last");


$mail->AddAttachment("/path/to/"); // attachment

$mail->AddAttachment("/path/to/image.jpg", "new.jpg");
// attachment

$mail->IsHTML(true); // send as HTML

if(!$mail->Send()) {

echo "Mailer Error: " . $mail->ErrorInfo;

} else {

echo "Message has been sent";


Wednesday, August 8, 2007

How to remove all adds put in a free web hosting site using a simple JavaScript

All sites that hosts web sites for free (Such as, puts their adds on our html pages. So what can we do for avoid these adds. In one side you can by a hosting plan paying money. But I am going to tell you the other way. That is hide all the adds that were not put by us.
To do second method, first you should create your site inside a div tag which has id of "keepThis" as following

<div id="keepThis">Here put your code for the page</div>

Then you should put onLoad event on body tag as following..

<body background="../bg.jpg" onLoad="killAll()">

Then put following JavaScript to header section of your page.

<script language="JavaScript">

function handleError(msg,url,num)
return true;

window.onerror = handleError;

function killAll()
var allEles = document.getElementsByTagName('*');
for(var i=0; i {
if (isDel(allEles[i])==true)
var w = document.body.clientWidth;
var ele = document.getElementById("keepThis");['left'] = w;
function isDel(ele)
var rtn = true;
return false;

return false;

if ("keepThis")
if (ele.nodeName!=undefined)
return rtn;


Hey you're done now. You can host your page without any forced adds on a free web server.