Archive for October, 2010

Links Overflowing On Chrome And IE

What to do when long links start to over flow in to the rest of your page.

This is going to be a little of a short post but I ran in to a problem that seems to of only happen in a few browsers.. Or better put it does not happen in Firefox.

The problem is that when I am pulling in my Twitter feed the links seem to go all kinds of crazy across the site.
Here is the code (or close to) that gets printed in on my site.

<li class="tweets">James_Riter: Cool Full Page Coda Slider! With demo and files to download. 
<a href="" target="_blank"></a></li>
<li class="tweets"><a href="" target="_blank"></a></li>
<li class="tweets">James_Riter: Setting up a Desktop over the weekend did not go so well. :( I think I have to buy a new motherboard. <a href="" target="_blank"></a></li>
<li class="tweets"><a href="" target="_blank"></a></li>

So as you see there is nothing out of the normal there ans what you cant see is that all that code is in a side bar the has a width of about 300px.

But in any case lets get to the good simple fix for this problem..


Add that to the cantoning div witch are holding the links. In this case the div that was/is holding the twitter feeds.

What James Riter Has Been Up To

My name is James Riter and I am a Las Vegas web designer and programmer.

Most of the time this blog or My Facebook will be the best way to keep up on my life. (So only my mom will be reading this)

But there are a few things I have in the works.
I am building my own CMS, well I have V1 of Proclarush I am re doing all the code so I am make a lot of improvements. IF you are a designer and have a small project coming up let me know. I would like some one to test my system and tell me where it needs more work.

I am going to be making a lot of changes to my site The SEO Hero. As it stands not it is just a pointless blog that I never touch. I was hoping to make it more of my own freelance site but I am going to make it a 3 part site. The main will just be basic SEO information, the second will be a blog that I will let a few other trusted people blog on about SEO work, the the theried will be a SEO twitter. I am still a ways from getting that done but I cant wait to see how it goes.

I am also going to recode my main site. I love the way it looks now but it is so slow I am sure it makes me look like I have no idea how to code a single thing. When I am done it will look the some but move a lot faster! (I hope!)

I still have no idea what I am going to do with this site but I am sure I will come up with a better idea than I site that I just use for testing.

Speeding Ticket In Las Vegas NV

We have all been there, One minute you are driving down the street (maybe a little fast) minding your own business and the next minute you are getting pulled pulled over and have a list of charges miles long.

There are a few things I have learned about getting pulled over in Las Vegas or North Las Vegas.

  • 1: Cops want to give you a ticket.
  • 2: You’re not going to walk away with just a speeding ticket.
  • 3: It is best to have someone go to court for you!
  • 4: Speeding tickets WILL cost you a lot of money!

So let’s cover this one at a time.

Number 1:  Copes want to give you a ticket.

We have all heard the jokes about it being the end of the month so cops need to make the payroll. But how much of a joke is that really?  I got pulled over for my back light being out and drove away feeling like I just got fucked over.  I know cops are not out to hurt us but they are also not there to listen to us. To the cop that pulled me over it did not matter that I was driving a friend’s car that was from out of state. I guess when he was in town for a few days he should have registered his car in Las Vegas so I could run to the gas station.  If the cop was out there really wanting to do good I think it would have been great for him to say. “Just wanted to let you know your back light is out” and called it good. But he had to run all my information and see what he could hit me with.

Number 2:  You’re not going to walk away with just a speeding ticket.

You know that it never happens that you will walk away with a speeding ticket and that’s it. It is a cops job to find things wrong and when they pull you over that’s just what they are going to do.  Just keep that in mind. It is there job to give you tickets and that will never change.

Number 3: It is best to have someone go to court for you!

I design WebPages and do SEO work. I have next to no idea what should be done in court and what is the best way to handle things.  And most people are just like me on this one. We have all been told to plead not guilty to speeding ticket but what do you do after that and more so does it really help?

I have seen it go both ways. I have seen it hurt and help a person and when it hurts it really hurts them.

The first time I had someone go to court for me I got really fucked! The guy did not show up and got a warrant for me and in the end just said “guilty” for me.

This last time (Ok it’s been 2 times) I have called a guy named Rick at Law Offices of Paul J. Adras and let me tell you it really does matter who goes to court for you.

I had a warrant for not showing up to court and needed to get it fixed without paying the thousand dollars the court wanted me to pay. So I started to make a few calls and well I thought I was going to jail. Everyone wanted like $700.00 just to take care of the warrant.  Then I found Rick at Paul J. Adras Law Office and they took care of it really fast and cost me about 1 tenth of the court wanted. (That about $100.00 for the lazy people like me)  And if you ask me that is better than waiting to go to jail or paying a thousand dollars to the court just for forgetting one date.

Number 4: Speeding tickets will cost you a lot of money!

This kind of goes hand in hand with number 3.  One way or another you are going to pay. There is nothing you can do about that. The real question is, how much do you want to pay?   I have gone to court and had it cost me $900.00 and I have had Rick help me get that down to $200.00.

To sum it all up if you live in Vegas you are going to need a good Las Vegas Traffic Attorney and the guys over at The Law Offices of Paul J. Adras, PC are great!  Trust me I have yet to save my work number in my phone (been here for about 2 years) but I saved their number.  They don’t over charge and they are kind and they don’t mess around.

You can contact them with this information

The Law Offices of Paul J. Adras, PC
4532 W. Charleston Blvd.
Las Vegas, Nevada 89102
702 489 2264

Proclarush Taonas My First CMS (No Database)

Proclarush Taonas

Well I have just finished what I am calling Proclarush [If your not a Stargate fan, it means Lost In Fire]

This is my my first try at a CMS and all in all I am very happy with how it has turned out.

Proclarush Taonas Works With NO Database

First I will let you have a link to it so you can get a feel for it and then I will tell you a little about what I have added to it.

First off you should see I kept it at a very basic design, I did this for a reason.  I am building this so that you can design skins for it and change the hole site look with about two lines of code. But this is also a place where I fell a little short. [More about that latter]

Some of what I have added

As you go over the site you will see I wanted to build some of the most basic things needed in any modern website today.  So it has things like.

Guest Book: A simple way for people to say thanks.

Media: I have built in a flash video player and mp3 player for that you can share you media and not have to worry about other hosting sites going down.

Contact Form: There is really two built in but I am only showing one for now. The second one is a popup one that works by clicking on a link.  But both of them have an auto replay to who ever filed out the form and should stop you from getting spam.

Some of the basic things I have added are things like a image popup that is shown on the front page, a mouse over tip by title,  a weather feed, a twitter feed, social links,  and best of all a client back end.

Client Backend

The client back end is one thing that I really like about it.  If you look at the About Us page you will see a little “:)” well you will see it all over the site.  Every where you see that is a spot that the client is able to edit the text from the back end.  I wanted this for a few reasons. For One I know as a designer it is a pain in the ass when you are working with a client and they call you every day wanting something little changes or some “NEW” bit of info on the front page ASAP. So now I am able to tell them they can change it as much as they would like. :)

And another good reason is, well this gives you a chance to help make the client feel like this site is theres two, and with out all the complex things that a lot of heaver weight CMSs have.

There is also a mobile side [still needs a little work] but for the most part it is done.

Have A Mobile Site With Half The Work

My goal is to have a mobile site that depends of the main site. So when I finish content for the home page it will be pulled in to both the full site and the mobile site. You can test it out on your phone or go to to see it. But as I said it is not where I want it to be.

Before I go I would like to talk about the changing of the skins. [I said I would get back to it] As it stands now there is no problem making a new skin for it that will work just fine. The only thing that has its draw backs it you have to copy all the css and js files in to a new folder and change a few links.  But it does give you the freedom the make a full new site well still keeping the main links and content in place witch I kind of liked.

Change Common Information Once And Have It Change Site Wide

Another good thing to point out about Proclarush is that I have  what I call a setting page and in that setting page you are able to change all kinds of things.

Say you have the email address, client name and phone number. Well if you use my system rite you could use all three of them over a hundred time in the site and if your client wants all three changed you will only have to change three lins of code. {I am new to PHP but I am really starting to love the power it has. :) }

Well, I am not sure I am going to release version 1, seeing that I am not going to start working on Version 2! That is going to be based on MVC and a lot of other powerful tool I am learning.

But at the same time I kind of would like a few designers to build around my system so that I can get there input and see where I need to improve what I have made so far.  So if you are a designer and have a small job coming up let me know and we can talk about giving you the files to work with.

A few helpful hints to making your first CMS or Website

I have just finished my first CMS and well I just wanted to give a few helpful hints to anyone that is like me and new to php, programing and taking on such a project.

You can view what I am calling proclarush V1 at
You can view my CMS at

As soon as I get a chance I will be doing a full rundown of what is in my little CMS.

I never planed on making a CMS, in fact when I started I was just looking to build a simple reset with a few pages in place to help me put out demo pages faster. In fact MOST of what I know about PHP I learned building Proclarush (Thats the name I gave it).

Seeing that there is way to much to go over in one post and I done really feel like sitting down that long I am going to cover the basics and a few things you should keep in mind if you are going try and build your own.

First!! Know what you want out of it!
As I said when I started I was not planing to make a CMS of any kind and that its self has come to bite me in the ass more time than you could think of! There are many different kinds of CMSs out there so look around and see what you are aiming to do. Just to give you a few things to think about here are a list of some common things a CMS would be used for.

Shopping cart:
Personal use:
Small business:
Large business:
And so on and so on…

So after you know what you want to do with it you will need to set the ground work. This is also something I did not do so well. Due to that there was a point where I wanted to change on thing and that alone made me change 6 other pages.

Lets get to the layout of things. This would be the main directory.


Keep in mind Proclarush is what I have named my system so you will want to come up with a name asao. :)

This is what inside of Proclarush looks like.


Now that you have a the main files in place it is time to start setting up some files.
Like all site you should start with an index.php but unlike a lot of site you are not going to start adding in content and images just yet. In fact there is not one div span or H tag in my index.php. I have under 15 lines of code that start it all off.

//Setting "Main_DIR" to /proclarush
define('Main_DIR', 'proclarush/');

//Pulling in the setting and directory page

//Pulling in the base skin
include_once(SKINS_DIR. 'base_skin.php');


Well my index has a few more lines this is what you will need to get started. So lest go over this line my line and what is in each file that is being called in.

Line 1:
define('Main_DIR', 'proclarush/');
This is saying that “Mail_DIR” is equal to

Line 2:
This is calling in a the “directory.php”. This will be used to create created directory constants for all the files you have in your site.

The code inside of this file look a little like this.

// This is to set up the directy list
if(preg_match('/\/$/', $_SERVER['DOCUMENT_ROOT'])) {
} else {
define('ROOT_DIR', ($_SERVER['DOCUMENT_ROOT']).'/');

//All things in the root directy
// How To Use "echo Main_DIR;"
if(!defined('Main_DIR')) define('Main_DIR', ROOT_DIR.'proclarush/');
if(!defined('BLOG_DIR')) define('BLOG_DIR', ROOT_DIR.'blog/');
if(!defined('Cache_DIR')) define('Cache_DIR', ROOT_DIR.'cache/');
if(!defined('PLUGIN_DIR')) define('PLUGIN_DIR', Main_DIR.'plugin/');
if(!defined('SITEMAP_DIR')) define('SITEMAP_DIR', ROOT_DIR.'sitemap/');
if(!defined('WIKI_DIR')) define('WIKI_DIR', ROOT_DIR.'wiki/');

//Main Folders in Proclarush
if(!defined('CONTENT_DIR')) define('CONTENT_DIR', Main_DIR.'content/');

Now you might be asking why is this a good idea? Lets say this is how things are laid out on you site to get to an image.
And you coded it something like this.

<"show" img alt="nice image" src="

Now say this is your FORM_IMG_DIR

define('FORM_IMG_DIR', ROOT_DIR.'/content/contact/form/image/');

Now was you just want to move that image to the folder with the rest of your images. well if you have a large site you may have a lot of images to relink. But if you do it this way you will just have to change that link in one place.
So change this:

define('FORM_IMG_DIR', ROOT_DIR.'/content/contact/form/image/');

To this:

define('FORM_IMG_DIR', ROOT_DIR.'/image/');

And thats it.

Now line 3:
Now this is going to be information that you will need over and over again.
Lets use four common things that you will use in a site.
Link to blog:

Well if the client ask you three months after the site is done to change her email address it could be a pain to remember where all that email address in. That is where this comes in.

The code will look a little like this.

$ClientName = "James Riter"
$ClientEmail = ""
$ClientAddresse = "Hot As Hell Las Vegas"
$ClientBlog = ""

Now every time you want my name or email in the site you can do this.

and changing my name from James to Jane only has to be done in one spot see that your client was a girl.

Line 4:
include_once(SKINS_DIR. 'base_skin.php');

Rite here I am including what I call the base skin, This file for me holds a lot of basics to the site but at the same site it does not really hold much. Just like the index.php you should call in a lot the this page to it clean and easy to work with.

Well I was going to set up a few files to download but it is getting late. If you want some and I have not added any yet just let me know and I will send something your way.

You can view my CMS at

Rite now I am on V1 and am starting to learn about MVC so will be updating as soon as I got time.

Now time I will cover
1: Building a nav
2:Pulling in content
3:What I put in my CSS

Add Yahoo Weather To Your Site With PHP

For the past few weeks I have been working on a type of CMS that does not need MySQL or any date base for that matter. :)

I am still new to php so this has been my helping hand in getting to learn a little. I am now on V2 of what I am calling Proclarush. (Yes I am a Stargate fan) And after setting up all the files and getting things to link rite I am now adding in some plugins. The one that was a pain to find was one for weather.

So lets get in to adding some weather to you site!

How I am doing this is by calling a .php file in to my site like this.

<?php include_once ('weather.php'); ? >

You can add that where ever you want your weather to show up.
**If you are new, make sure you are working with a .php file “index.php”**

Now to the code in side the weather.php I am going to put it all in at once and then help you out with how it works the best I can.

<div id="weather">
<h2 class="h2"> Weather </h2>
$weatherZIPCODE = "89145"; //Change The Zip HERE

function retrieveYahooWeather($zipCode = '$weatherZIPCODE') {
$yahooUrl = "";
$yahooZip = "?p=$zipCode";
$yahooFullUrl = $yahooUrl . $yahooZip;
$curlObject = curl_init();
$returnYahooWeather = curl_exec($curlObject);
return $returnYahooWeather;
$localZipCode = $weatherZIPCODE;
$weatherXmlString = retrieveYahooWeather($localZipCode);
$weatherXmlObject = new SimpleXMLElement($weatherXmlString);
$currentCondition = $weatherXmlObject->xpath("//yweather:condition");
$weatherLoca = $weatherXmlObject->xpath("//yweather:location");
$currentTemperature = $currentCondition[0]["temp"];
$currentDescription = $currentCondition[0]["text"];
$currentTitle = $currentTitle[0]["text"];
$weatherLoca = $weatherLoca[0]["city"];
<li> <?php print $weatherLoca;?></li>
<li>Current Temperature: <?php print $currentTemperature;?>°F</li>
<li>Current Description: <?php print $currentDescription;?></li>

You can see it working
And download the files

Now to some of the need to know stuff.

This is just saying get the file “weather.php”

<?php include_once ('weather.php'); ? >

In weather.php look at line 4 and you will see where you set you zip code.
$weatherZIPCODE = "89145";

Now to get this to show the town I wanted I had to add this.

//Make This Up //Find this is the RSS
$weatherLoca = $weatherXmlObject->xpath("//yweather:location");
//This says it = its self but is looking in ["city"]
$weatherLoca = $weatherLoca[0]["city"];
//This Will Print it out :)
print $weatherLoca;

If you go to Yahoo Weather
you will be able to find the the xlm file that the php uses to get your information.
And it looks a lot like this

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<rss version="2.0" xmlns:yweather="" xmlns:geo="">
<title>Yahoo! Weather - Sunnyvale, CA</title>
<description>Yahoo! Weather for Sunnyvale, CA</description>
<lastBuildDate>Fri, 18 Dec 2009 9:38 am PST</lastBuildDate>
<yweather:location city="Sunnyvale" region="CA" country="United States"/>
<yweather:units temperature="F" distance="mi" pressure="in" speed="mph"/>
<yweather:wind chill="50" direction="0" speed="0" />
<yweather:atmosphere humidity="94" visibility="3" pressure="30.27" rising="1" />
<yweather:astronomy sunrise="7:17 am" sunset="4:52 pm"/>
<title>Yahoo! Weather</title>
<title>Conditions for Sunnyvale, CA at 9:38 am PST</title>
<pubDate>Fri, 18 Dec 2009 9:38 am PST</pubDate>
<yweather:condition text="Mostly Cloudy" code="28" temp="50" date="Fri, 18 Dec 2009 9:38 am PST" />
<img src=""/><br />
<b>Current Conditions:</b><br />
Mostly Cloudy, 50 F<BR />
<BR /><b>Forecast:</b><BR />
Fri - Partly Cloudy. High: 62 Low: 49<br />
Sat - Partly Cloudy. High: 65 Low: 49<br />
<br />
<a href="*">Full Forecast at Yahoo! Weather</a><BR/><BR/>
(provided by <a href="" >The Weather Channel</a>)<br/>
<yweather:forecast day="Fri" date="18 Dec 2009" low="49" high="62" text="Partly Cloudy" code="30" />
<yweather:forecast day="Sat" date="19 Dec 2009" low="49" high="65" text="Partly Cloudy" code="30" />
<guid isPermaLink="false">USCA1116_2009_12_18_9_38_PST</guid>

If you are like me your thinking what the hell is that! But after looking at it for a little bit its not that hard.

Say you want to add in the wind chill.
Look for the line that says “yweather:wind”
And create a line that looks like this

$Thisisthewindchill = $weatherXmlObject->xpath("//yweather:wind");

There you are making a Variable “$Thisisthewindchill” and saying in equal to the yahoo xml file and in “yweather:wind”

Now make a line that looks like this.

$Thisisthewindchill = $Thisisthewindchill [0]["chill"];

There you are saying “$Thisisthewindchill” equals its self but is to look in “chill”.

Now all you have to do is add this line to UL/LI

print $Thisisthewindchill ;

As I said I am newish to php so I might have got something wrong, or worded something the wrong way. So if you see some thing let me know and I will change it. But I know this works and can help if you need any help setting it up on your site. Just leave a comment and I will get back to you asap!

Again you can download it

Return top