Showing posts with label hit counter. Show all posts
Showing posts with label hit counter. Show all posts

Monday, June 4, 2012

Adding a Hit counter Webpart in Sharepoint 2010

As I was working On hit counter for Sharepoint 2007 I also wanted to check if there is anything available for Sharepoiunt 2010 .

And Yes There is a Webpart available on Codeplex which works without any issues .

Before adding the webpart to the page. First create a Custom List, name it as Statistics also create three columns in Statistics list as below:

1.Url    -                    Multiple lines of text
2.Date -                    Single line of text
3.Username -            Single line of text

Give the Contribute – Can view, add, update, and delete permissions for the Visitor and Viewers for the Statistics list, so that visitor/viewers visits also recorded in the list.

To give permissions

1.Go to Statistics list, Settings > List Settings
2.Under Permissions and Management click on Permissions for this list
3.Select Visitors checkbox then click on Actions > Edit User Permissions then select Contribute – Can view, add, update, and delete
4.Click Ok

To know the hit count for all pages in site, you have to place the webpart in master page, so that the webpart code runs on every page where the visitor go and makes the unique entry in Statistics list

Download the Web part from the Below Link
http://hitcounter.codeplex.com/releases/view/35682

After You download the Solution Add the Solution to the Farm using the stsadm command

stsadm -o addsolution -filename HitCounter.wsp

to better understand

stsadm -o addsolution
   -filename <solution file name>
   [-lcid] <language>

Then go to the SharePoint Central Admin => Operations > Solution Management to deploy the solution.
After that go to the Site Collection Features where the solution is deployed and activate the feature HitCounter. Now, the Hit Counter web Part will be available for the users.

You can also deploy the solution using the Command prompt

 stsadm -o deploysolution -filename HitCounter.wsp

Syntax

stsadm -o deploysolution
   -name <solution name>
   [-url] <virtual server URL>
   [-allcontenturls]
   [-time] <time to deploy>
   [-immediate]
   [-local]
   [-allowgacdeployment]
   [-allowcaspolicies]
   [-lcid] <language>
   [-force]

 

Adding a hit counter in Sharepoint 2007 using SharePoint Designer 2007

Today One of my client wanted to add a Hit counter on his page . I informed him about the Site usage Report . However he wanted something that is visible to the users as well .

After a Some Research found that we can add a Hit counter Using Sharepoint Designer 2007 .

* Open The Designer and open teh web page .
* Click the New Document button on the toolbar.
* In Page view at the bottom of the document window, click Design.
* Put the insertion point where you want to create the hit counter.
* On the Insert menu, click Web Component.
* Under Component type, click Hit Counter.
* Under Choose a counter style, double-click a hit counter style, and then click Finish.
To set the counter to a specific number, click to select the Reset counter to check box, and then type the number.

To display a fixed number of digits in the hit counter, click to select the Fixed number of digits check box, and then type the number.

For example, to display the hit counter as "00#" instead of as a single or double digit, click to select the Fixed number of digits check box, and then type 3.

Click OK.

To use the hit counter on the page
1.Put the insertion point before the hit counter object on the page.
2.Type You are visitor followed by a space

For reference : http://support.microsoft.com/kb/825532

Users cannot see the checked out files in the folder/ library

I Came across a Issue today wherein the user opened a ticket for the below issue Issue : Users cannot see the checked out files in the fo...