Posted by Doug Hays on the 16th of May, 2008 at
10:18 am under Software. This post has no comments.
A client of mine, PositiveWare, just released version 2.2 of their project, time and billing management system. This is exciting to me for a couple of reasons. First off, I had a fairly large role in the development of the release and it always feels good to get something of this magnitude out to the users. Secondly, this even further aligns PositiveWare with the way its clients run their businesses.
The release adds functionality that allows an existing PositiveWare client to subcontract projects and tasks out to other PositiveWare clients. It means that, as a PositiveWare client, you will interact with your subcontractors the same way you do with your employees. No more wondering about what it is your subcontractors are doing.
As a PositiveWare client and as someone who occasionally uses subcontractors, this is very exciting.
Posted by Doug Hays on the 29th of April, 2008 at
11:20 am under CakePHP, MySQL and CMS. This post has no comments.
We have written a very basic CMS system (just like everyone else has) that we use on a handful of our clients’ websites. We wanted a CMS system that was:
- Easy to deploy
- Simple to re-skin when provided an HTML/CSS design
- Search Engine Friendly
- Easy enough that non-technical people could administer the content of the site
- Lightweight enough so that the system could be the foundation of a larger application or website
- Built using CakePHP and MySQL
After looking around the web for 5 minutes, and not finding anything, we decided to build it ourselves. So, here it is, Dingus CMS.
In order to install and use Dingus CMS:
- You’ll need a basic PHP/MySQL/Apache environment. (Note: PHP 5 is recommended and Apache needs mod_rewrite)
- Download the source.
- Extract the source into the document root of your website. Note that the app, cake, docs, etc… directories should be at the root of your site
- Configure the database connection in app/config/database.php
- Run the SQL in sql/dingus_cms_db_setup.sql
- Go to http://localhost and you should be up and running!
Note that Dingus CMS comes with built-in search and site map pages available at http://localhost/search.html and http://localhost/site-map.html
Finally, you may be wondering what a Dingus is. You’ll have to stay tuned for a full explanation.
Posted by Doug Hays on the 14th of January, 2008 at
1:28 pm under Rails. This post has no comments.
A client of mine let me know today that the Excel spreadsheets I was generating for them had data truncated at 255 characters. I didn’t find anything on the web that gave a reason or offered a fix so I decided to dig into the code myself. I am using the Ruby Spreadsheet-Excel gem.
Sure enough, on line 289, of workbook.rb (v0.3.5.1), there was this:
# Truncate strings over 255 characters
if strlen > StrMax
str = str[0..StrMax-1]
length = 0x0008 + StrMax
strlen = StrMax
end
No idea why this was done and I wasn’t going to waste anytime considering the downsides of not truncating, so I commented this block out and it works fine.
Maybe it has something to do with an older version of Excel? Who knows.
Posted by Doug Hays on the 15th of December, 2007 at
12:35 am under Rails. This post has no comments.
I just solved an issue that I couldn’t find an answer for on the web, so I thought I’d just put it out there so that maybe it could help someone else. I am creating a simple CMS tool for one of my clients and always like to use the FCKEditor for CMS tools. I hadn’t built such a thing in Rails before, nor had I used ActiveScaffold before today. But Rails + ActiveScaffold + FCKEditor seemed like the perfect combination. And it is, once you get it working. Here’s what I had to do to make this work for a table called content_items and a field called content.
After installing the FCKEditor and ActiveScaffold plugins, I created, for the content column, a form column override file in my views/content_items directory called _content_form_column.rhtml. After some trial and error, I landed at this solution:
<%=column.name.to_s.titleize %>:
<%= fckeditor_textarea( :record, column.name, :toolbarSet => 'Simple', :width => '100%', :height => '400px') %>
<input name="commit" type="submit" value="Save" class="submit"
onClick="var oEditor = FCKeditorAPI.GetInstance('record_<%=@record.id%>_<%=column.name%>_editor');
document.getElementById('record_<%=@record.id%>_<%=column.name%>_editor').value = oEditor.GetXHTML();" />
Now, this is my 15-minute solution. What I’d like to do is get that onClick JavaScript to fire on the form’s onSubmit event and remove this secondary submit button altogether. But, since it’s late, I decided to remove the ActiveScaffold Update button and make this column the last on the page. How’s that for an I’ll-deal-with-it-later hack!?
Posted by Doug Hays on the 14th of December, 2007 at
11:23 am under Apple. This post has no comments.
Just a quick note on a surprising feature of Apple Mail and iCal. After I upgraded to Leopard, I noted that some items in my email (addresses, dates, times, etc) had contextual menus appear when you rolled over them. The menus let you create a contact or an iCal event from the data in the email. But, again, Apple surprises with attention to the smallest details. For example, I was emailed this simple confirmation for an upcoming meeting:

When I rolled over the 6:00, the menu appeared and selected Create New iCal Event…. A little pop-up appeared and I began filling it out. When I went to choose the date, to my surprise, it was already selected:

It scoped out the rest of the message to find the mention of Thursday to select the 20th.
The ability to add an iCal event from an email message isn’t what makes a Mac fantastic. It’s the fact that the functionality does not get in your way and when you choose to use the feature, it works as you’d expect… and better.