Radified Community Forums | |
http://radified.com/cgi-bin/yabb2/YaBB.pl
Rad Community Non-Technical Discussion Boards >> YaBB Forum Software + Rad Web Site >> Linux shell script to count # hyperlinks. http://radified.com/cgi-bin/yabb2/YaBB.pl?num=1283114394 Message started by Rad.Test on Aug 29th, 2010 at 3:39pm |
Title: Linux shell script to count # hyperlinks. Post by Rad.Test on Aug 29th, 2010 at 3:39pm
I am curious about the number of hyperlinks the site uses.
I was planning to begin (test) counting the number of links contained in the current blog directory: http://mt5.radified.com/blog/2010/08/internet-vs-world-wide-web-plus-origins.html .. which lies inside: /mt5/blog/2010 Inside this directory are all the monthly directories, such as /01 and /02 etc. This script gives me an error: Code:
Error msg: Code:
Ideas? |
Title: Re: Linux shell script to count # hyperlinks. Post by Rad.Test on Aug 29th, 2010 at 3:51pm
Update. I tried to go straight to the monthly directory for January, which contains 5 *.html files.
Code:
I get the same error mentioned above, 5 separate times, one for each file it would seem. |
Title: Re: Linux shell script to count # hyperlinks. Post by Rad.Test on Aug 29th, 2010 at 8:45pm
think i mighta figured it out.
the final character, -l (a letter) I thought was -1 ( a number). Links in January 2010 blog: 464. Links in Movable Type blog for all of 2010 to date: 4270. |
Title: Re: Linux shell script to count # hyperlinks. Post by Rad.Test on Aug 29th, 2010 at 9:28pm
when i ran the script for ALL *.html files in entire site, I get > 100,103 links
when i ran it for *.htm, I get > 159,765 which doesn't sound right, cuz I have WAY more *.html pages than *.htm, which I stopped using long ago. And this includes guides I did not write, such as those by Magoo & NightOwl. I could query those directories and subtract, but not a big number. I don't think the forums are included, cuz those are stored at *.txt files, which I believe the forums script uses to create the web pages. Does a quarter million links (not counting the forums) sound reasonable? |
Title: Re: Linux shell script to count # hyperlinks. Post by Rad.Test on Aug 30th, 2010 at 12:47am
1. The pages contained in Ye Olde Rad Blog v4 contain 4,270 links (.. as of August 30, 2010).
2. The pages contained in Ye Olde Rad Blog III contain 18,973 links. 3. The pages contained in Ye Olde Rad Blog II contain 12,806 links. 4. The pages contained in Ye Olde Rad Blog contain 20,264 links TOTAL: 56,313 .. not counting the guides and daily entries not converted to blog entries (.. with Movable Type). |
Title: Re: Linux shell script to count # hyperlinks. Post by MrMagoo on Aug 30th, 2010 at 6:15pm
Glad you figured out the script. That's a win on its own. You've learned a lot since last year ;)
I'm not sure how accurate of a number the script can produce. What exactly do you want to count? The number of all hyperlinks? The number of things *you* have linked to? The number of links to external sites? All would give you a different answer. Moveable Type produces a lot of links on each page automatically, and I'm not sure if your script ends up counting many of those. I think it would. That's probably also why your .htm pages list so many - some .htm file has a bunch of links that were auto-generated. I think you could probably find a bot happy to crawl your site and give you far more detailed and interesting statistics about your site. |
Title: Re: Linux shell script to count # hyperlinks. Post by Rad on Sep 1st, 2010 at 12:13am MrMagoo wrote on Aug 30th, 2010 at 6:15pm:
Yeah, thanks. :) I *really* would like to count the number of links that I've personally created. But seems improbable. Next best thing would be just the number of links. Comments from the guy who sent me the script: Quote:
AND Quote:
|
Radified Community Forums » Powered by YaBB 2.4! YaBB © 2000-2009. All Rights Reserved. |