Archive for Uncategorized

A Life Changing Event

I wanted to share a recent event, without worrying anyone at the same time. It will be talked about at length on the PHPUgly Podcast, Episode #123, recorded 10/4/18. If you are reading this after about 10/9/18, go look for that episode.

TL;DR; I had a mild heart attack on Saturday 9/29/2018, but I am fine.

On Saturday evening, around 9:00pm, after the kids were in bed and my wife was out at book club with her friends, I noticed a weird discomfort in the middle of my chest, straight through my back. I thought it was odd, but I didn’t have any other symptoms like pain shooting down my left side, etc… The stuff we always hear about.

Earlier that day, we ran a 5K with the kids, pushing both of them in a stroller for a good portion of it. Then we went to a beach town, had lunch, and I ended up carrying both boys at the same time about 1/4 mile back to the car. So when this all happened Saturday night, I assumed that I had strained something. I really felt like I just needed to pop my back.

I had trouble falling asleep that night. My mind racing, feeling my heart beat… I was scared. I got up, did some reading and of course read everything from OMG Get To The Hospital NOW, to it could be inflammation. So I took some Advil, and finally got some sleep.

I woke up Sunday morning feeling 95% better. I lied to myself and others that I was 100% better. I had plans that day with the kids and nothing was going to stop me from being with them for that day. As I write this I realize the irony and am crying. I chose one day over possibly the rest of their lives. I had plans for the 3 of us to go get our haircuts together and then go to a baseball game. Nolan’s first, and we got to watch from a Suite.

While at the game, I noticed my chest more and more. I made the decision that I’d finish the game, get the kids home, fed, in bed and then I’d go have it checked out. I still really thought it was a strain, that I was just going to have it confirmed real quick that night. I got home, told Jacki my plans and she told me to go right away. She would take care of the kids. I had convinced her as well that it was nothing.

Geeze I’m balling as I write this… pull it together man… (Ok I was distracted by work which helped calm me down… where was I…)

Got to the ER, even the person checking me in asked if I did anything to strain the chest wall. Kind of confirming what I thought the issue was. So I was relieved. I went through the tests, EKG nurse said it looked ok, had blood drawn, etc…

Then the doctor saw me. He told me about an elevated protein in my blood called Troponin. Then he said, “I’m going to just be blunt, you had a mild heart attack, and may still be having it”. He went on to tell me the normal level is 0.2 or lower, and mine was a 6. I needed to be transferred to another hospital that had a cardiology unit. By the time I left the hospital, my Troponin level reached 10.2.

I went in for an Angiogram the next morning. Luckily all they found were 3 very small blockages. Unfortunately, they were in branches of blood vessels that couldn’t be opened up or stented.

So now I’m on a ton of medications, and need to change my lifestyle (luckily only a little).

Conclusion: I’m an idiot for waiting. But I will make a full recovery and will live a long happy life and be here for my kids.

 

PHP|Architect being acquired by Musketeers.me

To me this is HUGE news in the PHP World.

If you are in the PHP community and don’t know PHP|A, then you have been missing out.  I learned about them when I decided I HAD to grow and improve my skillset.  I was a sole developer that was stuck.  I wanted to be better, but to do so, you have to work with better people than you are.  So I set out a goal of learning things, and luckily enough I kind of knew what I was looking to learn.  Part of my whole speech about needing to know what you don’t know.

PHP|A offers a magazine (used to be in print, maybe again soon?), books, trainings, and conferences.  The conferences are what first drew me in.  I attended TEK-X, back in May of 2010 and thus start of the new me.  Within 2 years, I completely transformed myself for the better, and made some huge life changing decisions.

I met all of the members of Musketeers.me while on my new quest.  I met @EliW first at Tek-X, and while he won’t remember it, I certainly do.  I got to hang out with a large group of people in his room playing Rock Band until late in the night.  I was very shy that year, and stayed to myself.  I met the rest of the team (@omerida, @SandyS1, and @kevinbruce) this year at Tek12.  I talked with them way more than I thought I would have, and it was a great experience.

The Musketeers were the team behind MojoLive.com, until funding ran out and the backers pulled the plug.  At least this is how I interpreted the story.  They decided they liked working together and formed a new company called Musketeers.met.

This is a great story for potential PHP startups.  I am looking forward to what comes of all of the changes at PHP|A.  Will the conferences continue?  If so, will they be as good as they were, or better?  Congratulations GUYS!!!

 

VimDiff: How Have I Not Used This Before?

Ok, I have been using Vim for about 15 years now, and even did a whole presentation on vim at my SD PHP Meetup, and had a reference to vimdiff in one of my slides. But honestly I have never used it.

WOW, what a great tool. Here are a couple of links that I found useful.

http://www.debianadmin.com/vimdiff-edit-two-or-three-versions-of-a-file-with-vim-and-show-differences.html

The video shows you how to use vimdiff as your git diffing tool.
http://www.youtube.com/watch?v=hb5RVnOda2o

One thing to add. If you follow the steps for using vimdiff as your git diff external tool, make sure to add this to your .gitconfig
[pager]
diff =

Otherwise you will get errors.

Also, when editting more than 2 files at once, those shortcuts won’t work.
Instead of :dp, use :diffput b#
Instead of :do, use :diffget b#

b# is just a number of the window pane starting at 1, counting left to right.
Shorthand :diffpu or :diffg

 

Do Not Hire Or Be A Sole Developer

I was a sole developer for bowlingball.com for eight years. While there, I was very happy to be the only tech person. I was able to do things my way. There was even an employee that encouraged the owner to outsource the programming, and to get rid of me. Needless to say, I was very unhappy when I heard this.

Looking back… being a sole developer is bad for both the company and the developer themself.

    For Developers:


Developers should strive to be part of a team. It is so hard to grow by yourself. If you have to be willing to put yourself out there and work very hard to learn. If you have co-workers, you will learn from each other. Someone will have your back if you make a mistake. Learning best practices is easier with more people.

    For Companies:


If a company can not afford to hire at least 3 people, they are doing themselves a disservice by hiring any. What happens when that person leaves? Who’s double checking that person? Did you really hire the “Best” you could?

Outsourcing to a group of developers is not necessarily as expensive as it sounds. Sure, per hour you may pay more, but you are basically buying the experience of a group of people. If someone leaves that group, there are others that can pick up where they left off easily. You should not be left hanging in a transition. You are not paying an employee when they are not working to 100% productivity or for them to spend time learning.

    Conclusion:


In the end, a sole developer really isn’t good for either party.

 

The Pragmatic Programmers: Practical VIM Review

I gave a presentation at SD PHP on Vim, and when I got home from giving the presentation, I had this book sitting on my doorstep. A little late for my presentation, but that’s probably a good thing.

All I have to say is WOW. I am going to have to give another presentation from just the new things I’ve learned. This book is not for beginners by any means. And if you think you know Vim well, I would say pick this up and have your mind blown.

I have been using Vim daily for over 14 years. It’s how I write code, which is how I make a living. The book starts off with the dot (.) command. Which is very useful, but not the first thing you would learn in Vim. I have used that command extensively for years. But nonetheless, with that kind of start, I knew that starting there meant the book would be advanced.

I am currently at page 33, and have said OMG many times with the cool things Vim can do, that I had no clue about. Based on this alone, go get this book. 5 out 5 stars/elephants/candy canes, whatever you want to use.

Practical Vim: Edit Text at the Speed of Thought

 

Solved: Facebook sharer.php Not Working for Some Reason

So, we have a ton of share links all over our various domains at work. And much of our domain structure is based on users have subdomains (example: JohnCongdon.herbalhub.com).

All of a sudden, the sharer.php seemed to stop working. Some browsers stayed white, Chrome showed a grey error message with a 500: internal server error.

It took me a long time to track down the problem. I tried so many different things, but in the end, it was the CASE of the subdomain. 🙁 Changing it to johncongdon.herbalhub.com solved the issue. So strange, undocumented, and frustrating.

I hope this helps someone down the road.

 

Running a PHP User Group (2 Months In)

Running a user group was not in my thoughts prior to 2011. I joined Orlando PHP Dec 2010, but there was an hour commute. Then Daytona PHP started back up, and I was thrilled. Except they had 1 meeting and fell apart. 🙁

I planned on starting Daytona PHP on my own, but due to waiting for the OK from my then employer to use their conference room and then deciding to move to California, I put that idea to rest.

I started looking for a PHP Group in San Diego and was surprised to see that one did not exist. It became my goal to start it up (well start it up again, there used to be one). I had everything in place before I even moved.

Running a user group has to be one of the most satisfying experiences I have had in a long time. The people are great, and I have been very lucky to find members that want to be part of my team and co-organize. I was lucky to find a host that would provide space and pizza for the group.

We have had 3 meetups so far, and there have been a few regulars, which tells me something is going right. 🙂

 

Bluetooth Headset Purchase

After spending some time doing a lot of research, I settled on ordering the Motorola S10-HD.  I read some great reviews, some not so great as well.  We’ll see and I will post once I have them in hand.

 

 

Why You Should Not Style Major Elements

I have done this to myself many times.  Have you ever thought, I want all my tables to look like XYZ.  So you throw table { border-color: blue; … } into CSS.

The problem is now you are stuck with that for all tables.  I think you should have a table style like table.blue_border { border-color: blue; …} that you can now apply to only the tables you want to with <table class=’blue_border’>.

You will inevitably need a standard table somewhere without the same style as the rest, but now you have to do more work to make that happen.  Do yourself a favor, use a reset for all HTML elements, and don’t style them directly.  Style a class that you will put on those elements.

 

 

Feature I Would Like To See On PHP Tek Schedule

I am attending php tek12 next week.  One thing that I think the tek team should do is make it super simple for me to choose the sessions that I want to attend.

My vision: Since the majority of each session on the schedule page is a link, maybe add a check box/radio bottom for each time slot.  This would dim the other 2, making the ones I want to attend standout.  The printed version would look nicer.

Also, if I am logged into phparch.com, a simple ajax call to store my choices, so when I came back, it would be all preselected set for me.  And I could make changes if I wanted to.

Probably a little to late for tek12, but there is always tek13 🙂