Tag: webdesign

Crossposting Excerpts to LiveJournal

So I’ve been using the LJXP plug-in to crosspost my entries from this journal for a while now.  I liked that LJXP allowed me to choose certain categories to crosspost and others not to.  When I signed up with BlogHer, I needed all my content to only be on this one site, so I used LJXP to basically undo all those crossposts (pretty dang handy that it can do that).

For a while I’ve just been crossposting my “asides” and then hand coding a quick title and link on LJ that linked back to the entries here.  I was getting tired of doing that, so I wanted to be able to just crosspost an excerpt each time I updated.  Unfortunately the current version of LJXP doesn’t have an option for that.

Everything I looked at directed me to LivePress as the best possible solution, but I really didn’t want to have to install a different plugin, not to mention that I discovered with LJXP that what works for one person will often not work for another where these crossposting plugins are concerned.  And LJXP has worked for me.

So I started to try my hand at editing the code in LJXP to post an excerpt instead of the whole entry.  Nothing intuitive seemed to work there, like say some call to “the_excerpt” or “post_excerpt” or similar.  Instead I wound up editing the line:

$the_event .= apply_filters(‘the_content’, $post->post_content);

to say:

$the_event .= substr($post->post_content, 0, 350);

What I have done here is cheat.  Since I couldn’t get any of the appropriate WordPress variables to do what I wanted, I used a php function “substr” to return only the first 350 characters of the post.

I then used the LJXP’s custom header/footer feature to write a footer that started with an elipsis before the rest of my footer information, so that each 350 character cut ended with “…” and then instructions on how to read more.

It couldn’t crosspost all my old entries (error) but it’s managed to crosspost each new one I write no problem.  So with no warranties, no guarantees, no support, etc., if you’re using LJXP 2.0.6 (my plugin says it’s .6, the most recent download says .5, not sure what’s up there) you can feel free to give it a try for yourself to crosspost excerpts to LJ.  (Always save a copy of the original file before editing, yadda, yadda, use common-sense, plugins don’t always work, etc. etc.)

Posted on June 6, 2009 at 2:19 am | Comments Off | Filed Under: geekery | Tagged with , , .

Update Gratification

Do you find that if you are contemplating a site redesign, you don’t do much with your site?

I had been wanting to do a little something to reorganize some of the information on this blog.  Sort of rework it so the look would be the same or similar as it was before, but that more than one post would show up at a time, and reworking the sidebars a bit, especially in the single post view.  (As you can see, that redesign is mostly implemented, minus a few additions I’ll have to make at a later date.)

And while seriously contemplating this update, all other journal updates essentially stopped.  I would think of something to write, and think: Aw, that won’t look quite the way I’d like it to until I work on the site redesign, and I don’t have time for that right now.  Which is funny, since the redesign is (and was intended to be) so very similar to the old design that it almost doesn’t make sense (though it does, and it pleases me to have it done).

So, now, after a great deal of css frustration (it’s so simple what I want this should so work why doesn’t it work arghhh let’s go find a theme where it works and see what they did) here’s that bit of update gratification I’ve been looking forward to.  Whee!

Posted on May 22, 2009 at 2:02 am | Comments Off | Filed Under: geekery | Tagged with , , .

  • Project Wonderful

    ... to advertise

  • Twitter Updates