Tom’s Graphic Design Journal


research, thoughts, and reflections for print and web
NEWS: Viagra useage Diet medication online phentermine. Phentermine 37.5 free shipping Buy cheap phentermine free fedex Viagra Best price for generic viagra Phentermine raleigh Xanax 2mg generic alprazolam 180 pills Buy cheap phentermine cod Vicodin for sale Phentermine lortab online Drug interaction xanax and holy basil. Buy online order viagra Cheap prices phentermine. Phentermine rx Soma pill Cialis generic india Adipex between difference phentermine. How to get xanax Viagra cialis levitra Blindness viagra Tramadol abuse! Phentermine adipex Phentermine np with hoodia! Death cases from taking phentermine Cialis soft tabs, Lose weight with phentermine and 5 htp Cialis in uk Online viagra sale Buy viagra now online? Buy cheap meridia Tramadol online Cialis levitra better Alternative to viagra drug Picture of xanax pills Cheapest viagra online Phentermine usa pharmacy Buy online prescription viagra without Phentermine 37.5 adipex 37.5 mg Rated online pharmacies for phentermine Erectile dysfunction viagra Free viagra online, Prescription viagra Buy xanax without prescription in usa Cheap phentermine 37.5 mg Xanax no rx Buy phentermine online com Order viagra canada: Compare levivia and viagra Fioricet medication Tramadol uses Inexpensive viagra, Buy phentermine online Viagra for sale Buy in phentermine uk Buy generic viagra Oxycodone vs hydrocodone Fioricet order Order viagra Female spray viagra! Cialis immunity Phentermine and blood in stool Viagra alternates Taking phentermine Viagra by mail M357 vicodin? Ambien online Picture of xanax pill Phentermine to buy Buy xanax without prescription. Cheapest fioricet Hydrocodone pharmacy Compare viagra price Phentermine overnight: Xanax no prescription required How to get a xanax prescription Next day delivery on phentermine Compare viagra to cialis Pain medication tramadol Information viagra woman Free phentermine Fioricet line No prescription phentermine free shipping Viagra sales uk Phentermine fastin Non perscription generic viagra Do companies sell phentermine with low dose ingredients Ambien prescription Cheap tramadol online Blue 30 mg 90 free shipping phentermine pharmacy Lowest prices for tramadol online Viagra alternative and woman! Soma san diego Leo phentermine order online Soma side effects Phentermine 37.5 mg free shipping. Phentermine drug information Cialis generic india Viagra experience Black market viagra: Viagra tablet Tramadol cause kidney problems Viagra online ordering Fastin phentermine? Hydrocodone online pharmacy Lortab and xanax without a prescription. Ultram tramadol hci tablet Tramadol hcl 50 mg Buy phentermine epharmacist 100 mg viagra: Buy online salescom viagra Phentermine addiction help? Tramadol dosage for dogs Viagra testimonial Lowest viagra price Concomitant use of cialis and levitra. Fda us approved phentermine Buy online salescom viagra Phentermine pharmacies online Pictures of xanax bars: Tramadol Ambien cr effects side, Herbal substitute viagra Phentermine withdrawal Cheapest phentermine pill Cialis generic viagra Xanax pics Xanax side effects Soma seed Drug interactions tramadol elavil! Best herbal viagra Buy in phentermine uk! Best online deal for phentermine Xanax alcohol Phentermine ups shipped Viagra samples free! Berman sister female viagra study Phentermine 37.5 in round white tablets no imprint code Where to buy phentermine Canadian no phentermine prescription! Levivia viagra compared Levivia viagra Phentermine discover card Addiction tramadol Cheap phentermine Viagra alternates Phentermine tablets Phentermine 30 mg ordered with discover card! Viagra drug Drug loss phentermine weight Buy viagra cheap Viagra users Phentermine price Watson soma. Drug loss phentermine weight Adipex cheap phentermine: Online viagra consultation Phentermine 37.5 cheap Lowest prices viagra How to discontinue the use of phentermine Cheapest phentermine Order viagra Phentermine on line Filing income tax buy tramadol? Phentermine vs phentrazine Online phentermine prescription! Cheapest phentermine online Viagra female sexual inhancement Phentermine vs adipex p Free cialis samples Cialis results Phentermine rankings Buy generic viagra online Submit a site viagra? Cheap phentermine perscription Xanax picture Try viagra for free Comparisons on online viagra suppliers Womens viagra Without prescription phentermine Viagra price comparison Cheap viagra online. Vicodin health Phentermine and diet pill Xanax online without prescription Dangers of viagra Buy online pharmacy viagra Buy cheap fioricet Atenolol viagra Buy viagra without prescription: Phentermine effects Cruises soma? Buy phentermine Tramadol drug test How long does xanax stay in the system Generic cialis price: Purchase cialis online Best phentermine pharmacies compare links Viagra discussion Viagra story On line doctor phentermine Xanax valium. Non perscription viagra Prescriptions on line phentermine! Viagra mexico Cialis ineffective. How long does viagra last Phentermine and ocular hypertension Order phentermine Phentermine effects Viagra free pill Phentermine insulin Alternative to phentermine Compare levivia and viagra: Buy viagra internet Where to buy viagra on line Drug information picture identification tramadol er bvf Detox hgh phentermine quit smoking xenical! Diet phentermine pill sale Buy buy domain link online online viagra info viag Buy viagra uk Loss phentermine story weight Price viagra viacreme Phentermine blue diet pills Vicodin withdrawal Mivial valve prolapse viagra Phentermine in florida How does viagra work! Cheap phentermine prescription 25mg viagra Cialis forums Meridia vs phentermine Phentermine airborne express Natural suppliments work like viagra Order phentermine diet pill Bulk phentermine, Viagra for women Phentermine no fees, Cialis injury lawyer ohio Tramadol and dosage Viagra for sale Side effects phentermine gynecomastia, Buying vicodin online Adipex phentermine weight loss! Phentermine diet Soma online pharmacy Drug prescription tramadol Get viagra online, Linkdomain buy online viagra info domain buy onlin Buy cheapest viagra Cheapest phentermine online free shipping Phentermine ups delivery Viagra retail discount Picture of xanax pills Buy cheap phentermine free fedex Phentermine 37.5 tablet Generic viagra no perscription needed Long term effects of phentermine use Order phentermine c o d Overnight viagra Phentermine pill town Klonopin versus xanax. Viagra faq Tramadol cod Pfizer viagra Buy phentermine prozac? Diet discount phentermine pill Cheap viagra canada Xanax info Pulmonary hypertension viagra! Lexapro interaction with phentermine Phentermine in the uk Phentermine cod shipping Physical symptoms of high blood pressure and xanax Viagra testimony Wholesale phentermine Cheapest price viagra Buy phentermine online same day delivery Cheapest free shipping phentermine Viagra side affects Information on the drug xanax Grapefruit viagra Ingredient phentermine Viagra without a prescription Tools needed for injecting xanax Buy cialis viagra Maximum dosage of phentermine Phentermine 37.5mg tablets! Cod online pharmacy phentermine sell Vicodin info Buy cheap soma Phentermine weight loss pills Xanax no prescription overnight delivery Xanax side effect Cialis sample Natural viagra alternatives Woman taking viagra First viagra commercial network tv Phentermine 37.5mg cheap Herbal viagra affiliate Phentermine 180 Ambien online Viagra no prescription Buy vicodin Line prescription viagra Buy prescription tramadol without, Viagra substitutes Does phentermine help weight loss: Cialis vs viagra Is there a phentermine shortage Blindness cialis Order phentermine c o d Cheep phentermine with cod payments Viagra by mail Alternative viagra Vicodin information, Free overnight phentermine shipping Meridia side effects: Buy online prescription viagra without Buy online viagra viagra: Cheap viagra in uk Cheapest viagra in uk, Online viagra prescriptions Buy cialis generic online! Viagra xenical Viagra strip poker flash games Phentermine free online consultation Fioricet info: Buy pal pay phentermine using Phentermine free delivery: Buy phentermine online cod Natural supplement equivalent to xanax Birth defects and phentermine use Phentermine with free shipping Lethal dose of xanax Xanax indications! Xanax long term effects Xanax without prescription: Buy no phentermine prescription Buy soma Order soma Fioricet addiction Cialis forum Best price on phentermine Civiate generic sildenafil viagra Phentermine blue capules, Buy viagra now Buy cod diet phentermine pill Cheap tramadol Viagra retail discount Buy online purchase viagra Purchase vicodin. Grapefruit xanax Phentermine prescription diet pill Phentermine dangers Information about viagra Keyword prescription qoclick tramadol without Picture viagra pill Time released xanax Fatal dose of xanax Order generic viagra Ingredient phentermine Prescription tramadol Phentermine pharmacy cod Viagra strip poker flash games 180 tramadol Cialis ineffective Cheap tramadol cod? Xanax without a perscription Viagra online cheap Side effects from prozac and xanax No online prescription xanax On line phentermine Levivia vs cialis vs viagra Xanax manufacturer Phentermine saturday delivery. Viagra testimonial Order phentermine phentermine online Xanax prescription online Phentermine ionamin canada. Viagra compared to levivia Order viagra buying viagra uk 180 tramadol Tramadol 100 mg no prescription 180 tablet tramadol Symptom of vicodin addiction Klonopin xanax Generic prescription viagra without Order vicodin online Price for generic viagra Adderall skin allegra skin xanax skin Tramadol prescription Phentermine no prescription free shipping Generic cialis soft tabs Phentermine prescriptions online Tramadol 377? Cheap generic viagra Description of meridia Viagra cialis levivia dose comparison What is phentermine Cheapest prescription viagra Drug phentermine testing, Order xanax Phentermine and lexapro. Buy canada cialis Cheap phentermine pills Valium vicodin Hydrocodone dosage Phentermine use Canada viagra Herbal alternatives to viagra Cialis generic viagra Cialis uk Cheap viagra in uk Phentermine cash on delivery Free sample prescription for viagra Buy no online prescription xanax Phentermine xenical diet pill Phentermine side affects Meridia sibutramine 120 tramadol Xanax master card Phentermine directly and discreetly adipex Macular degeneration caused by viagra Pharmacy phentermine affiliate Can i buy phentermine anywhere in uk Brand drug generic name viagra Weight loss oral hcg and phentermine Phentermine law suits Overnight phentermine no prescription Meridia vs. Phentermine Female viagra Filling online prescription viagra Female uk viagra Tramadol drug Generic viagra pill Lowest phentermine 37 5 prices Xanax grapefruit. Buy phentermine online prescription Uk viagra: 150 tramadol Effects viagra Tramadol hc Generic viagra soft tab Restless leg syndrome phentermine Tramadol hydrochloride tablet Buy cheap domain onlineatspacecom xanax Free online phentermine shipping Generic viagra reviews Alternative to viagra online Compare phentermine prices Buy levivia viagra. Phentermine info Cheapest place buy viagra online Xanax master card Difference between valium and xanax Discount viagra europe Cheap phentermine with online consultation: Cheap xanax online Viagra cheap Phentermine lose weight loss diet pills Viagra overnight delivery,

Search My Blog

RSS Feeds

Articles
Comments

CakePHP 1.2 RSS

February 6, 2008. Filed under: Web Design, How-To, CakePHP | Read 2 Comments »

So oddly RSS in CakePHP 1.2 came up a lot one night recently in the Cake IRC channel. There's a really good article on the Bakery about it, but that's for CakePHP 1.1. In 1.2 it's MUCH easier to do, there's less code. So here's a short how-to, though I'm sure it's published elsewhere, the more places one can find from Google the better.

First in your /app/config/routes.php file you need to setup the routing to handle the rss extension. So just add this line:

Router::parseExtensions('rss');

Then you'll need to make some changes and add a method in your controller.

// make sure you have text and time helper, the rest are whatever else you need
var $helpers = array('Html', 'Form', 'Javascript', 'Text', 'Time');
// example method i have here, but your find methods and model will be different of course
function latest() {
       // shows latest posts
       // So the first thing here checks to see if a .rss has been requested...
       // if so get what we need for the feed
      $isFeed = ife($this->RequestHandler->prefers('rss') == 'rss', true, false);
      if ($isFeed) {
            $this->pageTitle = 'Latest Posts Feed';
            $this->set('channel', array('description' => 'Latest posts'));
        }
       $limit = 10;
       $this->set('posts', $this->Post->findAll(null, null, 'date desc', $limit, null, -1));
    }

Then we'll go over to our view template.

// this file is located under /views/posts/rss/latest.ctp
items($posts, 'transformRSS');

function transformRSS($data) {
        return array(
                'title' => $data['Post']['title'],
                'link'  => 'view/'.$data['Post']['lid'],
                'guid' => 'view/'.$data['Post']['lid'],
                'description'  => $data['Post']['body'],
                'author' => $data['Post']['author'],
                'pubDate' => $data['Post']['date']
        );
}
?>

Just take note that your model and fields will differ from what I've output in the feed. "lid" is something I created for the link id...which is part of a friendly url system I have setup for example. Everything should explain itself here, but the most important note is the location of the template file. It should not only be the name of the method (like usual) but should be located under the /rss/ directory under the model's view directory where the other templates are.

That's pretty much all there is to it. RSS is quite simple to setup compared to what you neede to do with CakePHP 1.1. The main difference is a lot of the setup and creation of the xml document is built into 1.2 for you.

You can see this specific example in action on my media blog latest post feed.

CakePHP Order By Rand()

June 21, 2007. Filed under: Web Design, How-To, CakePHP | Read 3 Comments »

Before I forget, I had to jot this quick discovery down. While not documented in the CakePHP manual (at least not anywhere I could find), it is possible to sort your associated models by RAND(). Maybe not earth shattering news to some people, but I find it interesting and handy.

So in your model file where you specify your association arrays, under the "order by" field you'll simply put "RAND()" instead of "name ASC" or "id ASC" etc.

Why on earth would you want to randomize the order of your associated models? I had to for a trivia application I was doing for work. I had a list of answers associated with questions.

So now the list of answer choices is in random order rather than by id or alphabetical. This makes it a little different for each user or each time you take the trivia. Makes it more challenging perhaps or not as easy to cheat. Also with the way the answers were originally ordered, the correct answer was showing up in the same spot over and over.

Sometimes the need to randomize is there and this is a very easy (quick) way of doing so in CakePHP.

Update: In case you didn't read the comments in this post, order by rand is not effecient and as I've read not as random as some other methods you can use. So order by rand may only be useful for you in some situtations. As with everything in the programming world there are many many ways to do things, just be sure to weigh out all your options and choose the best one.

Dyanamic Text Replacment

January 1, 2007. Filed under: Typography, Web Design, How-To | Read 2 Comments »

While I'm at it here, I figured I might as well share my two cents about dynamic text replacement. Or in other words, how I get all the pretty titles to show up on my blog automatically without creating images.

This is not a tutorial on "exactly" how. You can read some of the following sites and figure out how quite easily, the people who created these powerful scripts also include instructions. However, I wanted to review some of these better known ways as well as their pros and cons.

This text was created merely by wrapping it in an H2 tag.

There are two popular ways dynamic text replacement is done. One is by using server-side software to create images from font files (there's several ways to do that) and the other is through Flash. All of these methods do require javascript though which may or may not be an issue for some viewers. Fortunately there will always be a default display so it degrades well and doesn't ruin things. This also makes all of these methods search engine friendly.

sIFR is the way through Flash. It is quite nice and gives you the most control I think. It will allow you to fine tune and adjust spacing between words and padding/margins all around which comes in handy...but not letters, there is no kerning with sIFR becuase dynamic flash text did not support it (sIFR version 3 apparently has it, but it's beta). However, you can control leading.

Another method is by using a javascript and PHP script by Stewart Ulm, an article can be found on A List Apart about his method. Another similar method would be by using Python. You can find out more about Peter Bengtsson's approach here. Yet another variation is a script done completely in PHP and CSS that is based off Stweart Ulm's script, found at joaomak.net. There is no kerning support (currently) for these methods either...yet :)

sIFR
Pros:
Flexibility, anti-aliasing control, leading control, margin/padding control. Really nice looking because it uses Flash's engine for graphics (can technially use gradients or something for color).
Cons: Requires Flash, takes a bit of fiddling especially with odd fonts and text wrapping, larger base file size (but reuses swf file so in the long run it can be smaller), links can't use right click...to open in a new window, etc.

Stewart Ulm's Script
Pros: Fast (small file sizes..less than 5kb for a title you see here), easy to configure, doesn't require Flash to be installed.
Cons: Not easy (apparently it's somewhat possible) to kern/letterspace.

Peter Bengtsson's Script
The same pros and cons of Stewart Ulm's script...Just uses Python instead which may or may not be a con.

joaomak's Script
Pros: Doesn't require Flash or Javascript, valid XHTML and CSS, text/letter wrap (after page has been loaded...so if someone resizes their browser window), small file size (since there's no javascript and PHP is mostly server side, I'd imagine the only thing you're loading is very tiny images for each word...meaning this should be fastest loading script).
Cons: You can't specify class or id attributes on your text that you're replacing. That one hurts a bit.

One thing I didn't touch on (but hinted at) was transparencies. The sIFR technically could allow for it, so you could put your text overtop of an image background as you can with Flash movies...however, not all browsers support it. There is no (to my knowledge) support for the transparent backgrounds using the other scripts. I'm unsure if you can generate png images with the scripts...if you could, it would then be a matter of using the CSS filter property to get it working for IE6...but you then run down that road which has complications when you bring links into play.

sIFRsIFR is probably the most robust and best looking with the most options. I may in fact use it for my blog over Stewart's script. I'm not using Peter's because I'm not familiar with Python. Again, I personally did not use sIFR because of load times and because it doesn't allow for people to right click on links to open in a new browser window (and yes I have seen one attempt to fix this, but alas, it does not work on Firefox2).

I don't believe in any one "right way" for anything on the web. Any web designer/developer should know that. Even with "standards" there are just too many possibilities out there. The only two things that matter is what you can do...and what you can't do. Ultimately, it's your call...but don't go crazy with it because it will slow down load times if you were to replace ALL of your text on the page. :)

Glassy Icons

December 30, 2006. Filed under: General, How-To, Illustration | Post Comment »

Everyone (or at least I) get impressed and drool over fancy reflective beveled icons. They are much more "web 2.0" and "Mac" looking. Even Microsoft creates some nice glassy looking icons for their software these days. It just seems like the way to go and it is just about a cliche now.

There are people who get tired of it...thus we get pixel art (which is technically more of reverting to an old style - or retro) and several other graphical "movements" I will say in terms of computer user interfaces.

Internet Icon by Paul BoyerThe globes are perhaps overdone but always attractive. What is interesting though is to take that technique and apply it to other shapes and uses. Paul Boyer has taken this popular style and, I feel, expanded upon it taking it to the next level. Some of his work can be found on Win Customize, a web site that has resources on customizing your Windows user interface. He has an entire section called "Icon-A-Day." He even has gone through the trouble of making some tutorials and some very good screencasts. Yes, I've watched over 30 minutes of video tutorials by him and he certainly knows his stuff. He also makes things look easier than they are :) But in fact, it isn't terribly difficult to create those fancy reflective globes.

Boyer prefers CorelDRAW, while I've seen many many tutorials for glass globes for Photoshop (and even Illustrator), I have to agree with Boyer's choice for some of the more advanced shapes. CorelDRAW seems to be much faster as well, but that could also be because Boyer is good at what he does there. Though I have followed some tutorials for Photoshop and will say they are much more painstaking.

Scheduled Tasks Icon by Paul BoyerBoyer's icons are much more than glossy globes though. In fact, his icons are actually highly detailed and unique. I know that's difficult with all the glossy reflective icons out there, but his illustrative style is certainly refreshing and I have personally not seen many other icons with his style. I'm not an expert in the field, but I have customized my Windows interface and icons before. I've used LiteStep and many other skin programs, I've made my computer look like a Mac, and I've been to many of these customize sites years ago at least. So to me, he is the Godfather of pretty shiny icons.

I also want to make a note here. While Boyer has many icons to download in ico format for use right away on your computer, it is also possible to follow his tutorials and create larger size images. His icons are more than "icons" they are in fact illustrations and certainly have their place online and even in print. So, before you think I'm writing here about just something nifty to use for your computer settings...think again. I personally plan to read more of his stuff and watch more of Boyer's videos so I can learn how to create some nice original icons for myself to use in my blog here.

cakePHP and Eclipse/Aptana IDE

December 23, 2006. Filed under: Web Design, How-To, CakePHP | Read 2 Comments »

I started using Aptana IDE...then quickly changed to Eclipse with Aptana as a plugin. Actually, I'm using EasyEclipse for PHP...and PHPEclipse plugin and Aptana plugin. Good so far...I'll put a post about my opinions of these wonderful IDEs soon (IDE stands for Integrated Development Environment...but I still call it web editor for all intents and purposes).

I wanted to see just how much control I had with these IDEs and how useful they would be for cakePHP. It took some hunting, but I found (partially on cakebaker's blog) how to run "bake.php" from within Eclipse/Aptana. Way cool! Now I don't have to be arsed to use Windows cmd (yes, I use Windows) and keep typing in the command to use bake. I just click a little button and voila. I'm posting here because it was a pain to find and I didn't see it anywhere else so I'm sure more people will want to know how...so the more locations the information is posted....you get the idea.

This will also be convenient to anyone not using Windows as well...why open up another console and have 50 million windows open? We have enough between all the web browsers, editors, graphics applications, and system windows...

Here's how you run bake from within Eclipse/Aptana:

Set this in Run>External Tools>External Tools... with the following settings under Program:

Location: c:\path\to\php\php.exe
Working Directory: \...\cake\scripts\
Arguments: bake.php

They have browse system to find the paths so you don't need to type out all your paths.
That's it. Now you can run bake from the run external icon/menu at the top which appears in a nice little console window.

Next Page »

Tom’s Graphic Design Journal is proudly powered by WordPress. Valid XHTML
Login