Archive for the ‘PHP’ Category

A new mod for Easter

Saturday, April 3rd, 2010

It’s sweeter than candy!  I just finished a new mod for LJScript exchanges which I call the ‘buffs mod’.  If you’ve ever played an MMORPG, then you’ll know what a buff is, but if you haven’t they are basically a spell, item, or similar object that will increase a particular stat in the game.

The buffs mod offers similar rewards while surfing.  These rewards affect the duration of the surf timer, the surf rates for credits, banner impressions, and text ad impressions, and a special buff that allows a user to ‘possibly’ receive random referrals for the rest of the day.

Buffs are fully configurable from within the admin area, where you can set how often they show up, just how much the buff effects, and how long it lasts for.

Users can recieve instant buffs which become immediately active, or collected buffs which they can save and use later for when they want to get their powersurf on.

Buffs disappear when a user logs out/logs back in, so if they leave they will lose any buffs they currently have.

The mod comes with 6 buffs ready to go, and others can be programmed in to work with any unique features your website may have.

It is my hope that this mod will increase the activity at your website as well as the quality of your traffic, but it can only do that if I can install it.  I’m offering this mod for $60 + $15 for any additional buffs you’d like programmed into it.  It can be made to work with any feature so long as you have an idea for how you’d like the buff to work.

You may see a demo of this mod in action by surfing at my LJScript sandbox.

Purchase the buff mod today!

“Easy Unsubscribe” and CANSPAM Compliance

Thursday, January 15th, 2009

Tim Linden of StartXchange wrote today about Traffic Exchange owners who aren’t complying with the CAN-SPAM Act of 2003.

Article: The Big Bad List

This law, in a nutshell, was signed by President Bush in 2003, sets forth requirements for businesses sending commercial email, and did absolutely nothing to reduce the amount of SPAM sent over the internet. It states that “any electronic mail message the primary purpose of which is the commercial advertisement or promotion of a commercial product or service (including content on an Internet website operated for a commercial purpose)” must have the following.

  1. An unsubscribe link, that works, in all emails sent
  2. Requests to unsubscribe from a list are honored within 10 days
  3. Opt-out lists are only used for complying with the law (and not sold to someone else so they can add them to their list)

Tim listed 20 traffic exchanges that sent him emails without an unusbscribe mechanism in place to comply with the CAN-SPAM act, most of which are LJScript exchanges. In order to opt out of an LJScript you would typically need to delete your account. The script itself does not supply an easily usable link to simply unsubscribe/delete the account.

Until now.

I’ve recieved two inquiries in the past couple weeks about a mod that would do this, and after reading Tim’s post I decided to push it out quickly. The Easy Unsubscribe mod is ready for use by LJScript exchanges. It will cost $25 and could be installed in a matter of minutes.

The mod allows users to click a link, which will be in each email sent out by the Admin, and unsubscribe. At the page, they will be asked for their password for security purposes. After they provide the password they click unsubscribe and their account is deleted.

Update Tim informs me that asking for a password isn’t CAN-SPAM compliant either, and while not as secure, the mod is updated so it will request their email address instead.

New Admin Sortable Mod for LJScript Exchanges

Tuesday, May 27th, 2008

I have a new mod available that will clean up some of the tables in LJScript’s admin control panel for users, user sites, site reports, contact requests, banner rotator, and text rotator and allow you to sort these lists by their fields. This mod is only available for LJScript exchanges.

Before After
admin sortable before admin sortable before

This mod is available for sale for $50. Check out the mods page for details.

Captcha Mod Released

Friday, September 7th, 2007

I have just finished developement of a captcha mod for traffic exchanges. This mod is an anti-cheat feature which will ask the user to input a 6 digit code every so many pages surfed. In the case of the LJ Script it will replace the surf verification feature that is default in that script, but may be turned off in the admin area (which will return your site to using the questions as before).

Captcha is a common turing test feature among many of the latest open-source scripts and e-commerce websites and is very efficient at preventing bots from using a particular service. If you’re worried about bot activity and would like to purchase this mod now please visit my Mods page. It costs $45 and can be running in as little as 15 minutes.

Demo: Captcha Mod Demonstration
Demo: Sign up and surf to see it in action

Testing the GD Library

Friday, September 7th, 2007

The GD library allows a server to render simple graphics. It’s not photoshop, but it is highly useful. Especially for CAPTCHA pages, a typical feature which I am in the middle of developing for traffic exchanges.

CAPTCHA stands for ‘Completely Automated Public Turing test to tell Computers and Humans Apart‘, and typically uses the GD library to create a graphic with a random string or word, sometimes distorted, that a human can decipher and input back to the server but bots can not.

There are many other uses for the GD library, but this is an extremely common one these days.

When developing a script which uses image rendering through the GD library sometimes (usually) you get to a point where you have to check if the library is installed on the server. It’s a big plus to a developer if the code he’s writing can actually work.

So I was really pleased when I found a simple script by Dagon Design that tells you straight out that GD is installed. You can look at phpinfo() to find this info, but I find this nicer and more to the point.

Perhaps this will be as useful to you as it will be to me:
Script: Checking for GD support on your server

FizzBuzz

Thursday, August 23rd, 2007

I came across an interesting article today on weeding out weak programmers. Simply ask them to program FizzBuzz.

Using FizzBuzz to Find Developers who Grok Coding

FizzBuzz is a game children play in the UK where they each sit is a circle and begin to count. The catch is that if the number is a multiple of 3 you have to say ‘Fizz‘, if it’s a multiple of 5 you say ‘Buzz‘, and for multiples of both 3 and 5 you have to say ‘FizzBuzz‘.

Supposedly many computer science majors and other applicants for programming jobs can’t do this simple task.

On occasion you meet a developer who seems like a solid programmer. They know their theory, they know their language. They can have a reasonable conversation about programming. But once it comes down to actually producing code they just don’t seem to be able to do it well.

You would probably think they’re a good developer if you’ld never seen them code. This is why you have to ask people to write code for you if you really want to see how good they are. It doesn’t matter if their CV looks great or they talk a great talk. If they can’t write code well you probably don’t want them on your team.

After a fair bit of trial and error I’ve come to discover that people who struggle to code don’t just struggle on big problems, or even smallish problems (i.e. write a implementation of a linked list). They struggle with tiny problems.

FizzBuzz sets out such a simple task that anyone who can program should be able to write up a code that can do this in a couple of minutes. It’s amazing to hear that many of the applicants who apply for a programming job aren’t able to do this.

Perhaps the question is too easy. At first I thought there had to be some sort of catch to it. A trick question. But no, it is that easy. Simply write a program that will count from 1 to 100 replacing multiples of 3 with ‘Fizz‘, multiples of 5 with ‘Buzz‘, and multiples of both with ‘FizzBuzz‘. No tricks. No hidden catches.

So naturally as a programmer myself I immediately had to set out to prove my competence by writing FizzBuzz in PHP. While my design is far from elegant, I assure you that it works, which puts me in that club of programmers who can program.

// SET TWO VARIABLES
$multiplesofthree = 1;
$multiplesoffive = 1;

for ($i=1;$i<=100;$i++) {
if ($multiplesofthree==3 AND $multiplesoffive==5) {
$tehprintout=”FizzBuzz”;
$multiplesofthree=0;
$multiplesoffive=0;

} elseif ($multiplesofthree==3) {
$tehprintout=”Fizz”;
$multiplesofthree=0;

} elseif ($multiplesoffive==5) {
$tehprintout=”Buzz”;
$multiplesoffive=0;

} else {
$tehprintout = $i;
}
$multiplesofthree++;
$multiplesoffive++;

echo “$tehprintout
“;
}

Article: Why can’t programmers.. Program?

Whitespace Graphic
Quick Buttons Navigation
Tabbed Buttons Navigation
Subscribe to Four Points Cardinal's RSS Feeds Foponet Services F.A.Q. Traffic Exchange Mods Open Source Contact Me About Me FopoNet Blog