I was really getting sick of having to keep updating my code to accept different special characters. I was doing a simple php str_replace to take a special character and turn it into a space or just remove it. I did a little more digging and decided to use this line of php code:
$string = preg_replace(‘/[^a-zA-Z0-9_ -]/s’, ”, $string);
This takes my title and removes everything except a-z, A-Z, 0-9, _, -, or a space. It simply removes all special characters from the string… in this case my title. I let the wordpress title keep the special characters but just don’t pass them on when doing my keyword and API calls.
So that should be the end of most of my special character errors. I pushed the updated code out to all my new sites using the batch file I wrote about in the previous post. I am loving that!
Our 5th EPN niche site is Good Digital Cameras. This is a new domain registration. One thing I love about this site is that I can come up with almost limitless titles for the keyword Digital Cameras. Many of which include specific model numbers and brands. This is great for those long-tail search engine results that I am looking for. I think I will be doing more sites like this soon… that have model numbers and brands in the titles.
Do you prefer .com domains vs. .info domains?
I’ve been playing with .info domains because of the low price.
I too was attracted to .info because of the price but a fellow reader here got me away from them. My sites got de-indexed from google very fast when using .info. I have no hard evidence of this but from my peronal experience the big G looks at .info a lot closer then .com since so many spammy sites show up due to the low cost. Spend the extra 8 bucks or so as it is worth it and not very hard to earn that much back over a year from a site to at least break even.