Thursday, 9 July 2015

Connection string in Web.config

 
Connection string in Web.config 

GridView Control Use in .aspx webpage-
<![if !vml]><![endif]> GridView Control
<asp:GridView ID="GridView1" runat="server" Height="270px" Width="524px"
          BackColor="White" BorderColor="#3366CC" BorderStyle="None" BorderWidth="1px"
          CellPadding="4" >
          <FooterStyle BackColor="#99CCCC" ForeColor="#003399" />
          <RowStyle BackColor="White" ForeColor="#003399" />
          <PagerStyle BackColor="#99CCCC" ForeColor="#003399" HorizontalAlign="Left" />
          <SelectedRowStyle BackColor="#009999" Font-Bold="True" ForeColor="#CCFF99" />
          <HeaderStyle BackColor="#003399" Font-Bold="True" ForeColor="#CCCCFF" />
        </asp:GridView>
Create Database using MS SQL Server2005/2008. Then create table in sql and save it, Now connect database to our website, Using Server Explorer copy the connection sting path and add connection string tag in web.config file 
First Open Web.Config file
--><configuration>
      <configSections>
          <sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
                <sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
                      <section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
                      <sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
                            <section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="Everywhere"/>
                            <section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
                            <section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
                            <section name="roleService" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
                      </sectionGroup>
                </sectionGroup>
          </sectionGroup>
      </configSections>
      <appSettings/>
// Now Add <connectionStrings> tag in web config file
      <connectionStrings>
          <add name="DatabaseConnectionString1" 
connectionString="Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\Database.mdf;Integrated Security=True;User Instance=True" 
providerName="System.Data.SqlClient"/>
      
</connectionStrings>
Now Apply code in .cs file as follows-
using System;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Data.SqlClient;
public partial class _Default : System.Web.UI.Page
{
    SqlConnection cn = new SqlConnection();
    SqlCommand cmd = new SqlCommand();
   
    {   // Create Connection Object
        SqlConnection cn = new SqlConnection();
        


// Apply code in single line here- 


    // Now Open Connection
      cn.Open();
        SqlCommand cmd = new SqlCommand("SELECT eid AS EmployeeId , ename AS EmployeeName FROM employee ORDER BY eid", cn);
        SqlDataAdapter da = new SqlDataAdapter(cmd);
        DataSet ds = new DataSet();
      da.Fill(ds);
      GridView1.DataSource = ds;
      GridView1.DataBind();
         
       
    }

Wednesday, 8 July 2015

SEARCH ENGINE OPTIMIZATION TIPS & TUTORIALS

SEARCH ENGINE OPTIMIZATION TIPS & TUTORIALS

Introduction to seo

 Webmasters and site owners who want to investigate the issues of SEO (search engine optimization) and promotion of their resources. It is mainly aimed at beginners, although I hope that experienced webmasters will also find something new and interesting here. There are many articles on seo on the Internet and this text is an attempt to gather some of this information into a single consistent document. 

Information presented in this text can be divided into several parts:

   - Clear-cut seo recommendations, practical guidelines.

   - Theoretical information that we think any seo specialist should know.

   - Seo tips, observations, recommendations from experience, other seo sources, etc.

Lesson-1 Click Here            Lesson-5 Click Here               Lesson-9 Click Here

Lesson-2 Click Here            Lesson-6 Click Here               Lesson-10 Click Here

Lesson-3 Click Here            Lesson-7 Click Here               Lesson-11 Click Here

Lesson-4 Click Here            Lesson-8 Click Here               Lesson-12 Click Here

Lesson-13 Click Here          Lesson-14 Click Here             Lesson-15 Click Here


Online Earning with Website or Blog

How To Make Money Online Using Your Blog !!!!

Its very good for the peoples for earning money using their artical, website, blogging  etc. But there are some fraud are also by cheat the peoples using starting pays money ads offer some surveys program. But here i tell to you how you make your identity on world wide using just your knowledge sharing on web using blogging provided by Google.

1. Create a website or blog
 You can easlly create your blog by google Blogger. You have just only a single gmail account and login with blogger gmail. Create you blog here.
For website there are many inexpensive website services such as Hostgator and GoDaddy. It's also easy to set up a free blog through services such as Google's Blogger blog network. I also use Namecheap for domains and  a re-seller account for hosting.
Pay Per Click (PPC)

Pay Per Click (CPC) is what an advertiser pay to search engines and Internet publishers for a single click on their advertisement, which directs one visitor to the advertiser’s website.
Google’s Ad-sense program is the biggest provider. But its not easy task for achieve this. Google monitor your all website contents, traffic area and listing in search engines.
 It’s pretty simple to get running as a publisher. You sign up for an account, use their tool to build an ad code, and then paste it onto your site. People click on those ads and Google pays you x amount per click. Hence the name “pay per click.” This is a great way to make passive income.
Basically they bring together advertisers and website owners and in return you split the profit with them. Google pays 68% of the money that they typically receive. They’re basically charging a third in commission, but two-thirds of something is a whole lot more than 100% of nothing.

The ads are contextual which means that they are selected based on your website’s content. They come in both text & graphic banners, and have various ad sizes.

Microsoft & Yahoo use to have their own Publisher programs, but have since exited that market. Yahoo recommended Chitika as replacement to its former publishers. Here’s a list of top 10 alternatives to AdSense.

List of Online ads providers-
Google Ads Sence
Infolinks
India Vigyapan
Pay Per Click
Speed Ads
Chitika
Clicksor
BidVertiser

Banner and Text Ads

on the internet so many website advertisement provider for blog or website.
It might seem like easy money, but there is a barrier of entry. As we said repeatedly, build your audience first, then the advertisers. There are also tons of ad networks out there, but most of them require that you have at least 100,000 Page Views per month.

A text ad is similar to a banner ad but you are putting text (similar to a Google Ad) on your website.Text ads are different rates for publishers by providers.

The difference can get blurry, but essentially if someone approaches to buy a link placement, you should be careful. Yes it’s easy money, but if search engines like Google ever catch on, then your website could be harshly penalized in lowered ranking. Many webmaster found their website traffic slowed to a trickle as the result.