Monday, January 31, 2011

Increase the number of entries in Media Library of Wordpress

Have lots of images? Don't want to paginate? Using Faster Image Inserter?

Change from 10 to whatever:

back up wp-admin/includes/media.php

find this:

$start = ( $_GET['paged'] - 1 ) * 10;
if ( $start < 1 )
$start = 0;
add_filter( 'post_limits', create_function( '$a', "return 'LIMIT $start, 10';" ) )


and this:

$page_links = paginate_links( array(
'base' => add_query_arg( 'paged', '%#%' ),
'format' => '',
'prev_text' => __('«'),
'next_text' => __('»'),
'total' => ceil($wp_query->found_posts / 10),
'current' => $_GET['paged']
));


and change 10 to 50 or 100 or ...

Friday, January 21, 2011

MySQL fix some phone numbers

This is long and convoluted, but basically, it takes unknown inputs of phone numbers from a table:
5551212
555-1212
212555-1212
212-555-1212


and makes them all
2125551212


select Concat(if(length(PhoneNumber)< 10, "212", ""), replace(PhoneNumber, "-","")) FROM AddressBook;

update addressbook set PhoneNumber=Concat(if(length(PhoneNumber)< 10, "212", ""), replace(PhoneNumber, "-",""));

Wednesday, December 29, 2010

Evernote works well with WINE

Installed Evernote on WINE, and it seems so far to be pretty stable and works well enough to grab my information.

Saturday, December 11, 2010

Set up Harmony Remote for Motorola VIP-1216

We just installed Prism from CenturyLink. I just wanted to post something how easy it was (should have been) to convert my Harmony H659 remote to control the Motorola VIP-1216.

If you remember nothing else, "No, I don't have the original remote". Don't try learning it. Don't try guessing from the remote brand. I did this and was extremely frustrated.

You really just have to load your Harmony software, connect your remote, add the device (Video Recorder -> PVR), choose Motorola as a brand, and VIP-1216 as the model. Next, "No, I don't have the remote"! Next/Done, but then go to the Activities tab (watch TV?) and add the Motorola VIP-1216 to the TV.



Now, what functions will you not have immediately that you may want to add to the display?
Certainly, you won't have all the direct input power/mode buttons at the top. But if you have a Harmony remote, you understand why those aren't necessary. If you have an errant device in the wrong on/off state, you'll use Help to get it back in sync, though if it you're having constant issues, you may want to verify the remote is controlling that device properly in the Harmony software.

Other buttons: "On Demand", "Recorded TV", "Learn" (Not needed), "Back" (Probably unnecessary as there are other buttons that can do it), "Go Interactive" (May never use), TV/Exit to "TV (again, may never use). Certainly you can add those to the display of the Harmony if you want them.


Monday, November 29, 2010

The Calorie Lie followup

Almost a year ago, I wrote about The Calorie Lie, how calories in themselves were useless as a measurement.

Now, Weight Watchers has concurred with my findings. OK, not really *my* findings, but they have changed their "Points" system to reflect that food isn't made of calories, it's made of "macronutrients."

The best part of learning how to eat right is to not be focused on how much you're eating, but how well you're eating.

You don't have to go vegan to lose weight. Just moderate. Put less on your plate and don't eat it all. Don't eat a midnight snack. As I say, "I can eat anything I want, just not all of it!"

May good choices be yours!

Tuesday, November 9, 2010

vmware server make isos from Microsoft Volume License exe

Some things I learned:
  • the default logon and password of VMware infrastructure web access is the one you use to log on to your workstation/server
  • An iso you want to map to a CD in vmware server must at least be in the Virtual Machines location.
  • Microsoft .exe files from Open License should be extracted before made into an iso.
  • nlite is the easiest way to make a bootable iso from disk 1.
  • use your favorite iso maker to make an iso of disk 2 (ashampoo is a free option)
  • Internet Exporer (or Firefox) is necessary at least initially for the Remote Console
  • ctrl-alt-insert sends ctrl-alt-delete
  • Windows 2003 Server forgets the AMD PCNET adapter after upgrading to SP2. Copy the windows.iso file from the VMware directory to the Virtual Machines directory and mount it via CD to install VMware tools

Blog Archive