Categories
Development

Google Font API & Font Directory

I’m very excited that Google announced some high quality open source web fonts. The lack of safe web fonts has always been a pain at times, and the CSS3 font-face is still tricky when dealing with copyrights.

Currently it appears that they’re offering 18 fonts for use. While not a ton of fonts, it is a welcome addition.

Using the Google Font API couldn’t be easier! They offer a great getting started page. Hopefully more fonts will be added soon, and site won’t go too overboard incorporating the new fonts either.

Categories
Design Development

Landscapes & Interiors

Finishing up a website for Landscapes & Interiors. They’re a landscaping and cleaning service located in Kennett Square, Pennsylvania. The client wanted an original website that they would be able to easily maintain and have the ability to make simple edits on their own.

We decided to build the website  on the Joomla! open source CMS (content management system). I’ve built many sites with Joomla! recently and each client has been very much pleased with the rich CMS functionality that we are able to deliver to them at a very reasonable cost. It really amazes me just how much functionality they are getting from an open source project.

We also relied on the Yahoo! YUI library to build the site as well. The site makes use of the following YUI components:

  • CSS Reset
  • CSS Fonts
  • CSS Grids
  • Yahoo Global Object
  • DOM Collection
  • Event Utility

YUI really helped us to work faster and knowing that their library is used and tested by Yahoo! for A-Grade Browser support is a real time saver.

The client did an excellent job in providing and organizing content for use on the site. I cannot stress how vital it is for a client to provide appropriate content in an organized manner for a site to be successful. They are the content experts and when we can mesh our respective areas of expertise a great site is almost always the result.

Since the business is new and this is their first website, special attention was spent to make sure that there is room for growth. The content regions and navigation elements all are easy to add or edit via Joomla! with little if any CSS adjust necessary to manage additional or changed content.

There are still some further tweaks and adjustments to be made to the site, but we did go live today, so check out www.landscapesandinteriors.com and see what great services and support that they offer. Again, it was a real pleasure working with this client, I had a great deal of fun and they are very satisfied with their site and that’s always great to know.

Categories
Development

Vote My Vote

Vote My VoteI’ve been busy doing some work for a really cool site, Vote My Vote. It’s a really cool community voting site for TV’s most popular shows. You sign up and they go through the hassle of calling in your vote for you. While I rarely watch any of those type of shows, I do have to admit I think it’s a very slick idea.

I primarily assisted with some Joomla development and configuration. Someone had been doing that role before me, so coming into a project that someone had already begun had it’s challenging moments (a white error screen of death for instance). But solving their issues and helping deliver a really cool finished (or very close to being finished) product was very gratifying.

I haven’t met a single member of the team who worked on this site in person, nor even spoke on the phone. It’s really amazing how people from all over can successfully collaborate on a project. I was fortunate to work with an extremely talented bunch of individuals on this project.

The primary tasks I assisted with were:

  • setup and the automatic population of the blog. We used the CorePHP WordPress MU component to help us with this.
  • Community Builder user registration. Ummm, there were moments I despised you Community Builder, but in the end we figured you out and you are doing your job.
  • Pulling in the latest forum posts to their respective areas.
  • Good deal of assist with other Joomla odds and ends. My hands got dirty with much PHP on this project. It was lots of fun.

Check out votemyvote.com, and let anyone you know who’s addicted to those reality shows about it.

Categories
Development

WideImage

Needed to do some server side image manipulation with PHP for a custom Joomla component I was working on. Unfortunately, I was having some initial problems.

Luckily I found WideImage, and open source PHP library for image manipulation. It was great and made the whole process so much more simple for me to implement in my component.

Using it is a cinch, just check out the examples and documentation on their site. Again, this was an excellent library for me, and I highly recommend it.

Categories
Development

PHP multi word search

I was building a search for a site I was working on and needed the search to work on the words a user might type in separately not as one string. For instance, if they typed: “wiffle ball in Louisville”, it would search: wiffle, ball, and Louisville.

Building my SELECT statement was a little tricky at first.

First I had to take my string that’s being passed and store each word in an array. The below is a very simple example, I highly recommend that you clean up the string first!

$searchString = $_POST['who-search'];
$searchArray = explode(" ", $searchString);

This takes our string and uses the explode function to break up our string into an array whenever whitespace is found. Again, this should be refined a bit more in a production level product.

Now that we have an array of the words that were entered, a way to work this array into the SQL statement had to be figured out. Using a couple of loops to go through the array and create OR’s did the job.

$sql = "SELECT DISTINCT * FROM table WHERE ("; 
 
while (list($key,$val) = each($searchArray)) {
	$val = addslashes($val);
	if ($val<>" " and strlen($val) > 0) {
		$sql .= "column1 LIKE '%$val%' OR column2 LIKE '%$val%'  OR column3 LIKE '%$val%') OR";
	}
}
$sql = substr($sql,0,(strLen($sql)-3));//this will eat the last OR
$sql .= ") ORDER BY column1 DESC";

The while loop goes through our array the addslashes function is called to the current value. This escapes apostrophes from throwing off the SQL statement.

If the current value isn’t empty then it’s inserted in the SQL and it’s value compared to the columns you want to compare it against in your SQL. In my example above I’ve used LIKE against 3 columns.

Finally you have to remove the final OR from the SQL statement. A simple substr function is used to remove it from the end.

Categories
Development

‘corePHP’ WordPress MU

Just installed and am in the process of configuring the ‘corePHP’ WordPress MU component for Joomla! This nifty component allows a WordPress MU install to run within a Joomla! install.

This is great, you can have a great Joomla! based site that also hosts multiple user WordPress blogs. This is pretty much exactly with these folks were looking for, and it integrates very well with the built in user management as well.

I’m still tinkering with many customizations to get this just how we need it, but most of the difficult work is already done by the component.

Also very convenient are the modules that ‘corePHP’ makes available for this component too. There’s module to display recent blogs, recent posts, etc.

Very good stuff so far.