Showing posts with label mysql. Show all posts
Showing posts with label mysql. Show all posts

Wednesday, September 24, 2008

Hi my name is George and I was a Dreamweaver user...

_MG_9383

Yes, I'm embarrassed to admit that until this week, I used Dreamweaver as my development environment. What?! It was what I used when I first started doing web stuff and it did its job. I tried dabbling with the alternatives a couple of times: Textmate, Eclipse, VIM. There seems to be somewhat steep learning curve for Eclipse and VIM. Textmate had no real FTP support (I usually worked off the development server).
That all changed this week. We had a consultant buddy of ours, Lou, come in to do some heavy duty stuff. We developed (mostly him) a workflow to work on the site locally and commit changes to the development server (our version control is on another server). I finally had time to set up the site on my Mac locally. Lou was also helpful in getting me setup with Eclipse PDT. It's a lighter version of Eclipse made for PHP. The one I had tried previously was for Java.
The learning curve gets a lot less steep when someone is there to answer your questions.
By the way, I'm using XAMPP for the LAMP stuff on the mac.

Sunday, April 6, 2008

Google Custom Search Engine - Part 2: What's What is

Part 2: What's What is

Back in part 1, I ended with Wayne mentioning "mad bugs". Since it was only a text message and not a phone call, I still had time to jump on the bus and head down to the office.
I need to get into the nature of our site and our search strategy before I can get into the bugs. You'll understand why after the explanation.
Tickerhound.com is a Question and Answer site based on finance questions. We launched with a couple of thousands of questions AND answers from one of our partners, Investorwords.com (they're the questions asked and answered by StaffQuestion and StaffAnswer. The Answers also give credit to Investorwords.com ).
This way, the site will have a wealth of information and be more useful for the first wave of users at launch.

The bug: when users type in "what's" (apostrophe s) as part of the question, questions that start with "what is" doesn't show up in the results. As you can imagine, a lot of the questions start with "what is" - no good.

Getting there: After more testing and probing, Wayne the MasterBeta.... tester, found than using "what is" in the query will pick up questions with "what's".
We did more testing with "what is" as the baseline for good results.
I tried doing "what's OR what is" then the question as a query but got bad results.
The next one I tried was both the "what's" and "what is" version of the question, like "what's blah blah OR what is blah blah". It generated the same result as just using the "what is".

Solution: convert all questions that starts with "what's" to "what is" before sending the query to google.

Wednesday, April 2, 2008

Google Custom Search Engine (Business Edition)

Part 1: The Set Up
We decided to use google's custom search engine to do the search for our "similar questions" feature and for our regular search feature a while back. Fulltext search just wasn't cutting it. Who does better search than google right?

I finally got around implementing it last week.
It was a fairly painless process:
  1. sign up and pay (Wayne took care of this part)
  2. grab the URL from the admin panel page.
    the URL is only available to the admin or the person who paid.
    adding me as a contributor didn't work and you can't add any additional admins.
  3. read the doc. this took me a while to find for some reason:
    http://www.google.com/coop/docs/cse/resultsxml.html
    it seems the doc for the google application is similar but NOT the same as there are more functions that can be used (like meta data filtering) in the application.
  4. stick the URL in my existing search object, in a new function:
    1. send queries to google
    2. get xml back
    3. parse and style xml
    4. display results
It returns pretty good results, comparing to the old fulltext search.
There was a lag time of about 24-48 hours (this still needs more testing, but that's the general consensus on the interweb). New questions do not come up in the results. That's ok though because the older questions usually have more answers. Who wants to look at questions with no answers?

Everything was peachy then I get one text early next morning from Wayne telling me there are "mad bugs". uh oh.

to be continued...