Signup filters changed

Posted by Andrea under News

I just noticed a small mention from Donncha (and the changeset) about a small wording change in the code for the signup page.

The blog_id form has been changed to blogname. This will eventually affect any plugins you might have that hook into the signup process. Should be a small enough edit to fix though.

Note: this change has not made it into an official release yet. But it’s coming.

No Comments

WPMU 2.6 beta is out now

Posted by Andrea under News

Donncha wrote here about the new MU he just released. You can read all about what he has to say, but the biggest and most noticeable to me was a bump in the version numbers. There’s also a nonce on signup to help defeat splogs and post revisioning. Bunch of goodies rolled in from regular Wordpress.

Go download it from his entry and test it out. :)

2 Comments

How to hook into the footer

Posted by Andrea under Plugins

I think this comes up in the forum at least once a week, so here’s some handy tips & instructions. First though, some explanations of the terminology.

Hook - what a plugin does when we want it to “hook” into, or run with, whatever wordpress is doing.
Action - does what it says, it acts.
Function - in php, a function is a tiny bit of code that does something, especially if it’s something we want to do often. We write a function, then we call it.

Simply put, this is a two-step process. We add a function as an action, then we hook into WPMU . Kinda like catching a lift.

Are you ready to write a plugin? Hang on, because here we go:


<?php

/* We have to start our php with an opening statement.
If we really want to be fancy we can add some things here in the comments to tell everyone what this does. */


/*
Plugin Name: your snazzy new plugin
Description: Adds whatever we want to the footer
Author: your name
Version: 1.0
Author URI: where your plugin can be found, or your website
*/

function your_function_name () { ?>

/* see what we did there? We declared a function then closed our php again. Why? So we can add whatever html goodies we like. */

<p><em>This blog is provided by <a href="<?php get_settings('siteurl'); ?>"><?php get_settings('sitename'); ?></a>.</em></p>

/* Now every blog on our system will get this sentence inserted into the footer of whatever theme they used. And we did not have to edit every single theme. I know you picked something like 250 right? */


<?php }


/* We opened up our php again. we have to tell WPMU something important. */
add_action('wp_footer', your_function_name');


/* Ta da! This is the magic line folks. Let's close up shop now. */
?>

Make sure there’s nothing behind that last >, no whitespace, no line break. .Now, before you go too far, there’s one HUGE CAVEAT for this working. Every theme must have  <?php wp_footer(); ?> somewhere in the footer.php file. Preferably right where you want the contents of your new shiny plugin to show up. Most themes have it, so if you try this and it doesn’t show, check the theme’s footer file first.

I bet you’re already thinking of other things you could put here, like your Google analytics code. ;)

7 Comments

How to Display User’s Blog Posts Feed on your Main Page

Posted by WordPress Modder under Plugins, how to

As a regular WPMU Forum visitor, reader, and contributor ( when I can add value ), I see this question asked often. I have found many threads that offer some great hints and advice, and basically tell you exactly what to do, but all the information wasn’t in one place. So, here it is.

How to Display your WPMU User Blog’s Posts on your Main Page:

1. Download, Read the Directions, and Install the WPMU Sitewide Feed Plugin - ITDamager.

2. Go to Blue-Anvil.com and read this post that details how to fetch RSS feeds with WordPress.

3. Make the necessary changes to the RSS feed path to point to your Sitewide feed ( http://yoursite.com/wpmu-feed/ )

4. Take what you’ve learned and edit the page template in your WPMU installation where you want your Sitewide RSS feed to display.

To help me learn, I try never to copy and paste. Rather, I type out the code by hand and that helps me get familiar with the code. Unfortunately, it also makes me more susceptible to typing errors;)

Here’s an image of the code that worked for me:

Of course, after you get the latest blog posts to display, you’ll want to wrap some style elements around it and maybe make some other changes, but that’s the basic functionality.

I hope this was helpful. I’m sure more experienced WPMU’ers could add more to this, or even provide another method, but this is what worked for me.

8 Comments

Review of unBlog.fr

Posted by Andrea under elsewhere, site of the week

un Blog des blogs by Quentin
Review by Kevin Gormley, MyLocalCause.com

What can I say about unBlog.fr?  C’est magnifique!

With a clean, pleasing front page with bright colors and well designed sections, you don’t need to know much French to navigate and appreciate this great WPMU site.

Apparently, a lot of French speakers like this blog too as there are over 200,000 blogs and 1,000,000 posts.

A pleasing homepage features a tag cloud, a few featured blog icons, and a neat array of design elements. The most popular blog categories are general, family, personal journal, photo, music arts, sports and travel with more than 2000 blogs in each category.

Two big reasons for its popularity are: C’est facile et gratuit! [It's easy and free.]

It is funny that some aspects of blogging are universal:
Any guesses for “adrese email” and “nom de blog”?

On each blog page, the subtle footer lets users create a blog or navigate to the unBlog front page.

Another nice touch is the consistent use of the unblog.fr logo such as in the WP login page.unBlog.fr logo instead of WP logo on login page.

unBlog.fr has required several changes and performance enhancements to accommodate its large scale.
http://quentin.unblog.fr/wordpress-mu-wpmu/
Those interested in a more technical discussion can read about several types of caching:
Caching in WPMU, database query cache, PHP Op-code cache, Wordpress object cache, WP-Cache and reverse proxy caching.
So overall, a great WPMU site and some technical details on caching if you are looking to improve performance.

****

Merci beacoup to Kevin for the review. :)

2 Comments

Oooo, a spam reporter plugin

Posted by Andrea under Plugins

This looks awesome: WPMU Spam reporter. It puts a “Report Spam” button on every blog and send the site admin an email with the details.

Hmm, although maybe it could be called “report splog” but some people aren’t aware that splog means spam blog. Would be easy enough to edit if you’re that picky.

Thanks Rune. :)

EDIT: There are now variables in there to easily change text in certain areas. (I’m still giggling.)

9 Comments

Forcing MU to use www

Posted by Andrea under Hacks

By default, Mu strips out the www on domain names. I’m not going to get into the debate of for or against, because at some point you just may be forced to use it for reasons beyond your immediate control. Whether you like it or not. :D

In case you somehow missed catching the the change in the address bar, symptoms may include a redirect error when trying to view the main page, even if it installed fine, and a constant page refresh when trying to login. So watch the address bar and see if it’s adding the www.

After a few eye-bleeding hours searching the forums and the forum tags, I finally found it here. (Did you know there’s actually two ways to search? I should probably write a post on that…)

The thread is a year old and the line numbers are slightly off, but most of it still applies. The rewrite rule to strip www is no longer in the htaccess file so don’t bang your head looking for it. :D

In my case, I did not want to reinstall again because of the setup it was more work. Here’s what I did:

- go into phpmyadmin and search for all instances of your domain name. Edit them to add the www to the domain name.

- Find wpmu-setting.php in your root folder. Comment out lines 10 and 11 like this:

// if( substr( $domain, 0, 4 ) == 'www.' )
//    $domain = substr( $domain, 4 );

Those double-slashes in front of the lines keep that code from being run.

Go test your install, it should be okay. I should also mention that I only tested this on a subfolder install. I have no idea what it does on subdomains.

5 Comments

Some goodies coming

Posted by Andrea under News

I had a chance to update my local install to the latest out of trac (svn up FTW) and I poked around to look at the upcoming goodies.

Google Gears - didn’t try it out (does it work with Linux?), but the concept of storing common admin-area files in one place? Rocks.

Theme page pagination - so, so very sweet. There’s even a preview, which was kinda of slow on my end, but has more to do with me (I hope) than the code. The only downside was it appeared to mess up the alphabetization of the themes list, and only 15 themes on a page was possible too little. My local install, where I check out any theme I might like, has a total of 23 themes pages. I did notice themes were starting to be tagged, so if this means there’s a possiblity to sort themes by that, then again I think that’s awesome.

Powered by ScribeFire.

4 Comments

Adsense Revenue Sharing plugin for WPMU

Posted by kbane under Plugins

Are you looking for a great adsense revenue sharing plugin for WPMU?  So was I, it seems there aren’t many of them on the market right now.

However I did find one plugin that should meet most if not all of your needs.  It’s called the Author Adsense Plugin and it was created by Harley Quine.

Here’s a list of features:

“Admin has complete control over…

  • The percentage of author’s ads to admin ad’s.
  • Whether to randomise author ads on the front pages of blogs.
  • The page that authors see before entering their publisher id. Admin can modify the title and all content (could be useful for putting advertising rules etc.)
  • The positioning and content of ads.

Included is a widgets script that will allow admin/authors to put up to three widgets on their blog. Admin has control over what these widgets will look like, author can specify where the widgets go. “

This plugin did everything I needed and I highly recommend it if you are looking to move into adsense revenue sharing with your blog network.  The cost is only 10 Euro which today is about 15 USDollars .. I paid via paypal and they did the currency exchange for me with no problems.

Click here to visit Harley Quine’s site and purchase the Author Adsense Plugin for WPMU.

Do you use a different adsense revenue sharing plugin for WPMU?  If so please post it here, I’d love to check it out!

Kevin
www.KevinBane.com

Update 06/12/08:  If you would like to code your own Adsense Revenue Sharing solution, here is a link to the WPMU forums that should answer most of your questions.

4 Comments

Are you experienced in MU?

Posted by Andrea under News

There’s a job posting here, for work that needs to be done ASAP.

And by experienced, they mean you’ve set up more than your own install. :)

Powered by ScribeFire.

No Comments

google.load("language", "1"); var curstate = 0; var hasloaded = 0; function bnc_show_translated() { if (hasloaded == 0) { bnc_lang_callback(); hasloaded = 1; } for (i = 0; i < 0; i++) { var elem = $("bnc_original_" + i); if (elem) { if (curstate) { elem.show(); } else { elem.hide(); } } } for (i = 0; i < 0; i++) { var elem = $("bnc_trans_" + i); if (elem) { if (curstate) { elem.hide(); } else { elem.show(); } } } if (curstate) { $("bnc_trans_state1").show(); $("bnc_trans_state2").hide(); curstate = 0; } else { $("bnc_trans_state1").hide(); $("bnc_trans_state2").show(); curstate = 1; } } function bnc_detect_div(div_id) { var text = document.getElementById(div_id); if (text) { text = text.innerHTML; if (text.length > 0) { google.language.detect(text, function(result) { if (!result.error) { if (result.language != "en") { if (result.confidence > 0.25) { $("bnc_translating").show(); bnc_xlate_div(result.language, div_id, "en"); } } } } ); } } } function bnc_xlate_div(src_lang,div_id,o_lang) { var text = document.getElementById(div_id); if (text) { text = text.innerHTML; google.language.translate(text, src_lang, o_lang, function(result) { var translated = document.getElementById(div_id); if (result.translation) { translated.innerHTML = result.translation; } }); } } function bnc_lang_callback() { } function bnc_startup() { bnc_xlate_div("en", "bnc_translate_info", "en"); bnc_xlate_div("en", "bnc_translate_info2", "en"); } google.setOnLoadCallback(bnc_startup);
Close
E-mail It
This blog has been fine-tuned with 13 WordPress Tweaks.