Recently in site Category

Movabletype 4.2 Beta

| No Comments | No TrackBacks

Just checking to make sure this upgraded okay and everything is working. So far a few of my plugins seem to be dead but that is to be expected.

Take 2.

300 (Widescreen Edition)
After I got back from RHPS tonight I sat down to see what neat things I could do with Movable Type. I hadn't looked at the newest plugins in a while so I added in a few new ones. This media manager can import content from Amazon, like this DVD, videos from youtube and photos from flickr. Well I have the flickr stuff in but it doesn't seem to work right yet. Currently it can only use a single API key which only gives you access to the photos on my flickr account which is empty. Anyhow added that, updated visitor stats and hp blog printing. I am considering purchasing a license for visitor stats pro because the author has really put out alot of content and I would like to see him continue doing so. Plus the added statistics would be a neat thing to see.

On other notes my sleeping has gotten really fucked up lately. I am again sleeping through both of my alarm clocks and not being able to get to sleep til 1 or 2 each morning.

Current Mood:  depressed

Refeed: How we got it to work

| No Comments | No TrackBacks

First off since Movable Type 4.0 has been released I have been trying to get this plugin, refeed, to work. Finally after much gnashing of teeth and many swear words I decided I needed to find out if my perl install was even good or not. I couldn't find a ready script to test the perl modules that this plugin were using so I had to learn a little perl. I came up with the script below using the docs at cpan as a guide. So now I have this script that reads in an rss feed and then spits out the title of the feed followed by the time the article was published. This is where I discovered or at least confirmed what my problem with refeed was. XML::Feed wasn't properly reading in the time. <pubDate>2007-10-12 10:20:49-0400</pubDate> So now we know it isn't reading the time in right so what I did was enlisted the help of Corydon and he told me to change my $issued = $entry->issued; to my $issued = $entry->issued || DateTime->now(); the addition the line tells the script if the first field is undefined use this instead which is the current time. This has a few problems like all the posts from a feed would be read in the first time as all being posted at the same time after the initial pull it becomes less of a problem.

#!/usr/bin/perl

use Feed::Find;
use URI::Fetch;
use XML::Feed;

$url="http://www.memestreams.net/users/wilpig/?type=rss";

my @feeds = Feed::Find->find($url);
for my $uri (@feeds) {
print "$uri \n";
    my $res = URI::Fetch->fetch($feeds[0])
        or $warn->("Can't fetch feed $feeds[0], skipping"), next;

    my $feed = XML::Feed->parse(\$res->content)
        or $warn->("Can't parse feed $feeds[0], skipping"), next;

     for my $entry ($feed->entries) {
        my $id = $entry->id;
# Uses the current time if no time is found.
#        my $issued = $entry->issued || DateTime->now();
        my $issued = $entry->issued;
        $issued->set_time_zone('UTC');
        print "$id \n $issued \n";
     }
}

So after knowing what the problem was I asked again in #se2600 for some further help. Critch offered and helped me find a work around to this perl module not reading in the time correctly. So he had me edit /usr/lib/perl5/site_perl/5.8.8/XML/Feed/RSS.pm and we changed starting at line 224. This was the original section.

                my $parser = DateTime::Format::Mail->new;
                $parser->loose;
                $date = $parser->parse_datetime($ts);

and here is what we changed it to so that we knew exactly what format the time would be in once it was set to be parsed.

                my @time = localtime(HTTP::Date::str2time($ts));
                my $stringtime = Date::Format::strftime("%a, %d %b %Y %H:%M:%S %z",@time);
                my $parser = DateTime::Format::Mail->new;
                $parser->loose;
                $date = $parser->parse_datetime($stringtime);

This works as intended. However it does throw up a warning each time it is run talking about a difference in format but it doesn't seem to bother anything. Almost forgot at the top of the file we had to add in:

use HTTP::Date;
use Date::Format;

For the other modules we were using in parsing the time format.

There you have it. My test script to ensure that the perl modules are installed correctly and functioning and the changes we made to RSS.pm as well. Hope this helps someone.

RSS Feeds

| No Comments | No TrackBacks

Okay you've probably seen all the posts tonight and wondered what is up. Well after much work we finally got refeed working! I am going to do a little more fine tuning on it to see if I can't make it more pig friendly but now if I post on memestreams it should appear here as well. I'll post the details of the patch we made to the refeed.pl tomorrow after I have had some sleep. I have a really bad headache now from skipping dinner and gonna try to sleep it off.

Current Mood:  hurting

OpenID Login Enabled

| 2 Comments | No TrackBacks

A few weeks back I loaded a neat little plugin from mt-hacks that added the OpenID server functionality to my movabletype setup. This was all neat and good now I could login to other sites but I was not very happy with it because when I logged in using my ID it showed me up as http://blog.wilpig.org and not really myself as the example had shown. So I left a comment for the author of the plugin and he responded about how to make it show my name instead of the site. He pointed me to Wikipedia to learn about something called Foaf(friend of a friend). Which led me to neat little sites like this that can help you build a foaf file. After some digging and rereading what he posted back I found the magic missing ingredient.

<link rel="meta" type="application/rdf+xml" title="FOAF" href="foaf.rdf" />

This is how you can reference a foaf id file in the header of any html document. So I went ahead an build myself a foaf file inside of movabletype and put the above line in the head of the document. Now when I login to other sites using my OpenID it shows up as Wilbur Longwisch. Many thanks go out to Mark for this really nice plugin.

Example foaf.rdf:

<rdf:RDF
  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:foaf="http://xmlns.com/foaf/0.1/"
  xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#">
  <foaf:Person>
    <foaf:name>Wilbur Longwisch</foaf:name>
    <foaf:firstName>Wilbur</foaf:firstName>
    <foaf:surname>Longwisch</foaf:surname>
    <foaf:mbox_sha1sum>ba8c001a08e7dd5960a2e806fdef52d67a5a8284</foaf:mbox_sha1sum>
    <foaf:homepage rdf:resource="http://blog.wilpig.org/" />
    <foaf:nick>Wilpig</foaf:nick>
    <foaf:depiction rdf:resource="http://www.wilpig.org/~wilbur/webcam/locked/webcam.jpg" />
    <foaf:workplaceHomepage rdf:resource="http://www.icscci.com"/>
    <foaf:holdsAccount>
      <foaf:OnlineAccount>
        <rdf:type rdf:resource="http://xmlns.com/foaf/0.1/OnlineChatAccount"/>
        <foaf:accountServiceHomepage rdf:resource="http://www.freenode.net/irc_servers.shtml"/>
        <foaf:accountName>Evilpig</foaf:accountName>
      </foaf:OnlineAccount>
      <foaf:aimChatID>wilpigorg</foaf:aimChatID>
    </foaf:holdsAccount>
  </foaf:Person>
</rdf:RDF>

Current Mood:  accomplished

No real topic

| No Comments | No TrackBacks

I am once again stuck over the Ohio river and was going to make a quick post about some of the movabletype changes I have been making. First off I have installed several more login types the latest being AOL. I now have the YouTube pluging working that I might buy if I start using YouTube more. I am still trying to get refeed to work but it is giving me errors about dates and all types of things. I still have a few other errors on the backend that I am working on clearing up.

Current Music:  Rob Zombie - Feel So Numb

Old style keywords entry

| No Comments | No TrackBacks

The MT4 upgrade broke my keywords plugin because the entry page changed from a text box to an input box. So after a little reading and posting on the forums I started digging on my own. I found what I was looking for on Line 999 in "/tmpl/cms/edit_entry.tmpl".

You have to change this line:

<input name="keywords" id="keywords" class="full-width" tabindex="8" value="<$mt:var name="keywords" escape="html"$>" mt:watch-change="1" autocomplete="off" />

to this:

<textarea name="keywords" id="keywords" class="full-width" tabindex="8" mt:watch-change="1" autocomplete="off" /><$mt:var name="keywords" escape="html"$></textarea>

The formatting is just a hair off but I don't feel like tracking down the div or whatever style element is causing it. At least I can put in multiple keywords again to make my other plugins work.

Current Mood:  tired

New Site Design

| No Comments | No TrackBacks

I am currently toying around with a new design for the site. After upgrading MT some of my templates didn't work with the new features so it was time to blow it all out and redo. I have some PHP code in the back end now that is doing some fun stuff with entry editing as well as leaving special notes for some of my visitors. I will probably be dropping in some extra php from time to time to leave notes for people visiting from specific static IP addresses, etc.

Current Mood:  tired

Of myspace and mobile phones...

| No Comments | No TrackBacks

After being at all these parades and strolling the streets of New Orleans I have a bone to pick with some stupid people. This is not a camera. It's a phone jackass. Don't be holding it up in pitch black and expect it to take some award winning photo of a float coming down the street. This, while being a point and shoot, is in fact a camera that takes decent pictures that can be printed and come out not looking like ass. I am not sure how many of the pictures I took of the parades came out with some asshat's hand in the picture holding up their god damned phones but I am sure there are several. I saw this too on bourbon street alot. Now keep in mind I will not print even half of the shots that I take, but at least I have the option of printing them and they will come out like pictures taken on film. All this frustration over me not getting a few booby pictures on bourbon street because of over zealous dipshits with pricey phones. Bring back phones that are just that, phones. Now scroll down and see the pictures I took on my crappy camera phone and posted directly. HA! I'm an ass for doing something similar to what I am complaining about.

Onto the other thing... myspace... scourge of the internet. Okay. Umm... how to say this gently.... Your page is ugly. Dear God please just remove your great creation(abortion) of a style sheet and just let it be blue and white. Bright flashing backgrounds, music and video autoplaying, wasting my bandwidth with me having to load that garbage. If myspace wants to do the web community a service and allow people to add in style info at least let them use IDs to fully take control of the space. Let me force that comment box to X pixels wide so no more gaudy images can get added and make my scroll bars extend off into infinity. Had someone show me their page a few weeks ago, they were so proud that it showed off that persons originality and spirit. The background was a bright vivid image and the tables had all be set to transparent with black text. You couldn't read a damned thing on the page. Come on... 90% of good webdesign is to make it easy for your target audience to get your message / ad / etc. That is just retarded.

Enough bitching from me. Gonna head out and enjoy the rest of Mardi Gras. Expect pictures soon.

Current Mood:  exhausted

Mobile Blogging from Treo650

| No Comments | No TrackBacks

I have looked at this topic a few times when dealing with camera phones and how to get content directly onto this site. Finally, after looking at various pieces of software I found one that works and best of all it is free! u*Blog has met my expectations and gone far above. It is almost like it was written just for Movabletype. The only drawback I have seen with it is it will only pull pictures to post from the SD Card and getting that set just right was a little tricky.

So in the event that someone else is looking at how to do this here are some of my notes to make the process quick and easy.

Manual for u*Blog.
To get the program to see the photos on the card click on the menu button then goto settings. For the image path put /DCIM/.
And the tricky part of getting it to display the image with the posting was done with a little bit of help from the tags menu. I made a tag called "picture" then gave it the following code to make it happy.

<img src="http://blog.wilpig.org/archives/images/%f" class="mobileimage">

The %f is so it will insert the uploaded filename into the code segment. And the class of mobileimage is to resize the image on my main page yet allow the individual entry page to show the image full size.

This should support the keywords and stuff and I will try them on the next post I do with it. I will need to get a data package for my phone first. It is expensive to post without one.

Current Mood:  pleased

Semi-Live Cam

September 2008

Sun Mon Tue Wed Thu Fri Sat
  1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30        

Pages

Powered by Movable Type 4.21-en