Search This Blog
Friday, February 5, 2016
Thursday, January 7, 2016
i love you shayri
Dard ka ehsas janna hai to pyar kar ke dekho,
Apni aankho me kisi ko utar kar dekho,
Chot unko lagegi aansu tumhe aa jayenge,
Ye ehsas janna ho to Dil haar kar dekho.
Apni aankho me kisi ko utar kar dekho,
Chot unko lagegi aansu tumhe aa jayenge,
Ye ehsas janna ho to Dil haar kar dekho.
Saturday, January 2, 2016
Guide to Affiliate Marketing Success
- What is Affiliate Marketing?
- Why Affiliate Marketing?
- How to Start Affiliate Marketing with Little Investment
- How to Know What Affiliate Program to Join
- What Becoming a Partner Can Really Mean
- What Most Affiliate Marketers Do
- What Advanced Affiliate Marketers Do
- Why You Need to Brand Yourself
- Affiliate Marketing with PPC
- Maximizing Your Marketing Campaigns
- Importance of Learning Copywriting
- Dominate Affiliate Marketing with Bonuses
- High-Ticket Affiliate Programs (Top-Tier)
- Affiliate Marketing vs. Creating Your Own Products
2016 Resolutions For Affiliate Advertisers: 5 Steps To A Successful Year
Looking to step up your affiliate marketing strategy in 2016? Columnist Melissa Feemster outlines some best practices to get you off on the right foot.
With 2015 just about in the rearview mirror, it’s time to look down the open road that is 2016. Affiliate marketing, with its roots in native content, continues to be a proven method to reach consumers and drive sales.
Affiliate advertisers looking at ways to be most successful in 2016 should determine plans now. To get that started, here are five winning resolutions to improve your influencer network beyond measure in the new year read more..
Thursday, December 24, 2015
How to Password Protect Your WordPress without User Registration
There are many tutorials out there that shows you how to password protect your website content. Many of those utilize complex membership plugins that require user registration. But what if you just want to password protect your site without user registration? Let’s say you have a demo site for client work. You may only want that specific client to see your site. In this article, we will show you a very simple way to quickly password protect your WordPress site with a single password..read more
Monday, December 21, 2015
8 reasons why your business NEEDS a professional website!
Like many small business owners, you may believe your business cannot benefit from having a website or that a website is not within your budget. Or maybe you think because you don’t use a computer, neither do your potential customers. These are misconceptions. These 8 reasons show why your company NEEDS a professional website, no matter what size your business.... read more
Important links
Important links
Saturday, December 12, 2015
How to Easily Make a PHP Chat Application
Design an Online Chat Room with PHP and MySQL
by: Rory Canyon
by: Rory Canyon
In this article, you will learn how to design and develop a simple online chat room with PHP and MySQL. This tutorial explains every steps of the development, including both database design and PHP programming. Basic computer skills and knowledge of HTML and PHP are required. Ok, let's begin now.
Step 1: Design Database Table. Create table "chat" in MySQL database to store basic chat information: chtime (chat time), nick (user nickname) and words (chat message, less than 150 characters)
mysql> CREATE TABLE chat
-> chtime DATATIME,
-> nick CHAR (10) NOT NULL,
-> words CHAR (150);
Step 2: Design Structure. This simple online chat room includes the following four sections: user login, message display, message input and a main frame integrating the display and input sections. Thus, it needs the following four files to work: login.php, main.php, display.php and speak.php.
Step 3: Write the code
1. login.php (just a HTML form)
<html>
<head>
<title>User Login</title>
</head>
<body>
Please input your nickname and enter
<form action="main.php" method="post" target="_self">
<input type="text" name="nick" cols="20">
<input type="submit" value="login">
</form>
</body>
</html>
2. main.php
<?
setcookie("nick",$nick) //use cookie to store user nickname
?>
<html>
<title>My Chat Room</title>
<frameset rows="80%,*">
<frame src="display.php" name="chatdisplay">
<frame src="speak.php" name="speak">
</frameset>
</html>
3. display.php
This file is used to get message records from database and display the results. To keep the size of database, old messages are deleted and only the newest 15 messages are displayed.
<html>
<head>
<title>Display Messages</title>
<meta http-equiv="refresh" content="5;url=display.php">
</head>
<body>
<?
//connect to mysql server, server name: main, database username: root
$link_ID=mysql_connect("main","root");
mysql_select_db("abc"); //abc is the database name
$str="select * from chat ORDER BY chtime;" ;
$result=mysql_query($str, $link_ID);
$rows=mysql_num_rows($result);
//get the latest 15 messages
@mysql_data_seek($resut,$rows-15);
//if the number of messages<15, get all of the messages
if ($rows<15) $l=$rows; else $l=15; for ($i=1;$i<=$l; $i++) {
list($chtime, $nick, $words)=mysql_fetch_row($result);
echo $chtime; echo " "; echo $nick; echo":" ; echo $words; echo "
";
";
} //delete the old messages(only keep the newest 20 only)
@mysql_data_seek($result,$rows-20);
list($limtime)=mysql_fetch_row($result);
$str="DELETE FROM chat WHERE chtime<'$limtime' ;" ;
$result=mysql_query($str,$link_ID);
mysql_close($link_ID);
?>
</body>
</html>
4. speak.php
<html>
<head>
<title>Speak</title>
</head>
<body>
<?
If ($words)
{ $link_ID=mysql_connect("main","root");
mysql_select_db("abc"); // abc is the database name
$time=date(y).date(m).date(d).date(h).date(i).(date(s); //get current time
$str="INSERT INTO chat(chtime,nick,words) values ('$time','$nick','$words');" ;
mysql_query($str,$link_ID); //save message record into database
mysql_close($link_ID); )
?>
//the following is the message input form
<form action="speak.php" method="post" target=" _self">
<input type="text" name="words" cols="20">
<input type="submit" value="Speak">
</form>
</body>
</html>
Now, you have finished the design and coding of a simple online chat system. Put all the files into your website root and see how it works, :)
Subscribe to:
Posts (Atom)
