Day 76 - General update

by alex 17. April 2013 17:01

It's day 76 and I feel like the last week was squandered: I didn't have any major contributions to any of my on going projects and that leaves me feeling a bit misguided.

During this time, I got back into Unity and began refreshing myself on the coding style. Why? How will it make me money? I don't know that it will, and I feel a bit guilty about that, but you have to take time for hobbies, right? Never know where a good project will come from!

I also created a Tumblr account, which I'm using to post images that might be interesting to non-programmers. This is my creative outlet. Interesting note - the Tumblr blog gained traffic much faster than this or the product blog. I'm going to attribute the ease of getting traffic to the nature of the subject matter, for now.

Taxes are done! I'll blog about that directly following this post. And I'll also make an update on the No Dice Required exploration (not looking positive after 10 days or so).

Tags:

Just a little more on dynamic pages

by alex 9. April 2013 18:14

Completely by accident, I had two similar posts queued up to be published on this blog and the product blog for Build Keeper. If you need more info on creating dynamic pages in ASP.NET MVC, you might want to check out the other post too.

Tags:

Early results on exploratory signup website No Dice Required

by alex 8. April 2013 22:31

It's day 67 of the experiment. I mentioned last week that one of my old projects, No Dice Required, recently had an unexpected surge in traffic and signups. I spent a few days last week redesigning the website in ASP.NET MVC 4 and writing new copy and user tracking code.

The new website is a coming-soon page with a beta signup. The entire site consists of maybe a dozen pages: home page (with sign up control), sign up page, sign up complete page, HTTP error pages, and a this-site-has-been-redesigned page for the pages of the old site. Additionally, there are many dynamically generated landing pages.

Home page

The old home page was poor for a few reasons. There were less than 20 words available before login and there wasn't any meta data included in the headers: together, these make it hard for search engines to know anything about the site.

The old page also didn't sell the site in any way. Why does it exist? Why should the visitor care? I'm still not particularly good at writing copy that converts, but I feel like I'm improving.

The new homepage has much more text, images, and formatting variations: these should make a visitor more interested in reading the content of the webpage.

The coins at the bottom spin, and if the visitor clicks on them then a coin-pickup sound is played and the coin counter in the top menu increases. The number of collected coins is persisted in a cookie.

I pushed this to the internet a little less than a week ago. So far there are 2 signups for the beta and it has been seen by 89 unique visitors. Most visitors haven't realized that the coins were clickable. This might be because they lack imagination and I imply that they are clickable. Implying on the internet is bad for conversion! I should have come out and said that they were clickable or collectible or something a bit less subtle.

There's quite a bit of custom user tracking going on; I will write about the details of what I'm doing. The landing pages are done, except that I still need to work out the creation of dynamic sitemaps. The trouble here is that I can't easily route a single file to a controller action without also routing all files through the ASP.NET pipeline as well; doing that would be a performance nightmare.

Creating dynamic data-driven landing pages in ASP.NET MVC

by alex 8. April 2013 19:26

Creating dynamic landing pages

I mentioned in the last post that No Dice Required was updated. The real experiment with this site is that I'm playing with scaling out SEO efforts by drastically increasing the number of landing pages.

A landing page is the first page of your website that a visitor lands on. A certain amount of visitors to nodicerequired.com will be looking for "language learning tools", but another group will be looking for "Japanese food words." Ideally, the visitor should land on the home page for the first phrase but the 2nd phrase, "Japanese food words", has no place on the homepage. That's where landing pages come in.

Landing pages are kind of like search fodder to give you more indexes in Google. There are two goals: one is to grab search phrases which are related to your problem domain but not necessarily related to your product, and the second is to then route visitors into your website from those phrases. Above all else, landing pages should resolve some need the visitor has.

It would be easy to create a dozen landing pages by hand, but this has scalability problems; hand-crafting a dozen similar pages isn't what you or I should be spending our on. As a programmer, this problem has an easy programming solution!

First off, you should remember that there isn't anything particularly unique about a landing page, other than that it generally has many crosslinks to other content on your site (and maybe to other landing pages); however the rest of your site generally won't have links to landing pages.

The rest of this post is techy and related to creating landing pages in ASP.NET MVC 4. If that isn't your cup of tea, then you should probably move on to the next article now =)

Defining your data structures

You need to consider the data that you'll need to populate a page. For No Dice, I planned to have each landing page be a list of translated vocabulary words, and it will include links to other lists, and the lists are grouped by categories.

I have POCO objects to support these goals. The POCO objects may look a little wonky, but I'm using them directly with Entity Framework to build my database via Code First, so I can deal with the weird virtual properties.

public class Word
{
    public int ID { get; set; }

    public DateTime DateCreated { get; set; }

    public int UserID { get; set; }

    [StringLength(256)]
    public String Text { get; set; }

    [StringLength(10)]
    public String Language { get; set; }

    public int? WordListID { get; set; }
    public WordList WordList { get; set; }
}

public class WordList
{
    public int ID { get; set; }

    public DateTime DateCreated { get; set; }

    public int UserID { get; set; }

    public String Name { get; set; }

    public virtual IList<WordListCategory> WordListCategory { get; set; }

    public virtual IList<Word> Words { get; set; }
}

public class WordListCategory
{
    public int ID { get; set; }

    public DateTime DateCreated { get; set; }

    public int UserID { get; set; }

    public String Name { get; set; }

    public virtual IList<WordList> WordLists { get; set; }
}

That's pretty simple. There's a one to many relationship between WordList and Word, and a many to many between WordList and WordListCategory. Or, in other words, every Word is in one WordList; every WordList has many Words and many WordListCategorys.

The data model I'm using isn't exactly like this, but it's similar enough for this discussion.

I don't want every WordList to be a landing page, so I also have a Page object:

public class Page
{
    public int ID { get; set; }
    public DateTime DateCreated { get; set; }

    [StringLength(256)]
    public String Name { get; set; }

    public String ViewName { get; set; }
    public String ViewMasterName { get; set; }

    [StringLength(256)]
    public virtual String Stub { get; set; }

    public int WordListID { get; set; }
    public WordList WordList { get; set; }

}

For every landing page that I want, I create a Page object and configure it to use a WordList, give it a stub and a name, and it's good to go.

You might also notice that I added a ViewName and ViewMasterName property. This allows me to configure which .cshtml file will be used to render the landing page, in addition to a Master Page or layout, so that every page doesn't necessarily have to have the same look and feel as the others or the rest of the site.

Persisting the objects

You'll need some place to persist all these objects, probably XML files or a database. Personally, it's quickest for me to drop them into an Entity Framework DbContext and use SQL Server.

public class DiceContext : DbContext
{
    public DbSet<Word> Words { get; set; }
    public DbSet<WordList> WordLists { get; set; }
    public DbSet<WordListCategory> WordListCategories { get; set; }

    public DbSet<Page> Pages { get; set; }

    protected override void OnModelCreating(DbModelBuilder modelBuilder)
    {
        modelBuilder.Entity<Word>()
            .HasOptional(p => p.WordList)
            .WithMany(d => d.Words)
            .HasForeignKey(p => p.WordListID)
            .WillCascadeOnDelete(false);

        modelBuilder.Entity<Page>()
            .HasRequired(p => p.WordList)
            .WithMany()
            .HasForeignKey(p => p.WordListID)
            .WillCascadeOnDelete(false);
    }
}

Landing page Controller

Create a new LandingPageController class, which will handle page requests.

Here's mine:

public class LandingPagesController : BaseController
{
    public ActionResult Index(string language1, string language2, string stub)
    {
        Page p = null;
        // [...]
        return View(page.ViewName, page.ViewMasterName); 
    }
}

I need to know the name, ID, or stub of the page to be rendered. I decided to use a stub instead of the page ID because stubs are more friendly to search engines and users. I also need to know which language the visitor knows and which language they want to study, language1 and language2. From these three data points, I can find a Page, which indicates a WordList. I can find the appropriate words using language1 and language2.

Routing URLs to your Controller

I've talked about routing in a few other posts. You want to make sure that your URLs look good. By that, I mean they should be shallow and keyword-rich. Having your keywords in the URL makes your page look more useful to search engines.

Create your new routes in the Register_Routes method (this might be in global.aspx.cs or RouteConfig.cs).

My route will interpret all 3-segmented URLs as a landing page: the first value is language1 (the visitor's native language), the 2nd is language2 (the visitor's study language), and the third value is the stub of the page to be displayed.

I will probably have to make some revisions to this routing structure if I get enough interest to make me revive this project.

public static void RegisterRoutes(RouteCollection routes)
{
    routes.IgnoreRoute("{resource}.axd/{*pathInfo}");

    routes.MapRoute(
        name: "Landing Pages",
        url: "{language1}/{language2}/{stub}",
        defaults: new { controller = "LandingPages", action = "Index" }
    );

    routes.MapRoute(
        name: "Default",
        url: "{controller}/{action}/{id}",
        defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
    );
}

After this, I can load URLs like http://www.example.com/english/japanese/food and it will be routed to the LandingPageController, with the parameters properly filled in.

Finally, the easy part: create a view and go crazy in the ways you normally would to create and populate a view. Mine looked like this in the end:

Dynamic Sitemap.xml files for bots to detect the pages

You might be asking yourself, "If my homepage doesn't link to any pages that eventually link to the landing pages, how will they ever show up in search results?" Good question.

Right now, they never will. We need to create a dynamic sitemap file and submit it to our search engines of choice so that they know about the landing pages and can index them properly.

This post has gone on long enough, so I'll cover this topic later tonight or tomorrow.

If you run into any issues or have any questions, feel free to share them in the comments below!

Estimating your software startup costs and my personal budget

by alex 5. April 2013 21:27

If I had a super power, it would be data analysis and forecasting.

...I mean, if my current skill set had anything on the level of super powers. I would never wish for that super power.

I'd rather be invisible. Or have telekinesis. Or flying powers.

Anyway.

like running numbers and forecasting costs. Back in 2007 or so when the US has the new home buyers tax credit, it took me 3 months of running numbers and reading up on tax codes before deciding between buying a house and renting. (Side note: I went with renting because it would have taken about 9 years for my unit house to break even with my unit apartment. More on that later, maybe.)

Naturally, I track all of my expenses (my Mint account has almost 5 years of history) and it wasn't terribly difficult to estimate my costs when deciding to start my own business. The scarier part was actually deciding to quit my day job.

Supposing that you want to start your own business, be it a pet shop or a software startup like me, you have to know how the money side of things will work. How much will you spend on your business? How much can you expect to make? How long can you run on savings? How will you provide for your family and any employees you have?

Scary stuff.

Here's how I did it.

Figuring out your personal budget

The first step is to figure out your current personal budget, or your current cost of living. The goal of calculating your personal budget is to know how much it costs to live your current lifestyle per day, month and year. It's actually pretty easy to create. There are two basic steps:

  1. List all the things you spend money on, how much they cost and how often you pay for them.
  2. Do math.

Really and truly, it's that easy.

First, make a list everything you spend money on and group it by how often you pay for it. If you support a family, don't forget about the costs of your spouse and children.

Daily expenses: Food? Cigarettes? Coffee? Road tolls? Gas for your car?

Weekly: A personal allowance? Maybe a weekly parking fee?

Monthly bills. Student loans? Child support? Credit card payments? Any online accounts you pay for monthly? Hulu Plus? Rent or mortgage? Electricity, heat, telephone or cell phone? Cable TV? Internet? Milk deliveries?

Yearly expenses: Car insurance? Many online subscriptions like Amazon Prime are billed yearly - have any of those? Christmas and birthday gifts for friends and family? Taxes? Car inspections and registrations? Car maintenance? Hair cuts?

Then, add a cost for each item, for example electricity: $50 per month.

From here, it's a few math operations to figure out your total personal liability.

  1. Add the costs for each group separately: add all the daily items together, then add all the weekly, then monthly and yearly.
  2. Multiply the sum of daily costs by 30, and write down the result. This is your monthly cost of all daily items.
  3. Multiply the sum of the weekly costs by 5 and write down the result. This is your monthly cost of all weekly items.
  4. Add your result from 2 and 3 to your monthly total and multiply the sum by 12. This is your yearly cost for all daily, weekly and monthly items.
  5. Add your result from 4 to your yearly total. This is your total yearly cost.

Tada! Now you know how much it costs you to live your currently lifestyle for one year. You can take this number and divide by 12 to get your monthly cost of living or by 365 to get your daily cost of living. The interesting thing about the daily cost of living is that this shows you approximately how much you have to earn every day to continue your lifestyle.

The next question would be, "How much money are you making now?" If you're earning less than your cost of living then you are not in happy place (unless you have a lot of money in savings). You need to earn more than your cost of living to afford that lifestyle indefinitely.

Finally, keep in mind that your budget is a tool that allows you to forecast your financial costs into the future, so it is important that your budget accurately reflects what your spending habits are. Maintain your budget by adding items that you forgot about, removing items you don't use anymore, and adjusting the numbers to your actual habits.

Figuring out your business budget

Now that you know how to calculate a budget, determining the business budget should be simple. The only difficult part will be determining what you will need to spend money on.

A few ideas for you:

Office rent, electricity, computers, computer maintenance, insurance, business origination fees, lawyer fees, accountant fees, employee wages, employee benefits, taxes, web space, domain names for your website, web designers, marketing, insurance, accounting, human resources, wholesale product prices, engineering cost of product development, certifications, clearances, insurance.

My head hurts. I recommend you read the internet A LOT. Learn as much as you can about various costs associated with starting a business and decide which ones apply to your situation. Create estimates for how much each expense will cost and figure out your business's budget and add it to your personal budget to determine what you're on the line for exactly.

I can tell you from my own research that as soon as you have employees your costs shoot up and your liability increases. This is the main reason that I've put off having employees - I'm running my business off my personal savings and I can't afford to hire anyone.

My personal and business budget

I'm using this blog to record my personal mistakes and successes in hope that it will help someone someday. To that end, it might be useful to see my own budget and things I have to pay for while running this software business.

I budget $10 a day for food, and $20 weekly for a general purpose allowance (this is how I pay for all of my entertainment).

Monthly: Health Insurance - $130, Rent - $500, Storage Unit - $100, Personal Care (soap, razors and such) - $50, Gas - $40.

Yearly: Car Insurance - $1280, Gifts - $500, Car Registration - $35, Car Inspection - $50, Filing Taxes - $100, Oil Change - $70, Haircuts - $80.

As you can see, I'm very frugal. If it isn't in this list then I don't plan on regularly spending money on it.

So, $10 * 30 days = $300 a month for food + $20 * 5 weeks = $100 a month for allowance, which is a total of $400 a month for food and allowance.

Monthly bills add up to $820 + $400 for food and allowance = $1220 per month or $14,640 a year for food and allowance and monthly bills.

Yearly bills total to $2115 and combining with the previous accounts for a total yearly budget of $16755.

That means, it costs me $16755 a year for me to exist - a place to live, food to eat, and so on. This is a minimum-acceptable life style for me. I could cut out the gifts allowance, but I like giving birthday and Christmas gifts to my family. I could cut out the car, but it gives me flexibility that is worth the cost (try living in rural Pennsylvania without a car).

...I may start shaving my head to cut out the haircut allowance =)

Additionally, there are a surprisingly small number of business expenses:

Monthly: Web hosting - $3.50, Marketing - $100, Dedicated IP Address - $2

Yearly: Domain names - $79.24, SSL Certificate - $27, PO Box - $76.

Everything else is free in one way or another. I have a few free online code repositories, I use a lot of free tools and the Microsoft BizSpark program gives a lot of free software.

The business costs add up to an additional $1448.24, which is pretty small. In hindsight, the PO Box was a waste; I never use it and most forms requiring an address won't accept PO Boxes.

Adding my personal expenses, $16755, to the business expenses, $1448.24, my total cost of living while running the business is $18,203.24 a year, or $48.88 a day.

If I can earn $50 a day after taxes, then I'm sitting pretty.

In the end...

...if you want to run a successful business (one that can reliably feed you and your employees), it is absolutely critical to know how much it costs for you to actually do business. If you can't earn more than that cost, then you're probably not in the right game.

Tags:

Meta

About the author

Something about the author

Month List