Kitaro Nishida Quote from McLaren Park

Thinking has its own laws. It functions of its own accord and does not follow our will. To merge with the act of thought – that is, to direct one’s attention to it – is voluntary, but I think perception is the same in this respect: we are able to see what we want to see by freely turning our attention towards it.

Kitaro Nishida

The Semantics of HTML and Web Sites – Why Markup Matters

Creating websites for 13 years now, I have seen the evolution of websites from clunky table based layouts that were semantically just a bunch of noise to the current HTML5, semantically charged creations. Of course the leaders in Web Standards and semantic HTML have been people like Jeffery Zeldman and his disciples, great CSS exercise sites like Zen Garden and also the blog sites and open source world, probably most importantly WordPress. If you want to make a web site theme that then someone else can take and run with, the semantics of the markup have to be solid.

I am amazed at how understanding semantics in both web design and programming gets overlooked. I still know many web designers who do not understand what a heading tag is. They are often so lost in the fonts and backgrounds and images that they forget what is going on in the hierarchy of information. I have witnessed decent designers never realize that <h1>What a Killer Page</h1> is what is essential. This is not only for SEO but also for making the web site accessible on a variety of platforms. I still know amazing developers who can talk your ear off about Object Oriented Design Patterns who when they get to the HTML will code a heading tag as <div class=”main-header”> What a Killer Page</div>. I am not sure if this is because they just read stuff too quickly and never really read chapter one and think they know everything, or maybe they just don’t get it. Struggling with the margins of a <p> tag does not mean you should then use a few <br /> tags. Strange.

In HTML, if you take away things like the required html, body and title tags, the important semantic markup is pretty simple.

  • Headers h1,h2,h3,h4,h5
  • Paragraphs <p></p>
  • Lists <ul><li></li></ul>
  • Tables <table><tr><th></th></tr><tr><td></td></tr></table> (for tabular data)

That is really it! Markup such as divs and spans are not semantic. They are presentational! Putting things like navigational lists into divs is just wrong. The sooner one learns this basic distinction, the faster you will write cleaner, easier to maintain code.

In HTML5 the list of semantic markup grows longer. I will not enumerate them here but to me one of the main objectives of HTML5 is this semantic markup. <section></section>, <article><article>, <video></video>.

So there you have it. Just think. If you are just starting to write HTML, you got to avoid the 7 year era of table based layouts and nested tables seven layers deep just to keep you debugging for and hour all for the crappy browsers of the day.

How to Create Your Own File-Based Image Galleries with php, ftp, Shadowbox and a Groovy File Structure

or perhaps titled:

I don’t trust anyone with my photos, not Flickr, not Google and especially not Mark Zuckerberg!

Requirements

  • Linux Hosting Account (php enabled)
  • ftp program for uploading files

Implementation

History
Many years ago, in the dark ages of web development, when I had a Windows hosting account, you know one of those $4.95 a month deals, and I wanted to post lovely photos of my kids and vacations, I would do it a state of the art way. I’d open Photoshop 7 and chose “Create Web Gallery.” I would then wrestle the various dialogue boxes into submission and create a Web Gallery. It worked. It looked cool. It used tables for layouts. I was a genius.

Last year I closed my Windows hosting account. Never use webhost4life. It is a terrible hosting company. As I was doing a lot of Word Press, I chose BlueHost. So far so good.

Now I could have just uploaded all my old Photoshop galleries to my new hosting account but this seemed lame. I did not want to use any Web 2.0 stuff, in other words startup companies just waiting to be bought out and make your life really complicated, but I did want to use ftp to upload files. So with a little php, notably scandir, I created a way to display all the photos in lovely paging galleries.  The first time a particular gallery is accessed, it creates a folder of thumbnails in that directory named ‘thumbs.’ This makes the pages load faster.  Larger versions of the images utilize Michael Jackson shadowbox, still one of my favorite lightboxes  There is no indexing for searching, or meta tags, but to be honest, I would never get around to entering this sort of data. Maybe in the next version, I will add this feature.

A few key elements (let us say features and recommendations) of “Paul’s Amazing php Photo Gallery” are

  • Name your folders like this 2012-08-New York. The folders will display by replacing the dashes with spaces and are ordered in descending order.
  • Process your images to 1200px wide. This way they will look great when large, but not so big it takes forever to see a gallery.
  • All gallery images have a lightbox large image version. Go shadowbox!

that’s it…
Enjoy!

2012 Hardly Strictly Bluegrass Festival Highlights

Last year I was in Tennessee at a wedding. This year I was able to check two days of the 2012 Hardly Strictly Bluegrass Festival in San Francisco. Unlike past years, I did not have any known friends who were doing early morning squatting, marking out terrain, so I would be flying solo, moving between stages and looking for good listening and viewing spots. I caught Saturday and Sunday afternoon shows. Overall, it seemed like the festival was extremely well attended and each day I ran into people who traveled to San Francisco specifically for the festival. Met some nice people from San Diego, LA and Denver.

For me the best show was DOUG SAHM’S PHANTOM PLAYBOYS featuring: dave ALVIN, steve EARLE, delbert McCLINTON, boz SCAGGS, jimmie VAUGHAN… and whoever the cat drags in.… The rhythm section was right in the pocket and the band played a lot of different grooves. It all seemed effortless. The horn section was outstanding. The guitar solos outstanding pieces of R&B soul. For this show, I listened by a tree, stage right and it turned out to be a great spot. You could see the band the acoustics were good. This show had great sound.

A few interesting acts I caught were “The Cowboy Junkies” who I had never heard of feature a decent harp player. I enjoyed the brooding lead female singer who was very different from some of the earlier acts I heard. I also caught Patti Smith whose music I did not know, but whose name is well known. She brought a decent young rock and roll band and her music has this powerful, self-empowering message. Very nice.

So much music. So little time. Another fine year at the 2012 Hardly Strictly Bluegrass Festival. Next year, I really got to make it for Friday night too.

Toots Thielemans Solo on “Don’t Blame Me” – Jazz Harmonica Transcription

We all have all been listening to Toots and probably never knew it. Paul Simon records. Film scores like “Midnight Cowboy.” He basically put the modern, chromatic harmonica on the jazz and popular music map. I am presently on a personal project to transcribe a bunch of his solos. In this post, I present his solo on the album “Man Bites Harmonica” and the song “Don’t Blame Me.”

Of course, with these sorts of transcriptions it is best not to just read the take down. It is best to listen to the solo and get into it and transcribe it in your head. Perhaps the hardest thing is getting to know his phrasing. Toots has a very fluid way with his lines. It often seems like he is at a cocktail party – he sort of stumbles around the hors d’oeuvres, moseys towards the bar then says high to woman by the dessert table. His style is instantly identifiable. Do not be tempted into thinking his music is lightweight as he makes it all sound so easy. The guy knows his stuff and has serious chops.

Toots Thielemans Solo- Don’t Blame Me (pdf)

10 Toots Thielemans Chromatic Harmonica Solos – Transcribed and Analyzed

By Paul Lyons

TenForToots_tn

Now available at Lulu Press

An in-depth look at the style of one of the great improvisors of the last 50 years. Excellent for not only chromatic harmonica players, but jazz players of all instruments.

Table of Contents

Introduction – 3

Why Transcribe – 5

Don’t Blame Me – Man Bites Harmonica! (Riverside, 1958) – 6

Three In One – Man Bites Harmonica! (Riverside, 1958) – 11

Sno’ Peas – Bill Evans Affinity (Warner Bros., 1979) – 18

Blue in Green – Bill Evans Affinity (Warner Bros., 1979) – 20

Jesus’ Last Ballad – Bill Evans Affinity (Warner Bros., 1979) – 23

Only Trust Your Heart – Only Trust Your Heart (Concord Records, 1988) – 26

C To G Jam Blues – Footprints (Polygram Records, 1991) – 30

Felicia and Bianca – The Brasil Project (BMG, 1992) -36

Coisa Feita – The Brasil Project (1992, BMG) – 38

Everybody’s Talkin’, Midnight Cowboy: Original Motion Picture Score [Soundtrack] (1969) – 45

Conclusion – 48

References – 48

Etudes – 49 – 80

Bootstrap Carousel – Two on the Same Page – A Clean Example

[do_widget id=woocommerce_products-3]

See a Complete Example


NOTE: It is so funny really, that this post is viewed more than any other on this site. If you are trying to put two carousels on a page it is simply a problem that you need to understand selectors.
If you need web development or are interested in my web development posts, it has moved to
http://www.paullyons.info/blog.
Paul Lyons
11/1/2014


There is really two ways you can find great new platforms and technologies when building websites. You can tirelessly scrape the web, subscribe to podcasts go to blogs, subscribe to twitter feeds. All of this is but one route. Another is just to get a job in the industry and have to deal with some out-sourced vendor’s code. I tend to be someone who does the later.

And so I found myself dealing with the Twitter Bootstrap world – http://twitter.github.com/bootstrap/ defined as

“Sleek, intuitive, and powerful front-end framework for faster and easier web development.”

At a tidy 25k minified it definitely raised my eyebrows.  So I dove in and took a look around.

I was having a hard time with the project I was working on having two Bootstrap Carousels on the same page.  In the past I had always used a jQuery plugin called BxSlider. So I tried to isolate the problem and still I was stumped. The code was very modular with good name-spacing but the js file just rambled on.  So I looked at how it was instantiated.

What I discovered with bootstrap is that it is best, dare I say “best practice’ to call your jQuery plugin with a selector not used in the plugin. For example, the Carousel plug-in uses .carousel as a class in the code. So doing a

$(document).ready(function(){
$('.carousel').carousel();
});

will just create issues if you put two bootstrap carousels on the same page. The class ‘.carousel’ is used in the bootstrap plugin.  Instead do


$(document).ready(function(){
$(‘#carouselName’).carousel();
});

Where #carouselName’ is of course the id of the carousel.  So I had two of these lovely carousels and could then instantiate them with

$(document).ready(function(){
$('#oceanCarousel, #musiciansCarousel').carousel({
interval: false
});

});

Another issue that I had to deal with is the concept of having more than one img showing at a time. This can be accomplished with simply putting more than one image in the active div

<div class="active item">
<a href="#"><img src="../images/small/ocean01.jpg"></a>
<a href="#"><img src="../images/small/ocean02.jpg"></a>
<a href="#"><img src="../images/small/ocean03.jpg"></a>
</div>

You will not be able to have the carousel move just one image at a time as you can with BxSlider but so be it. A few important notes. It is best to use the entire bootstrap.js even though they have individual versions for each plugin. I think the pure CSS previous and next buttons/arrows that come courtesy of the base bootstrap css are the bomb but of course IE makes them square but then who cares about the people who see the web with IE anyway.

Hope this post makes your day easier.

 

First Glance – Surfing Ocean Beach in San Francisco

I remember a day in about 1989 before I surfed. I had moved to San Francisco from some landlocked state without an ocean. I lived in the Mission on Valencia when you could find phone booths every four blocks or so and traffic was two lanes deep in both directions. Valencia was sort of a wasteland of old hardware and appliance stores, corner stores, a few Mexican restaurants but not much else. It is hard to imagine but true. If you rode a bike, you took your life in your own hands and probably were honked to the sidewalk. There was only one café that I can remember. Things have sure changed.

Anyway, I still remember that day. It was December and we took a drive out to Ocean Beach, the usual route, out San Jose to Brotherhood Way around the lake to hang out at the ocean. Maybe play a little Frisbee. When we came over the knoll by the wastewater treatment plant and looked towards the ocean we where greeted by quite a sight. It was a crystal clear winter day and the swell was huge, probably breaking on the outer bars. I had never seen waves this big and it made no sense at the time because there was no wind. I had always associated larger waves with thunderstorms and windy weather. We pulled into the parking lot and were simply amazed. It was like we were visiting another planet. The waves were these massive towering things that broke way out to sea.

It took about four years until I started surfing, courtesy of a Brit with a few garage sale wetsuits and equally lousy boards but a hefty amount of adventure and craziness. Due to proximity I definitely call OB my home break.

So last Friday I drove out to take a look. I doubted I would surf as I knew the waves were crappy. I just really wanted to hear the waves and smell the brine. When I got to the parking lot the wind was blowing hard from the Northwest but I realized my timing was perfect. I could take a photo of a dump truck dumping a bunch of sand and a guy driving a bobcat pushing it around. I knew this Ocean Beach Sand Management Project was going on and probably in the back of my mind I was curious how far they were along. You can read about the project here http://www.parkplanning.nps.gov/projectHome.cfm?projectId=42876.

I know they are spending a month moving sand from north to south and dumping it at my spot but in the end it is just an experiment. They are simply going to see where the hell it ends up. It probably will change the sandbars down there and it will be interesting to see what happens from a surfing perspective. Maybe they are setting stuff up for us for the fall surf season – like baseball umpires dusting off home plate. But I hate to tell them this. Anyone who has surfed that place in the winter knows that the ocean always wins in the end. If the ocean wants to eat a parking lot for breakfast, there is nothing you can do about it. A big December swell and a 6.2-foot high tide and half that sand will end up back were it came from. Anyone who surfs OB has a story about how far they drifted knows that stuff moves around down there, especially in the winter and a few dump trucks of sand is really just a small inconvenience to the big mama.

Which brings me back to the first time I saw a big swell at OB. To this day, when I go surfing and I make that same drive, when I drive over that knoll by the wastewater treatment plant, I turn off the radio and sort of hold my breath in expectation. Right away when you go over and get that first glimpse you can tell if it is going to be good or bad. Nasty or lame. Marginal or sublime.

NOTE: This essay first appeared on The Stoke Report as a Rant.
http://stokereport.com/rant/first-glance

Our Local Lawn Mowers

Driving on Saturday along Felton by the water reservoir I took in a curious sight. Fifty or so goats on the other side of the fence grazing away. They caused a bit a scene as cars stopped and locals had to check it out.

Goats Grazing on Felton Street in San Francisco

Monday Nights at The Union Room at Biscuits and Blues – Mike Olmos and Jeff Mars

It is Monday night. You are looking for some great music in San Francisco. Somewhere were you can hear some of the local best tear it up.. Look no further. Mike Olmos and Jeff Mars hold down the Monday night jazz gig at The Union Room at Biscuits and Blues. Starts at 7:30pm. Ends around 11:30pm. Cover from $5-10 depending on your participation energy. A lot of music for your money as the band is never playing it safe and over all the playing is about the best in town. Creative, inventive and virtuosic. To round out his glowing review I must say that the room has excellent sound, the piano is in tune and the vibe is a friendly.

I hear the food is pretty good too.

Mondays – Mike Olmos Jazz
The Union Room at Biscuits and Blues
401 Mason Street San Francisco CA
415-931-6012
By Union Square

General admission: $10 ($5 for Musicians)
Door 6pm;
Show 7:30pm – 11:30pm

“Into the Wild” by Jon Krakauer – Alexander Supertramp – The Real Deal

 

I was flying back from Mexico and the plane was delayed a few hours. By the time I landed in San Francisco I had finished the entire book “Into the Wild” by Jon Krakauer. This “coming of age” book traces the journeys of Chris McCandless and others including the author. They are all gripping tales and the book is extremely well written. Of course the main story is about Chris McCandless and his American odyssey, hitchin, hopping trains and floating around the west that he undertook after graduating from college. Every so often a character like McCandless comes along, influences people in very positive ways, travels far and wide and then dies tragically. At this point they enter the public conscience and become a sort of symbol for approaches to life, spiritual values, materialism and the meaning of existence.  Of course, how this enters into the public dialog is often just as much about the art that then is created around the person.

Jon Krakuer’s book “Into the Wild” captures the spirit of the topic extremely well. It is seemingly well researched and the inclusion of chapters about various other young explorers and free thinkers, including Karkuer, make it even more profound. One sees the yearning of McCandlesss as not a freak sort of occurrence but as something that is universal and timeless. People have often left civilization behind, with a head full of ideals to live an acetic life enjoying only the simple pleasures. It has an appeal to most everyone on some level.  Krakauer intersperses quotes of various transcendental writers, Thoreau, Stegner, Muir, Tolstoy among others that McCandless was reading that influenced his thinking during the trip. These quotes begin the chapters and give the book a sort of depth and gravity.

On the other hand, the movie “Into the Wild” directed by Sean Penn is but an admirable attempt to take on the subject. The casting is brilliant; the cinematography is spot on, the dialog adequate. Where it falters is that it tries to be too much like the book. For example, quotes of the same transcendental writers flash across the screen but this never has the effect as it does in print. Irritatingly, some of the quotes do not even credit sources.  Furthermore, the sound track is a scrapbook with bits from a Canadian film score guitarist, pedestrian tunes from Pearl Jam and generally a lot of music that does not add to the film. The American West is about open spaces and great silence. The movie could have used this sparseness. Instead, it feels a bit like we are on a high school field trip bus  and it is noisy and rushed.  To be fair, the one piece I liked was some transition music by Kiki King. Do not get me wrong, I enjoyed the movie immensely, it is just that taken as a whole the book, as often is the case, is better.

So if you have already seen the movie, try to forget what you saw and read the book. If you have read the book, read it again. By the end you may want to figure out where your old backpack is in the dusty basement.