Category Archives: Blogging

Upgrading to WordPress 6.1

21
Filed under Blogging, WordPress

This site’s been chugging along for years now. I’ve been super happy with my hosting company, NameCheap, and everything has just worked.

Until, of course, it didn’t.

I used to use Microsoft’s LiveWriter way back when, but then, they quit updating it and it quit connecting to my blog so… I just used the WordPress editor and continued on.

I finally had minute to take a look and realized that I hadn’t updated WordPress is quite some time.

So, back up the site, then update… oops, no, I’m using an ancient version of PHP.

So, update PHP to 8.1

Update WP to 6.1

Bam!

Critical error loading WordPress

Oh Joy

So I start all the typical stuff. I’m no WordPress expert, by any stretch.

Update all the plugins.

Nope

Disable all the plugins.

Nope

Clear caches. Reset Themes.

Nope, and Nope.

This might turn into a long night.

So I punt.

The guys (and gals) in NameCheap support have pulled me out of a wringer before, so I figured I might give em a shout. The worst they could do is tell me “that’s your programming problem”. Smile

Joy

So I search the Knowledge Base right quick, come up empty, and finally decide to file a support ticket.

Within an hour, I get a message back that they’d had a look at my WordPress log and the issue appeared to be with my theme at line x.

No freakin’ way!

Open the theme INDEX.PHP up and, sure enough, turns out the old WordPress was more forgiving with PHP files that used <? … ?> instead of the newer style <?PHP … ?>

Literally 2 lines of code changed and presto. Entire site back and running!

And not only that, the latest OpenLiveWriter (the open sourced version of my old friend), recognized it and loaded up perfectly. I’m even writing up this entry using it!

Just Upgraded to SyntaxHighlighter 3.0.83

0
Filed under Blogging, WordPress

I had to use the shLegacy.js option since I’ve got tons of <PRE> tags all over this site using the older version. Not great bbecause the “Autoload” function for syntax brushes doesn’t seem to work in conjunction with shLegacy.js, but I suppose that’s to be expected.

If you notice any “unhighlighted” code, just let me know.

ShiftThisSwift SMTP Configuration for WordPress

3
Filed under Blogging, WordPress

I’m in the throes of conversion from dasBlog (a great ASP.net based blogging engine, btw) to WordPress, as you can no doubt tell from the sometimes random gobbledygook littering these pages!

One bit that was particular annoying was that when comments come in, the administrator is supposed to be emailed a notification of such. But this wasn’t working.

I hit all the pages on Google pertaining to the problem (and it has been a problem for some time, apparently, centered around hosting WordPress on various webhosts), but still no luck.

Finally, I came across a mention of the ShiftThis Swift SMTP Plugin for WordPress. Looked like exactly what I was needing.

A quick download (and upload) later, and I was looking at the configuration screen.

Unfortunately, my first set of config didn’t work. Actually, it through a big, nasty exception all over the screen.

So did rounds 2 and 3. Round 4 got a little closer, the exception indicated that “authorization had failed for the username and password”.

Better.

Eventually, I worked out this set of config values (I’ve annoted the config screen below), and they DO seem to work just fine with my webhost (hosting under Windows).

image

Of course, your mileage may vary.

The key points for me, anyway, were:

  • The Server Address. It needs to be the name of the SMTP server OF THE WEB HOSTING MACHINE your website is hosted on. For instance, if WordPress is configured for the site MyDomain.com, this will likely be smtp.mydomain.com.
  • The Username. For me, it needed to be the FULLNAME (with the @domain.com part) of a mailbox configured ON THE WEB HOSTING MACHINE your website is hosted on. Following from the above example, I might use mail@mydomain.com
  • The Password. Even though my mailbox has a password, I had to leave this blank, or authentication would fail every time.

And there you have it!

Death of a Blog

2,490
Filed under Blogging, dasBlog

I’ve been offline for a few days. Yeah, it was Thanksgiving, yeah, I lost a drive in the raid of my main workstation. But the real nasty bit was when I went to post a new entry and Windows Live Writer merrily churned away with no errors, but when I went to check the entry on my site, no joy.

Eh?

imageWell, I didn’t have any time till tonight to check into it. A few Googles turned up this handy little label on the Live Writer Help-About screen.

Click it and you get a nice log file (that might be quite long since I don’t believe Live Writer ever trims it).

 

 

Down toward the end, I notice this:

 image

Doh.

I use www.ServerGrid.com for my webspace, so I browsed over to my control panel and it sure looked like I had 302mb used of 1000mb available. Hawuh? That should be plenty. Still, I have a hard time believing dasBlog would lie about an error like that.

Fortunately, ServerGrid has a live chat 24hrs a day. A quick chat with one of their support people, and I discover that just because they upped my space to 1gb, doesn’t mean they automatically up my quota.

Back to the control panel, sure enough, the quota is still set to 300mb.

Change it up and I’m back in business.

New Windows Live Writer Available

1
Filed under Blogging

I’ve blogged about Live Writer before. It’s an awesome offline blogging app from Microsoft, and it’s free! It can even read the style sheet of your blog and apply it while you write (mostly).

Anyway, looks like the first official release is out and it’s definitely worth the download. They’ve fixed the most irritating bug in the beta (having too many pictures in an entry would cause GPF’s), and so far, it appears very stable.

Even better, the new version will upgrade the beta in place. All my draft entries were preserved perfectly.

Grab it here.

A Bit of a New Look, or Fun With CSS

4
Filed under Blogging, CSS

The formatting of the code snippets I post from time to time have always bothered me.

They didn’t wrap, which is good (wrapping code just annoys the hell out of me), but they trailed off the edge and just appear to get cut off.

If you selected the text, it was all there and could be copied to the clipboard, but… well…. yuck.

Anyway, I finally figured out how to change the CSS such that you get a nice little scrolling window for the snippet.

I should point to Scott Hanselman’s blog as the source of the example I found, but I did tweak it a bit.

Here’s an example:

Public Function AppVersion$()
   '---- Get the Current Application file's "Full" version info
   Dim p$

   If IsIDE() Then
      '---- just pull from the App values (because the version resource
      '     isn't available
      AppVersion$ = App.Major & "." & App.Minor & ".0." & App.Revision
   Else
      '---- get from the VersionInfo resource, will include the real revision and build numbers
      AppVersion$ = GetFileVersion$(App.Path & "\" & App.EXEName)
   End If
End Function

Since this is purely a CSS thing, it works backwards in all my old posts, and it appears to be (so far) cross browser compatible.

Here’s the style (I’ve enclosed it in a STYLE tag so you can embed it directly in a html file, otherwise, just use the PRE definition).

<style type="text/css">
pre {
	border: 1px solid #e3a83d;
	border-left-width: 2px;
	background-color: #444;
	padding: 1em;
	margin: 2em;
	line-height: 1.2em;
	overflow: auto;
	width: 90%
	font-size: small;
	color: white;
	font-family: consolas, "Courier New", courier, monospace;
}
</style>

Yeah, it’s probably pretty minor stuff for all the CSS genii out there, but I’m still surprises with what you can do with a little CSS. Makes me really want to get into the whole WPF thing. 

daBlog’s New Medium Trust Made Me Sad (for a little while, anyway)

2
Filed under ASP, Blogging, dasBlog

Oops, don’t try this:

      Dim req As System.Net.HttpWebRequest = System.Net.WebRequest.Create(URL)

on an ASP.NET page in a web app marked with MEDIUM trust (as the new dasBlog 2.0 comes configured, as in this web.config file)

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
    <system.web>
        <trust originurl="" level="Medium">
    </system.web>
</configuration>

Guess that’s one of the no-nos of medium trust.

In my case, the only place I’m doing this is where the incoming URL is a value fixed in code, not something coming from user input, so I don’t believe it can be usurped for unscrupulous uses (I think I just blew my “u” quota for the day<g>) .

If you’re wondering, that code came from the ICQ status request bit I coded up and blogged about here.

To solve it in my case, I went back to normal trust level.

Anyone know how you’d handle doing this in medium trust? 

Ultra-Speed Wonder-Blogging

1
Filed under Blogging, Utilities

I’ve read a ton of good press about BlogJet and from the demo I looked at it’s pretty slick. But BlogDesk is free and does everything I needed it to, until now.

I have to say, Windows Live Writer is an awfully nice way to write blogs, and it’s free as well. It works smashingly with dasBlog, sets up on Vista without a hitch, has a built in spell checker, which myself (and a lot of blog writers out there) need, and can even edit blog entries using the styles cribbed from you blog itself.

Check out this screenshot of Live Writer entering this actual entry.

image

Sweetness. And it pulled the style sheets automatically. It doesn’t look exactly  like my blog, but hey, that’s pretty good for being editable!

Finally, if you prefer, there’s all sorts of effects you can give graphics as you paste them in. I tend towards the simplistic, but there’s drop shadows, overlays, transforms, etc to play with.

UPDATE: Well, Live Writer is nice, but it’s definitely still beta. With lots of images, it seems to crash when loading drafts to continue editing. But it works well enough for image-light pages, so your mileage may vary.

New Comment Styles

8
Filed under Blogging, CSS

I’m experimenting with a new comment style on the site.

Basically, the idea is to make comments look like they’re speech balloons. Plus, I believe it makes them a little easier to follow. Here’s an example of what it should look like now.

I saw this on a blog somewhere, just not sure where anymore, and apparently I cleared my browser history since then because I couldn’t find it again.

I’d have preferred the Names to be on top, with the arrow pointing down into the comment, but dasBlog doesn’t have any support for templated comment elements. You have to have that to move the actual pieces of the comment (the name, comment, and date, for instance). From what I have found online, they just haven’t gotten around to it yet. That made modifying the comment item format, um, shall we say, an adventure.

This is the first round. It doesn’t seem to work completely in IE (the little dialog arrow doesn’t show up), but it doesn’t completely mess things up either. It looks right in FireFox. Not sure about other browsers.

The trick, as I’ve got it now, is that I’m using the AFTER pseudo-element along with the CONTENT keyword to create an image tag where there was none before, like so:

.commentPermaLinkStyle:after {
 content: " " url('quotearrow.png');
}

Unfortunately, this doesn’t appear to be handled properly by IE. I tried a background img, but that didn’t seem to work well either.

CSS, one giant, turbo-charged erector set full of parts that don’t always fit the same way 🙁

Web Hosting (or Move your s**t, I wanna put my stuff here!)

3
Filed under Blogging, Misc

Ok, you’ve got a nifty idea for a site, maybe it’s personal stuff, maybe it’s something more involved. You could put it up on that free space your ISP gives you. And then you get to hassle with it every time you have to change ISP’s because Comcast gets bought by TimeWarner, that decides to bail out of your area leaving it to verizon, which…. you get the picture.

Or, you can plunk down a few bucks a year, buy a domain name and then plunk down a few more bucks a month and buy some space on a professional hosting company. That way, the domain is yours and it won’t change just because some bean counters at your ISP decide your city no longer forecasts to good market saturation, or whatever the jargon is. It also means an email address that won’t change just because you ditch cable and switch to Dish Network (say that five times fast!).

There’s a lot of hosting companies out there, and everyone has different requirements and demands as to what a good hosting company consists of. In my case, I wanted a host that would provide a decent amount of space, tons of email support, MS SQL and MySQL options, as well as Access dbs, and full support for .NET and some of the more esoteric web languages out there, like PHP, Ruby, Python, etc. so I could experiment with them, time permitting.

www.1and1.com looked pretty good, the price is definitely right, but they make you choose between Windows hosting, with .NET support and Linux hosting, with all the other languages. Not so good. But their domain registration is excellent and they provide free private DNS records, which is quite nice.

I ended up stumbling upon www.servergrid.com. They support all my requirements for 7.95$ a month, and they use HSphere for dynamic site management, which seems to work pretty good for me. I can host all my domains through one account, and just split my space up between them, which makes managing everything nice and tidy. Granted, I’m only running small sites, testing web apps, etc so I don’t have huge demands, and your mileage may vary.

This site uses dasBlog for its content management. I had it installed, setup and running within an hour on my ServerGrid space (not including the hours and hours I spent coming up with the nifty graphics, layout, CSS and color scheme, but that’s another story!)

I will say this though. I’ve started up support chats at one in the morning with these guys and there’s always someone there that seems to know what they’re doing. Good support goes a long way in my book.