Menu

Wednesday, August 17, 2011

Submit Blog in Yahoo


This tutorial explains on how to submit your site and its feed in Yahoo.

Step 1: Login to https://siteexplorer.search.yahoo.com/ using your yahoo id. If you don’t have, create it.

Step 2: Enter your site and then Click Add My Site.


Step 3: There are two ways to verify your site. The simplest way is to add the Meta tag generated for you in your blog under the head tag. And then click the Read to Authenticate.


Step 4: After the site has been verified, go to the site that you added and then click the Feeds link. Enter the sitemap xml and click Add Feed.

Submit Blog Sitemap in Bing


Step 1: Login to http://www.bing.com/toolbox/webmaster/ . If you don’t have id, create it.  Click on the “Add Site” button which is on the homepage of the webmaster. Enter your site URL in the pop up and then click submit.

Step 2: To verify the ownership of the site, just copy the Meta tag which is given in the “Option 2”. Go to your blog and Edit the html and paste it under the head tag. Once you added the Meta tag, click Verify.
This will take some time to crawl your site.




Step 4: once you successfully added your site, go to Crawl tab and then click Add Feed which will pop up a window. Enter your sitemap xml URL and submit it.
That’s all. You have successfully submitted your blog sitemap in Bing.



Submit Blog in Google


This tutorial explains on how to submit your blog and its feed in Google.


Step 1: Log into Google webmaster with your Google account. If you don’t have Google account, create it. https://www.google.com/webmasters/tools/

Step 2: Click on the Add a site button and then add your site.


Step 3: Verify the ownership of your blog by following any one the method explained. Simple way is to copy paste the Meta tag on your blog.  Once you added the Meta tag, click on the verify button.



Step 4:  After your site has been verified, click on the Sitemaps link under the Site configuration.  Click on the Submit a Sitemap button and then add your sitemap URL.

That’s all. You have successfully added your sitemap. Wait for Google webmaster to crawl your website.


Related Articles:

Submit Blog in Ask.com

Tuesday, August 16, 2011

Submit Blog in Technorati

This tutorial explains on how to submit your blog in the Technorati Site.

My Technorati claim token: U8YUHZB4P55Y

Step 1: Log into http://technorati.com/. If you haven’t an account, create it.

Step 2: Go to your account http://technorati.com/account. At the bottom of the page, you can find a section to add your blog. Enter your blog URL and click Claim.


Step 3: Enter all the necessary information to claim the blog and click “Proceed to next step” which will be at the bottom of the page.



Step 4: The Technorati will send you mail about the claim Token. Create a post on your blog and add this token in the body of the post.  Once you complete this, go to your Technorati account, and click the “Check Claim” button.

That’s all. You have successfully submitted your blog in Technorati.

Monday, August 15, 2011

Delete Facebook Page

This tutorial explains how to delete a Facebook page that you have add on your Facebook account.


Step 1: Log into your Facebook Account.

Step 2: You can see the “Pages link” on the left side of your Facebook homepage. It can be easily identified by a flag symbol. If you have only one page, the page name will be shown instead of “Pages”.

Click on that link which will list out all the pages that you have added on your Facebook.  Click on the page that you wish to delete.

Step 4:  Click on the Edit page and then click on the Manage Permissions tab.  At the bottom of the page, you can see a link: Delete page - Permanently delete XXXX where XXXX is your page name.

Click on that link which will open a confirmation dialog box. Click delete button.
That’s all. You have successfully deleted your fan page.






Sunday, August 14, 2011

Create Facebook page


How to create a page in Facebook?

Step 1: Login to Facebook with your account.

Step 2: Click on this link to create a page http://www.facebook.com/pages/create.php

Step 3: Click on any link which suites to your page. Here I want to create a page for my Favorite Books, so I have selected the Entertainment template. Add profile photo and fill up basic information required for your page. That’s all. You have created a Facebook Page successfully.



     

Add Facebook app to facebook page



How to add Facebook App that you created to your Facebook page?

Step 1: Login to https://developers.facebook.com/apps with your Face book account. Once you login, you can see your apps home page where all your apps will be listed out.

Step 2:  Click on the app which you wish to add on your Facebook page. And then click on the Edit button which is on right side of the Settings.


Step 3: Once you click on the edit button, you will navigate to the Applications profile page. Click on the “View App Profile Page” link.

Step 4: Click on the “Add to my page” link which will pop a window and list all the pages that you have already created. Select the page and close the window. Now you have successfully added your application into your page.

How to add Facebook Developer App?


How to add Facebook Developer Application to your account?

Step 1: Log into Facebook with your account.

Step 2: Click on the below link to add the developer application into your account

Step 3: This application will ask permission to access your account information. Click on the “Allow” button.



Now you have successfully added the Developer Application on your account. The home page of your developer apps will be like this.


Monday, August 8, 2011

Linux Command - xsltproc

Xsltproc – It is a Unix/Linux command line tool to transform the XML file into an Html or XML file.

# xsltproc  [OPTIONS]  stylesheet-file  input-xml-file

# xsltproc  - -output  books.html books.xsl books.xml


XSLT

XSL stands for "Extended style sheet". It is a style sheet for xml file.

XSLT stands for "XSL for Transformations".  It is a tool to transform XML document into an Html document or into other type of XML documents.

In the below example, the xml file is transformed into an HTML file using the XSL file.

Here is a sample XML file which describes the books and its author.
 
<books>
 <book price="$35" author="Kathy Sierra">The Head First EJB</book>
 <book price="$18" author="Martin Fowler">UML Distilled </book>
 <book price="$27" author="Bill Dudney">Mastering Java Server Faces </book>
</books>
 

Consider we want to translate the above XML into below Html file.
 
<html>
 <head></head>
 <body>
 <div id="books">
  <ul>
   <li><b>The Head First EJB:</b> $35 : Kathy Sierra</li>
   <li><b>UML Distilled: $18 :</b> Martin Fowler </li>
   <li><b>Mastering Java Server Faces:</b> $27 : Bill Dudney </li>
  </ul>
 </div>
 <body>
</html>
 

Here is the XSLT file which converts the XML file into above HTML format.
 
<?xml version="1.0"?>

<!-- Include this tag, so that it will be identified as a XSL stylesheet -->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<!--This tag tells that the output should be transformed into Html-->
<xsl:output method="html"/>

<!-- This template processes the root node i.e / -->
<xsl:template match="/">
 <html>
 <head>
  <title>My Favourite Books</title>
 </head>
 <body>
  <div id="books">
   <ul>
    <!-- Apply a template to process each book tag -->
    <xsl:apply-templates select="books/book"/>
   </ul>
  </div>
 </body>
 </html>
</xsl:template>

<!-- Template to process book tag -->
<xsl:template match="book">
 <li>
  <!-- Get the value of the text node -->
  <b><xsl:value-of select="." /> :</b>
  <!-- Get the value of the price attribute -->
  <xsl:value-of select="@price" /> :
  <!-- Get the value of the author attribute -->
  <xsl:value-of select="@author" /> 
 </li>
</xsl:template>
</xsl:stylesheet>
 


Wednesday, July 27, 2011

JQuery - Accordion


1. Include the necessary JQuery's scripts and css in the head tag.
    For Accordion, the jquery-ui must include accordian and widgets related scripts.
    You can download it from here.
<script type="text/javascript" src="scripts/jquery-1.5.1.min.js"></script>
<script type="text/javascript" src="scripts/jquery-ui-1.8.14.custom.min.js"></script>
<link href="css/jquery-ui-1.8.14.custom.css" rel="stylesheet"></script>

2. Include this script in the head tag
<script type="text/javascript">
$(function() {
$('#section').accordion();
});
</script>

3. Include this html in the body
<div id="section"> 
  <h3><a href="#">Section 1</a></h3>
  <div> This is section1.</div>

  <h3><a href="#">Section 2</a></h3>
  <div>This is section2.</div>

  <h3><a href="#">Section 3</a></h3>
  <div>This is section3.</div>

  <h3><a href="#">Section 4</a></h3>
  <div>This is section4.</div>

  <h3><a href="#">Section 5</a></h3>
  <div>This is section5.</div>
</div>

View the complete code here.  This example output

JQuery - UI Tab

Download the necessary js and css file from here. I have downloaded these files with smoothness theme.

<html>
<head>
    <script type="text/javascript" src="scripts/jquery-1.5.1.min.js"></script>
    <script type="text/javascript" src="scripts/jquery-ui-1.8.14.custom.min.js"></script>
    <link href="css/jquery-ui-1.8.14.custom.css" rel="stylesheet"></script>

    <style>
    #tabs{
      width: 300px;
      font-size: 12px;
    }
    </style>
    <script type="text/javascript">
       $(function() {
           $('#tabs').tabs();
           //Tab on mouse over
           //$('#tabs').tabs({event: "mouseover"});
       });
    </script>
</head>

<body>
  <div id="tabs">
    <ul>
      <li><a href="#book">Tab 1</a></li>
      <li><a href="#tab2">Tab 2</a></li>
      <li><a href="#tab3">Tab 3</a></li>
    </ul>
  <div id="book">
      <p>A combination of economic factors resulted in Indian expats waking up this morning to find that the rupee had strengthened considerably – directly hitting their savings.</p>
  </div>
  <div id="tab2">
      <p>Norwegian police said they mistakenly released an alert on Wednesday saying they were searching for a man who identified with mass killer Anders Behring Breivik.</p>
  </div>
  <div id="tab3">
      Content of the tab 3
  </div>
</div>
</body>

</html> 

The tabs will be like this



Tuesday, July 26, 2011

MySql - User related commands

  • 1. How to create user?
    • CREATE USER username@host IDENTIFIED BY password
    • Ex: CREATE USER 'akila'@'localhost' IDENTIFIED BY 'akila';
  • 2. How to set password for the user?
    • # SET PASSWORD FOR username=PASSWORD(password);
    • Example: # SET PASSWORD FOR 'akila' = PASSWORD ('akila');
    • # UPDATE mysql.user SET Password=PASSWORD ('AKILA') WHERE user='akila' AND host='localhost';
  • 3. How to grant permission?
    • GRANT ALL PRIVILEGES ON database TO 'akila'@'localhost' IDENTIFIED BY 'akila';
  • 4. How to switch to another user?
    • # mysql -u user –p
    • Enter Password:
  • 5. How to show users in the database?
    • SELECT * FROM mysql.user

Sunday, July 24, 2011

Install tomcat in windows

  1. Download Tomcat from the below site. http://tomcat.apache.org/
  2. Set the following environment variables in the User or System variables.  See this article to set environment variables. How to set environment variables in windows?
    • JAVA_HOME = location of the JDK
    • CATALINA_HOME = Location of the Tomcat server
    • PATH = Add CATALINA_HOME\bin directory in the path variable
  3. Go to CATALINA_HOME\bin directory in the command prompt and run the startup.bat file.
  4. Run this http://localhost:8080/ URL in the browser to verify tomcat installation. By default tomcat will run on 8080 port.

     Related Articles:

     How to add Tomcat as a service in windows?
     How to change the Tomcat's default port no?

How to set enviroment variables in windows

Right click on the Computer --> Click Advanced system settings --> Click Environment Variables


Javascript - Load XML string

The below javascript example explains how to load XML string into Dom object.


 
Books
Bind a callback function after Dom is ready.
$(document).ready(function(){
    //Code here
});

or

(function($){
    $(function(){
          //Code here
    });
})(jQuery);