Tips and Tricks

Qt C++: Threaded Communication with Artema Hybrid on Linux

Communicating with an Artema Hybrid CC Payment device is actually deceptively simple. I’ve written an application what uses a webkit widget exclusively for the UI display, and so I hook into the Javascript to provide some extra functionality to the app, in this case, reading and writing to/from the Artema Hybrid device. The documentation that [...]

Tags: , , , ,

Posted in: c/C++, C/C++ Programming, Computer Science, Javascript Tutorials, Linux, OOP, Qt, Tips and Tricks, Topics, Tutorials | No Comments »

Rails will_paginate links to wrong page

Well, While setting up a website today I found a bit of retardation in will_paginate. Aside from poor and complicated documentation and an incredible amount of bloat for what amounts to a very simple kind of website component, I found that will_paginate was linking to /?page= on a page that showed in the url bar [...]

Tags: , ,

Posted in: Javascript Tutorials, Ruby on Rails, Ruby on Rails, Tips and Tricks, Topics, Tutorials, Web Design | 3 Comments »

Rails 3 – PHP Style Global Variables, $_SESSION, $_GET, $_POST in the models, and everywhere.

PHP Globals in Rails 3 So, as part of my slow descent into hell for even showing this stuff, I thought I would make a quick and dirty post about getting PHP like globals into your models in Rails. I wrote a longer article about globals in the model in rails which you can check [...]

Posted in: Computer Science, PHP Tutorials, PHP/MySQL, Ruby on Rails, Ruby on Rails, Tips and Tricks, Topics, Tutorials | No Comments »

Ubuntu, Find large files by size

Here’s a handy little command for finding files in a directory over a certain size. $ find * -type f -size +90000k -exec ls -lh {} \; | awk ‘{ print $9 “: ” $5 }’ Related Posts:No Related Posts

Posted in: Linux, Tips and Tricks, Topics | No Comments »

Apache2/MySQL on Ubuntu Configuration

Once you’ve installed apache2 and mysql on your server, you might want to try these configuration changes to make it perform a bit better: In /etc/mysql/my.cnf key_buffer = 16K max_allowed_packet = 1M thread_stack = 64K table_cache = 4 sort_buffer = 64K net_buffer_length = 2K And in Apache2′s config, /etc/apache2/apache2.conf, find the section for MPM prefork [...]

Posted in: General Computing, Linux, MySQL, PHP/MySQL, Tips and Tricks, Topics, Tutorials, Writings | No Comments »

Never Again! Backing up your rails .sqlite3 dbs

Well, with mysql, it’s pretty hard to overwrite your dbs, but with sqlite, it’s real easy. I did this, luckily I only lost about a days worth of work, but nevertheless, I have instituted a new rule for sqlite3 dbs: Hourly backups. Here’s the script: #!/bin/sh D=`date +%H` cp -f /var/www/app/db/production.sqlite3 /var/www/fapp/db/production.sqlite3.bak.$D Related Posts:Rails will_paginate [...]

Tags: , , , ,

Posted in: Computer Science, General Computing, Linux, Ruby on Rails, Ruby on Rails, Tips and Tricks, Topics, Tutorials, Uncategorized, Writings | No Comments »

Rails 3 Migrations Cmdline Builder

This is a little helper for making migrations.

Tags: , ,

Posted in: Computer Science, Ruby on Rails, Ruby on Rails, Tips and Tricks, Topics, Tutorials, Web Design, Writings | No Comments »

Ruby on Rails Session in Models: Not So Evil Actually

I just finished reading this post from m.onkey.org on how to put your session into your models. First off, I love this guy, and his site, and most of what he says, but I’ve had it up to here with this nonsense. I also kind of felt a little dissed by the PHP comment. I [...]

Tags: , , , ,

Posted in: Computer Science, General Computing, OOP, Ruby on Rails, Ruby on Rails, Tips and Tricks, Topics, Tutorials, Writings | 1 Comment »

Info Tidbits and Vocabulary that you should know, Facts, Trivia

I have started this post as a collection of vocabulary and facts that every person should know. It’s not in any order, though one day I may organize it. For right now, just wander through, and learn, and come back often. All of this information relates to the world around you, the people in it, [...]

Posted in: Information, Tips and Tricks, Topics, Writings | No Comments »

Spree Commerce, eBay Trading API, and the eBay Accelerator Toolkit from Intradesys EbatNs

In this bit, I talk about using the EbatNs SDK for the eBay Trading API, to list items from your Spree Commerce store, or really any rails application. Filled with production code examples from an honest to god real live and working spree site that interfaces with the eBay trading API to Add, Revise, and End items, on ebay when they sell in your store, or on your store when they sell on eBay.

Tags: , , ,

Posted in: eBay, PHP Tutorials, PHP/MySQL, Tips and Tricks, Web Design | No Comments »

Powered by Wordpress. Design: Supermodne.