Pikachoors

For the longest time, I’ve wanted something like Delicious for pictures, instead of links. Today, It finally gelled in my head how to do it with WordPress. You need one PHP script and a bookmarklet:

1. wp-pikachoor-post.php, this is the script that does the actual posting.

2. This bookmarklet: <a href=”javascript:window.location=’http://address.com/wp-pikachoor-post.php?url=’%20+%20eval(window.location);”>Pikachoors</a>

All you do is, drop the script into the top directory of your blog. Then put that bookmarklet somewhere you can easily click it in your browser. And any time you want to grab a copy of an image, just make sure you’ve got the image (JPEG, GIF, or PNG) pulled up in your browser, and click on the bookmarklet. The image will be saved and displayed in your blog.

Voia, you get Pikachoors.

C++

I don’t do much C++ programming, but in 2009 I started slowly working my way through Project Euler, solving the projects using C++ as a way to use my skills.  For now, this page will catalog my solutions, though that may change in the future.  Each solution was originally posted to my LiveJournal, and until I have time to upload each one as a text file, I’m simply going to link to them from this page.

Project Euler Solutions:

Iron Man Armor

Iron Man Armor

Iron Man Armor is the custom Twitter client I use to post to my sockpuppet Twitter account, tonystark. It was originally based on the Coding the Tweet client, but IMA is written in VB.NET (atop .NET 3.5) and uses the OAuth code, by Shannon Witley and Eran Sandler, as an assembly.  You can get an idea how that works, as well as the DLL, by looking at TwitBack.

As of now, IMA’s source code is not available for download. I’m still adding features, the code is messy, and there’s absolutely no documentation.  If you’d like a copy of the compiled version, or are really brave and want to dig through my code, let me know. I don’t want to take the time to make it presentable to any random passersby, but am always happy to share my code.

Current Features:

  • Posting tweets
  • Viewing a real-time timeline of friends
  • Viewing semi-real-time timeline of replies
  • Backing up posted tweets

Photobucket Viewer

This is a mashup with two parts: a server-side OPML generator and a client-side viewer. The server-side component is written in PHP, and the client-size is done with AutoIt.  (I am considering a second version of the viewer written as either a WPF application or Adobe AIR widget.)  You will need three files to get this to work:

Server-side setup:

  1. Put opml.php and PBFTP.php in the same accessible web directory.
  2. Set the permissions of that directory to 777.
  3. Set the value of line 82 in opml.php to the location of your public Photobucket account.
  4. Set the value of line 85 in opml.php to the number of minutes you want to cache your OPML file.

Client-side setup:

  1. Change the value of line 10 to the location of your opml.php file.
  2. Change the value of line 11 to the location of your public Photobucket account.
  3. Run the photobucket.au3 script.

Small Basic

Small Basic is a new dialect of BASIC from Microsoft, not to be confused with SmallBASIC. I’m rather fond of Small Basic for a number of reasons: it’s a fun procedural language for making simple widgets, you can extend the base language with .NET languages, and I just like BASIC. The projects on this page will consist of programs written in Small Basic and libraries to extend the language. (Note: Many of these programs were written for Small Basic 0.1 and 0.2; they may not work in current versions.)

Programs:

  • ms_small_mouse.sb — a small program that demonstrates the Dialogs library.
  • ms_small_test.sb — my first Small Basic program.
  • ms_small_widget.sb — a simple widget for surfing through my latest Photobucket images; uses the RssBasic library.
  • ms_small_widget2.sb — uses RssBasic and Dialogs, now loads the full-sized image as well as thumbnails, updated for Small Basic 0.3.
  • ms_small_xml.sb — as-yet-unfinished XML parser written in Small Basic; as of now it grabs an HTML page and removes double-spaces and hard returns.

Libraries:

  • Dialogs — this is a library that gives Small Basic programs access standard dialog boxes. (VB.NET)
  • RssBasic — a small, alpha-type library for giving simple aggregation capabilities to Small Basic. (C#)
  • Twitter — a library I’m working on to give Twitter access to Small Basic. (VB.NET)