chrisruzin.net :: BlogTimes for pMachine Released (February 15, 2003)

Skip to main content
Newer: War Protestor Check List Older: Black People Love Us!

BlogTimes for pMachine Released

As I mentioned in an earlier post, I had seen a Moveable Type plug-in called BlogTimes which basically graphed a months worth of entries on a bar time-wise.  This allows others to see the times when you most often post.  I don’t know if there’s any Earth-shattering uses for this, but it is interesting to see patterns in the way I post.  You can see the graph on the bottom of the home page or in my archive summary.

I have been busy with a Web project lately, so my release of the code for BlogTimes pMachine had been put on hold.  Tonight I had enough time to finish hammering out the little details, and am happy to release it to the eager masses.  All 2 of them.  If you want to download the code, click here.

Setup is a piece of cake.  You don’t need to change any of the code, if you don’t want.  Just upload the script to your server, and wherever you want the graph to appear just add the following code:

<img src="blogtimes.php" border="0" alt="BlogTimes pMachine” />

That’s it!  I’ve also set up the script to accept variables so you can display information relevant to certain months.  You can see my Archive Summary as an example of this.  For example, if you want to display posts for January 2002, just use the following:

<img src="blogtimes.php?m=01&y=2002" border="0" alt="BlogTimes pMachine” />

If you want to change the colors or size of the graph, I have commented the places you can change the code in the script.

Let me know if you have any problems or questions.  I hope there aren’t too many bugs.  I’d also like to see it in use on other sites, so if you have it setup and running, let me know.

Sue from pMachine Hacks correctly pointed out that you’ll also need the GD libraries on your server in order for BlogTimes for pMachine to work.  That’s only the most important instruction!  I don’t know why I left that out.  I must’ve been tired or something.

Sue's gravatar Sue United States February 15, 2003

Chris, you need to mention that this only works if you have the GD libraries installed.

I don’t, and will get that fixed.

Chris's gravatar Chris United States February 15, 2003

Doh! Yes… Sue is right. You need to have the GD library installed on your server in order for it to work.

Thanks, Sue.

Chris W's gravatar Chris W United Kingdom February 17, 2003

Great tool and much appreciated! One thing I noticed when using the code in a pMachine template is that “double quotes” mess things up while ‘single quotes’ are fine. I used

Frederik Belgium February 25, 2003

Thank you for this! Good thing someone posted an image link with the variable for the month names in it. Thank you all!

Frederik's gravatar Frederik Belgium February 25, 2003

hmm… seems those variable don’t get parsed correctly.

Chris's gravatar Chris United States February 25, 2003

They should be parsing correctly. That’s exactly the code I used in my Archive Summary template. What template are you trying to use BlogTimes with?

Frederik's gravatar Frederik Belgium February 25, 2003

Ok, the problem was I changed the variables into Frederik Belgium February 25, 2003

He, my previous comment gor parsed on this page !! grin lol

Chris's gravatar Chris United States February 25, 2003

I’m glad it works for you. I like your site, by the way. You take some great pictures too. I like the two ducks picture.

Frederik's gravatar Frederik Belgium February 25, 2003

He, thanks grin I’m sorry you can’t understand dutch…

Another two questions – Are you the multi-poster Chris from the pMachine forum?

– Why does the blogtimes-img only counts till 20 and something , even on your site?
Chris's gravatar Chris United States February 25, 2003

No, I’m not the multi-poster Chris on the pMachine forums. My nick is Crusty.

What do you mean it only counts until 20 something? On all of my graphs, it shows the right number.

Frederik's gravatar Frederik Netherlands February 26, 2003

Look, it was kinda late yesterday when I installed Blogtimes, so do you promise not to laugh? I thought the blogtimes graph indicated the density of postings over a month (30 days) and not over 24 hours. grin

I feel very stupid right now.

Frederik's gravatar Frederik Netherlands February 26, 2003

This is the Blogtimes-dude again… I browsed your site a little, and I got really interested in your accessability statements. It is for the first time that I see a clear and logical list of all the improvements webmasters can integrate in their pages.

I never trusted css-layouting techniques. They seemed to look differently on every browser and every platform. If someone wants to use css-layouting techniques, they even have to hack certain css-properties in order to render them correctly (see http://www.thenoodleincident.com). So I decided to use tables after all for my page…

But now that I bought the Pro-version of pMachine (yesterday!), I’m planning a new design with multiple blogs. And your page really inspires me!! Tonight I’ll dive into you css-files wink

A have a few questions though – do you your header en footer on your site, or are those handcoded in every single file? – Did you have to ‘hack’ your way to a cross-browser css-layout? – Can I ‘steal’ some ideas from your site (like the use of icons underneath your messages instead of text-link)?

Chris's gravatar Chris United States February 26, 2003

On this site, I use pMachine Free, so I hard code the header and footer into each page. On another client’s site, I use pMachine Pro. There I used a header and footer file. You can see that site at www.dequeen.com.

I didn’t have to hack anything so far. This site looks correct in all the browsers I’ve tried. The De Queen site doesn’t look correct in Safari, but I can live with that for right now. Safari is beta, and will work out that bug in the near future.

Sure, you can use icons as links under your entries. I don’t have copyright on it or anything. =]

Babs's gravatar Babs Canada March 1, 2003

Is there a reason i can’t figure out how to configure my archive_summary template to show as yours does? Must be one of those days.

Babs's gravatar Babs Canada March 1, 2003

yeah. Ignore that last comment. slaps forhead

Chris's gravatar Chris United States March 1, 2003

It’s definitely one of those days.

Chris W's gravatar Chris W United Kingdom March 10, 2003

Hi Chris, is there a way to stop blogtimes from counting forum posts when using pMachine Pro? Am running it on my test server and every forum post appears on the graphic.

Chris W's gravatar Chris W United Kingdom March 10, 2003

Scratch that last question – adding “and weblog=’weblog’ ” to the $result query sorted my problem out.

Chris's gravatar Chris United States March 11, 2003

Glad I could help you out, Chris. wink

hannah's gravatar hannah Germany April 27, 2003

well, thanks for this neat script. i like it a lot, but the summary chart is even nicer, is there the chance you share that, too or did i miss it??

best,
hannah

Babs's gravatar Babs Canada December 18, 2003

have you tweaked this any to enable only a specific weblog and not all of them?

Babs's gravatar Babs Canada December 18, 2003

meh. forget that. figured it out. smile I just read the comment from Monday, March 10, 2003 | 5:24 pm

tina's gravatar tina United States June 3, 2005

I keep getting the following error:

The requested URL /archive_summary.php was not found on this server.

Chris's gravatar Chris United States June 4, 2005

tina, that’s because the script is no longer there. I no longer use pMachine, I use ExpressionEngine. The archive summary script won’t work with EE, so it was just spouting out a bunch of PHP errors. Sorry.

Your name is mandatory
Your email address is mandatory
Your comment is mandatory Formatting:
_emphasis_
*strong*
-deleted text-
@code@
   What word do you see to the left?
The captcha is mandatory