Wordpress

Easy aMember Protect Lite WordPress Plugin

Announcing the release of a new plugin for WordPress (single and multisite) that will allow you to use your purchase of aMember to protect your posts and/or pages very simply, easily and best of all – do it for FREE!

Download the plugin at the wordpress site here

Download aMember 30 day trial here

How to install

  • Download the file from the official WordPress page or visit your WordPress dashboard, go to Plugins/Add New and search for “easy amember protect lite”.
  • If you downloaded it, extract the folder from the zip file and upload the whole folder to your wp-content/plugins/ directory using FTP
  • Activate the plugin

How to configure

The plugin assumes that your amember installation resides in a folder called amember in the root of your wordpress install. If your installation uses a different folder name or is in a different location you will need to set the correct location in the settings page.

How it Works

You should already have some products in your aMember setup and the PHP_Include plugin activated (it should be anyway).

The plugin will use the product ID number from your aMember setup as the value of the custom field you add to the posts or pages that you want to protect.

The aMember product you want to allow access to

Once you know your product ID, add the custom field to the post you want to protect.

Add a new custom field with the product number from aMember you want to allow access for

If you want to allow access to more than one product, add a new custom field for each product.

Allow multiple products

Format your post with –more

If your blog shows the whole post in the archive view or blog post list, you need to use the < !--more--> tag after the text you want everyone to see. Once someone clicks on the title of the post or the link to read more, they will get redirected to the amember login page (if they aren’t already logged in).

the more tag in HTML mode

The more tag in wysiwyg mode

Have fun!

With a bit of imagination and time on the amember forums, you should be able to get your own premium content membership on WordPress site up and running in next to no time!

Notes

This plugin is not a replacement for the official amember wordpress plugin, it wont create a new user on WordPress or allow you to log in to both sites. It simply allows you to protect a single page or post from being seen by someone unless they have an active subscription to one of your amember products.

This plugin is provided ‘as is’ and is free for you to use any way you wish.

Hire me to do your dirty work!

If you want support, modifications and/or custom code then you can contact me on the amember forum (my username there is Andyb) with the details of what you want and request a quote. Prices range from 20$ for telephone support, 50$ for a simple mod, 100$ for custom coding additions and up to and over 250$ for more complex requests. (quotes are free and it costs nothing to ask!)

If you want to try out aMember before you buy, you can download a fully functional 30 day trial for free here. I recommend it if you need a quick solution to add a paywall to your site or you want to charge people to download an ebook, zip or other file.


Stickin it to the G-man? no need, seriously! Dont!

It always amazes me how much time and effort that people will put in to SEO tricks and tactics, how they swear that they know Google will ‘see’ this or ‘know’ that based on some rumour of a overheard bit of gossip written by a black hat SEO guru. Lol, what is a SEO guru anyway?

It’s an emperors new clothes designer that’s what! If someone tells you that they know what the Google algorithm wants then they are feeding you a line of BS because no one knows and if they did, Google would change it so it would be old news very quickly.

Is all SEO hopeless or even real?

Of course not! there are things that you can do that are known as ‘best practices’ or more commonly known as, ‘common sense’ and you can find out about them from Google itself from their webmaster pages and blog.

A good friend of mine who has successfully got his clients to the number one position on Google for their chosen terms recently wrote an interesting article on SEO and is it real?. He spends his life on and around Google search and even he says that you can try too hard.

The human factor

I recently had emails go to and fro with a colleague and she was quoting another SEO guy who said to bold this term and only do it once and how that is how the Google algorithm ‘knows’ what the article is about.

That makes me lol! Google algorithm ‘knows’ nothing! it can’t ‘see’ anything either, it can only trawl text and html source. It doesn’t look at images, it only stores what they’re name is and whether or not it has a caption and what that caption is.

Here’s a little experiment I want to try to prove that last paragraph..


A new luv in my life

I’ve started coding the upgrade to my CommentLuv plugin, it’s going to be called CommentLuv 3.0 (original huh?) :)

More features than you can shake a stick at

This time around I want to do it all again from scratch and I’ve already got a good idea of what I’m going to add to it.

  • Dofollow
    Just for the last blog post link and it’ll be configurable like Lucia’s linky luv plugin
  • Keyword luv (sort of)
    This will allow a registered comluv user to have their registered site name next to their real name in their comment.
  • Custom CSS
    How many people have been asking for this? lol, it’ll be in the new version!
  • Use the new comment meta table
    I’ll store the last blog post, user id and request id in the comment meta so the comment text doesn’t get mangled and every link will be identifiable by the info panel. no more ‘cannot find member’ messages.
  • Auto registration
    Why not allow the blog that installs commentluv to click a button and be registered straight away? yey!
  • Premiumness
    I would like to add premium options, one would be to allow you to give your registered users a full 10 posts to choose from when they comment.

If there’s more you want to add, let me know in the comments…

[edit] I’ve just realized, this post is number 300 on this blog. Synchronicity. mmm Yummy.


oh batshit, it’s happened again. thrice

What a load of bollox! This seems to be the week I experience maximum crashage.

Hard times/drive

First, my shop pc had a hard drive crash. A massive one. The drive wouldn’t even spin! I tried the usual methods found on a Google like putting it in a plastic bag and putting it the freezer which is supposed to fix a jammed disc.

nope.

Then I tried what this page tried. Basically, swapping the logic board from an identical drive to the faulty one. That actually got the drive spinning and recognized in windows but unfortunately, it was completely trashed. Every sector screwed and no matter what software apps I threw at it, it wouldn’t play. (so I took it apart to see how it works)

Lost code

All my backups of my server where on that disc. All.of.them!

In a great wave of relief, I found that 99% of it had been updated to the live server only the day before. The 1% that didn’t just so happened to be my awesome edit of the pay-to-blog plugin which I was about to put on ComLuv. dammit, that was some good coding I added to the plugin.

It would have allowed me to set a free time limit on new blogs of say 30 days and when that runs out, the next time the blog owner tried to log on, they would be presented with a page where they can pay a piddly 5 USD to have the blog enabled for a year. If they didn’t want to or couldn’t pay then they could request a free blog and that would notify me by email and list the request on my admin page.

I’ll have to rewrite the code and I bet I can’t remember how I did it!

New install, new problems

I managed to grab another hard drive and put it in the box to replace the poop one. Installed Ubuntu 9.10 and vwmare and got all the shop POS software working with the ancient equipment we have. Sweet! until… only 24 hours of nice working, it went pooooop. Something to do with i810 video drivers missing. Cue 5 hours pissing about with sudo apt-get and other linux bollox until at last, it is working again.

And then Vmware decided to stop working with the serial port via USB. Pleh!

More sudo apt-get and 2 hours later, I found an old vwmare image for the win98 system and copied over the contents of the .vmx file and ta-da! it worked again.

No more please!

No more. thanks. done it now.

New Wheels

At least the new wheels look good on Twitpic

Even these got delayed by 3 days. Next day delivery bleeeeuuurrgh!


Taming the Upgrades plugin from http://premium.wpmudev.org

If you’re lucky enough to have a subscription to Premium WPMU Dev account then you’ll have access to great monetization plugins like the Upgrades or Supporter which take all the pain out of providing a ‘pay for’ service that can handle payments through Paypal, Google or even Amazon gateways.

I downloaded and installed the upgrades plugin a while ago and I’ve used it to monetize certain parts of my ComLuv site. There’s the usual way of adding plugins to the Upgrades directory and configuring them to be used which I’ll go into in a future post but I wanted to use the system slightly differently, and that was to charge users for adding new URLs to an account or to add default links to their returned list of posts.

The advantage of premium

Some of the advantages to using wpmupremium plugins is the support you receive, knowledge that the plugin will be updated to keep it compatible with new changes and my favourite is, the quality of the code.

When you’re getting premium, you’re getting premium code which for me personally, has taught me a LOT about how wordpress works. Particularly custom hooks and actions and filters. That was always a mystery to me until I dissected the plugins I downloaded from their site so it was a breeze to modify the upgrades plugin to work for users who don’t have blogs and start using the internal functions in a daughter template to do what I wanted.

Modifying the upgrades plugin


I needed to allow the upgrades menu to show for regular users because not everyone who joins the Comluv site starts a blog. This was just a simple case of changing the user level so that everyone, not just blog owners can see the menu and buy credits.

There are two places to modify:

/mu-plugins/upgrades-framework.php
line ~ 197-200 (upgrades plug pages framework function)
change add menu and submenu calls to

add_menu_page($upgrades_branding_plural, $upgrades_branding_plural, 0, 'upgrades.php');
add_submenu_page('upgrades.php', __('Credits'), __('Credits'), 0, 'credits', 'upgrades_credits_output' );
add_submenu_page('upgrades.php', __('History'), __('History'), 0, 'history', 'upgrades_log_output' );

line ~ 1919 (upgrades_credits_output function)
change user check to

if(!current_user_can('level_0')) {

Creating the daughter template

Adding another page you can use as a template is pretty easy, you just need to create a new php file in your theme directory and make sure it has the correct remarks at the top to identify it as a template page.


/*
Template Name: ComLuv purchase url
*/

Next just copy and paste the main calls from another template, you’ll be deleting most of it like the loop to display posts and replacing it with your own hard coded form and text. Be sure to keep the divs that surround the content intact.

I wrote a description of the item being sold and added a form.
(DON’T copy and paste from this page, I had to remove the beginning < characters from the code so it displays properly)

form action='/member/additional-urls/' method="POST">
input name="addurl" type="text" size="30"/>
input type="submit" name="submit1" value="Submit"/>

/form>

I also added a finish_page() function which just closes the /div tags so I could easily break out of what I was displaying without rendering the rest of the custom code below it.

You set the action to the page slug you’re publishing the page as and put a nonce field in there so you can check it with the next bit of code to prevent a naughty user from trying to call the purchase directly.

Handling the purchase

Next, you need to handle the data that gets submitted by your form and do the magic with the users credits.

if(isset($_POST['submit1'])){
$nonce=$_REQUEST['_wpnonce'];
if(!wp_verify_nonce($nonce,'addurl1')){
echo 'Page request deformed, please go back and try again. (b1s1)';
finish_page();
}
if(!$_POST['addurl']){
echo 'Please go back and enter a value';
finish_page();
}
// check if user has enough credits
global $user_ID;
$credits = upgrades_user_credits_available($user_ID);
if($credits < 3){
echo 'h2>Error - Insufficient Credits/h2>';
echo 'p>You will need to purchase some credits to register another URL, you currently have strong>'.$credits.'/strong>';
echo 'p>a href="/wp-admin/upgrades.php?page=credits">Click here to visit the purchase page/a>';
finish_page();
}
// if we're here then everything is ok to provide service and deduct credits
$credits = upgrades_user_credits_available($user_ID);
$credits -= 3;
upgrades_user_credits_update($credits);
upgrades_log_add_msg($user_ID,'You paid 3 credits for an additional URl - '.$url);
do_add_url($url,$user_ID);
echo 'h2>Site added, 3 credits used on your account/h2>';
echo 'p>You have '.$credits.' credits remaining';
echo 'p>a href="/member/additional-urls/">Click here to refresh the page/a>';

The first bit gets the nonce you created and checks it and displays an error message if it doesn’t match
Next, check the field you’re expecting and spit out an error if it is empty.
Next, check the user has enough credits and spit out an error if they don’t.
If everything is fine, continue.

use $credits = upgrades_user_credits_available($user_ID); to get the users current credits total
use upgrades_user_credits_update($credits); to set the users credits total to $credits (after you deduct what your item/upgrade costs)
use upgrades_log_add_msg($user_ID,’You paid 3 credits for an additional URl – ‘.$url); to add a message to the users Credits history page so they know they used some.

That’s it, easy peasy! Here’s an idea, use credits to sell digital downloads on another page, just check and deduct the users credits before allowing a dowload.

I’ll post a follow up to this soon on how to use the upgrades plugin to add a new package that enables the RSS widget for a blog (I’ll show you how to disable the rss widget too)

You can get over 100 plugins and themes of premium quality at http://premium.wpmudev.org and they all help to make your wpmu site better than the jones’s :)


Making a takeaway website – my story

Fired Wok Chinese Takeaway

Some of you may know that I run a Chinese takeaway and delivery shop in Lancaster, UK with my partner and her brother. My role is strictly ‘front-of-house’, customer service, chief geekster and go-and-get-stuff-from-Preston’er (among other things like doing the weekly books and tracking the cost of goods sold etc)

I can’t for the life of me go in the kitchen where it’s all fire and wok but, I can do all the other great things like come up with great marketing ideas, develop online solutions for advertising, answer the phone and understand the myriad of different accents you get when you run a delivery orientated business in a two University town.

Pretty Vs Useful

One of the things that was inevitable for me to do was, The Website.

Now, I class myself as a developer not a designer. The difference? (continue reading…)


WP-Twitip-ID Plugin – Add a twitter field to your comment form (easily)

Version 1.0 (updated 11 Feb 09)
Requires: WordPress 2.6 (could work with lesser)
Tested up to : WordPress 2.7b3

This plugin is no longer supported, please download TwitterLink-Comments which will do a much better job and will still be able to use the existing database table and labels.

Download TwitterLink Comments


New url registration page or new plugin settings?

I took a day off this week and it extended itself to another half which then puts me in contemplation mode.

I’m used to this happening after finishing a particularly complex series of things, I kind of get a sugar crash which puts me into day off mode, that then leads to search for new source of sugar.

It happened last week, I managed to work out how to upgrade the WPMU version ComLuv site to 2.8.2 and then expand the single db into 256 smaller ones. This was a big thing for me, it was either get the site working with 256 databases or fork out another bundle of cash every month for an extra gig or two of RAM on the server!

Luckily, after seeing it work fine for about a week with the new db configuration and no scary cpu usage alerts coming, I think I can concentrate on the next stage of development. I’m really itching to get a decent url registration page up and I’m considering opening up the ability to have up to 5 urls or sources registered with your account without needing anything other than a standard commentluv account.

I’ve already started sketching out what I want the page to look like (which I really should have done the first time around!)..
Sketching out new url registration page on Twitpic

Another thing I really want to do is convert commentluv to use a plugin framework so I can really do wonders with the settings page and not worry about htmlspecialchars this and mysqlescape that.
Doing this would allow me to put in some needed features to the commentluv plugin like full editing of the css used.

I’m tempted to update the plugin first, I have just received a Russian translation to go in with it and I want to update the readme so it is formatted to display fully in the plugin browser of a wp blog.

Oh the quandary! I can’t decide which one to do, they both need doing and both need to be done on their own or else distractifications occur!

What’s more important to you?
1. comluv update to make the whole url registration process nicer and add 5 sources to your acocunt
2. fix plugin so you can edit your own styles and have a prettier and easier to understand settings page?


A day of other peoples code

Support Tickets

I did some pretty fancy tweaking of code today to see if I can replace the support tickets system on ComLuv, the system at the moment isn’t bad but the last support ticket management software I used was far superior and allowed me to reply to closed tickets and create canned responses.

It will need some more work to integrate it into the dashboard of the site but I’m pretty confident I can do it.

Theme

I feel the need to tweak themes too, I found an old mockup image on my hard drive that I had for a client that never took up the job and I contacted someone about converting it to a WP theme. I love how it looks and I’d really like to have the format for ComLuv so I can start on tutorials and other features.

That’s not to say the current one isn’t great, it’s just that I’m all for “get it done” then “make it work” and then “make it pretty” and then “do it all again until I have what I want.

Newsletter

I had a bit of a nightmare with my newsletter software taking up too much resources while being on the same server as ComLuv so I took steps to transfer it to another server and use the ComLuv SMTP connection to do all the sending. Hopefully this will fix any issues I was seeing..

Tutorials & Videos

I have the new pc set up with a screen recorder and I have a list of videos that I’d like to produce for tutorials on the ComLuv site. I tested it out and my quad core monster can handle the capture on a widescreen so I can do HD videos and host them on Vimeo

Remote Images & Scripts

I have done some serious optimization on the blogger version of CommentLuv so that now there are very few calls to the ComLuv server for images and scripts. This one thing should dramatically decrease the server load during busy times.

Work

And now I have to tweak the system in the shop.  The tweaking never ends!


Time flies!

I usually spend the first part of Sunday doing the weekly books for the takeaway, it takes up most of the morning to go through each days takings and tot it up in an accounts package and check the figures off the parallel sheet. It’s a good system and helps me to know exactly where any errors have happened.

Today though, I did my usual shower, shave, coco-pops and coffee and started fiddling with some bits of the site, which took me off on many tangents of code and template glory until I had a fully moved fiddyp.co.uk on the ComLuv network and rebranded parts of the whole network to be in line with the CommentLuv feel.

6 hours I was at it! I really must get a bumper sticker ..

“WPMu admins can be at it all night”

:-)

But really, I’m having so.much.fun!

It Grows!

Looks like the network is growing rapidly and the latest version of CommentLuv hasn’t had a support ticket about a bug for the last 12,000 downloads. Can I has stable? :)

So far, the new API has given some luv to more than 50k comments on blogs around the world and has attracted more than 200 new blogs and hundreds more registered users. The new-started-only-last-week database has already recorded approximately 20k unique websites (those that have a feed), processed 4k info page displays and recorded over 9k clicks from users on peoples last blog/tweet/digg links.

happy boy!

It’s just starting..

There’s still a huge amount for me to do with regards to the site like adding advertising options, custom themes, editable css files, affiliate payments for selling adverts, custom text link ads and much much more. Stick around, you might see something you’d like to take advantage of. I have big plans for this network, I hope you can be part of the fun too.

Let me know if you’d like to see anything in particular on the site or in the plugin..



  • 279
    Unique
    Today
    Powered By Google Analytics
  • Copyright © 1996-2010 FiddyP. All rights reserved.
    iDream theme by Templates Next | Powered by WordPress