Etching And Engraving



             


Wednesday, March 12, 2008

Using web fetching to create novel websites

Collecting information from a website and presenting it to your visitors in a different, more useful/interesting format can be a valuable service. It can help attract new visitors and get existing visitors coming back for more.

The best way to collect data from a website is to use their web service if they provide one. Google, Yahoo, MSN, amazon, ebay, technorati and numerous others all offer web services. These are well documented interfaces through which you can easily collect data. The problems come when you want to collect data from a site that doesn't provide a web service.

If a site doesn't offer a web service or some other well structured version of their data then the only option remaining is web scraping. This can be messy, often requires extensive testing and debugging, and will break if ever the target website changes its design. With all these problems it should only ever be a last resort.

The reason it is so difficult is that you are collecting the data you need from the html used to display the website to each visitor. Each site is unique. Each web scraper is also unique.

If the site we are interested in doesn't offer a web service, no rss feed and we can't get the data we need from anywhere else then how do we go about building a web scraper?

The process can be broken down into three parts: get the html of the page, extract the data we need, and then do something with that data.

Depending on how the site you are fetching information from is set up fetching the html could be really very easy or exceedingly complicated. At its simplest all you will need to do is open up a file just as you would a file located on your local server. If you don't need to log in to view the data you want on the site then it may well be this easy. For your sake I hope it is this simple.

If you need to log in to the site to access the data you need then things can get complicated . . . really complicated. I'm currently trying to collect/develop scripts to fetch the contact lists from webmail services such as hotmail. Here the obstacles you must face include cookies and variables in the URL. These problems can be overcome but you'll need plenty of time.

Once you have the html for the page you need to clean it up so that you have just the data you need with no extra text. The best way to do this is with regular expressions. By defining patterns for the data you want you can cut out the chaff and just keep what you need. Unless you are extremely comfortable with regular expressions you may find it easier to use several simpler patterns one after each other. Your script may take a little longer to run but it will be far easier to develop.

Finally you want to do something with the data you gather. This may be as simple as storing it in a text file or displaying it immediately to a visitor to your site. You may also decide to do some more complex tasks with the data. The important thing is that once you have the data you have the choice of what to do with it.

Web scraping isn't easy but the benefits can be considerable. If a web service is available though save yourself some time and use that instead.

TorrentialWebDev focuses on developing the tools to build and promote Web Applications

Labels: , ,

Friday, January 4, 2008

Stretching Can Explode Your Muscle Growth

 by: Nick Nilsson

When you think about gaining muscle, stretching is probably not the first thing that pops into your head. But did you know that stretching plays a critical role in building muscle?

Every muscle in your body is enclosed in a bag of tough connective tissue known as fascia. Fascia is important for holding your muscles in their proper place in your body.

But your fascia may also be holding back your muscle growth. Think for a moment about your muscles. You train them and feed them properly. They want to grow and will grow but something is holding them back. They have no room to grow!

Because fascia is so tough, it doesnt allow the muscle room to expand. It is like stuffing a large pillow into a small pillowcase. The size of the muscle wont change regardless of how hard you train or how well you eat because the connective tissue around your muscles is constricting the muscles within.

The best example of this is the calf muscle. The lower leg is riddled with fascia because of its tremendous weight-bearing duties in the body. It is because of this fascia that many trainers have great difficulty developing their calves.

The solution: stretching.

Using the pillowcase example from above, imagine you can expand the size of the pillowcase by stretching it. Suddenly, the pillow within has more room and will expand to fill that new space.

By stretching your muscles under specific conditions, you can actually stretch your fascia and give your muscles more room to grow.

The key to effective fascial stretching is the pump. The best time to stretch to expand the bags that are holding in your muscles is when your muscles are pumped up full of blood.

When your muscles are fully pumped up, they are pressing against the fascia. By stretching hard at that time, you increase that pressure on the fascia greatly, which can lead to expansion of the fascia.

One of the major reasons Arnold Schwarzenegger had such incredible chest development was that he finished his chest workouts with dumbell flyes, an exercise that emphasizes the stretched position of the pectoral muscles. He would pump his chest up full of blood during the workout then do flyes, holding the stretch at the bottom of the flye. This gave his chest room to grow to amazing proportions.

Fascial stretching is more rigorous than regular stretching but the results can be amazing. When you stretch hard enough to cause the fascia to expand, you will really feel it! When you are stretching the fascia, you should feel a powerful pulling sensation and pressure as the muscle works against the fascia to expand it.

Be sure you do not stretch so hard that you cause the muscle to tear or cause injury to yourself. You will rapidly learn to distinguish the difference between a good stretch and a bad stretch. You should not feel any sharp pain, just a steady pull.

Hold each stretch for at least 20 to 30 seconds as you must give your fascia time to be affected by the stretch. Stretch hard like this only when you have a fully pumped muscle as you must give your fascia a reason to expand. If your muscles arent pumped, just stretch normally.

You can find instructions for stretching at: http://www.fitstep.com/Library/Info/Stretching1.htm

One set of hard stretching after each set you do for a muscle group, besides the obvious benefits of increased flexibility, can have an incredible effect on the size of your muscles and their further ability to grow.

Nick Nilsson is Vice President of BetterU, Inc., an online exercise, fitness, and personal training company. Check out his latest eBook "The Best Exercises You've Never Heard Of" at http://www.thebestexercises.com or visit http://www.fitstep.com. You can contact him at betteru@fitstep.com or subscribe to BetterU News, his fitness newsletter at betterunews@fitstep.com.

Labels: , , , , , , ,