El Dorado

A full-stack community web application written in Ruby/Rails
Mass Edit Pages Plugin « Wordpress « almost effortless
 
Tue, 25 Jul 2006, 8:56pm #1
Trevor
Administrator
Wait-ill-fix-it
Registered: Sep, 2005
Last visit: 3 hours ago
Posts: 226

This Wordpress plugin will come in handy for those using their Wordpress install less as a Blog, and more as a CMS (Content Management System). The Mass Edit Pages plugin allows you to edit the Page Parent (post_parent) and Menu Order (menu_order) of many pages, on a single page.

Thus, instead of clicking through each page (page after page after page) to change their order or parentage, you can get at all of the pages from one simple interface.


http://www.almosteffortless.com/wordpress/mass-...

Offline
Wed, 26 Jul 2006, 3:35am #2
Jan
New member
Registered: Jul, 2006
Last visit: Sun, 17 Sep 2006
Posts: 1

Wow. This is a really nice plugin. I have just changed a few things so that it will show up in the language chosen for your WordPress blog. Where do I submit my changes?

Offline
Wed, 26 Jul 2006, 7:53am #3
Trevor
Administrator
Wait-ill-fix-it
Registered: Sep, 2005
Last visit: 3 hours ago
Posts: 226

Thanks, Jan. You can just post them up here, or you can email me if you like.

My email is: info@almosteffortless.com

Offline
Thu, 10 Aug 2006, 12:19pm #4
arbol
New member
Registered: Aug, 2006
Last visit: Thu, 10 Aug 2006
Posts: 1

nice plugin!

Offline
Wed, 16 Aug 2006, 2:21am #5
pandem
New member
Registered: Aug, 2006
Last visit: Wed, 16 Aug 2006
Posts: 1

Thanks a lot! I've been a long time waiting for something like this.

Offline
Mon, 28 Aug 2006, 7:33am #6
garubi
New member
Registered: Aug, 2006
Last visit: Tue, 29 Aug 2006
Posts: 1

Jan wrote:

Wow. This is a really nice plugin. I have just changed a few things so that it will show up in the language chosen for your WordPress blog. Where do I submit my changes?

Can you let your modification public? I'm installing this great plugin on an italian installation and want to use the Italian localization...

TIA

Stefano

Offline
Mon, 28 Aug 2006, 11:23am #7
Trevor
Administrator
Wait-ill-fix-it
Registered: Sep, 2005
Last visit: 3 hours ago
Posts: 226

You can also use the "German" version, which has been fixed up by Jan to work with localization correctly. You don't have to use the German language files. I'll update the plugin soon so that it will work with localization. If you translate the plugin on your own, please let me know and I'll post it.

http://www.almosteffortless.com/wordpress/mass-...

Offline
Sun, 03 Dec 2006, 1:04am #8
Luhmann
New member
Registered: Dec, 2006
Last visit: Tue, 05 Dec 2006
Posts: 2

I know WordPress 2.1 is just in alpha right now, but there are several features I need in 2.1 to run a static website I'm using. Unfortunately, this excellent plugin breaks in WP 2.1 alpha. It loads, but none of the pages are listed. I don't know if it is too early to request that the plugin be fixed, since I suppose 2.1 could continue to change - but I thought I'd ask anyway.

Offline
Tue, 05 Dec 2006, 10:38am #9
Trevor
Administrator
Wait-ill-fix-it
Registered: Sep, 2005
Last visit: 3 hours ago
Posts: 226

I think I'd need a new version to get the plugin working in 2.1 - the problem is likely that Wordpress is going to use a new, separate table for pages instead of combining them with the posts table (from what I gather). I'll put it on my to-do list to make the plugin work for 2.1 (it'll basically be a whole new plugin), but there are a couple things ahead of it in line right now.

Offline
Tue, 05 Dec 2006, 12:05pm #10
Luhmann
New member
Registered: Dec, 2006
Last visit: Tue, 05 Dec 2006
Posts: 2

Thanks for the explanation. I look forward to the new plugin when its ready! 2.1 offers some great features for static web sites - like the ability to specify a home page other than your blog.

Offline
Tue, 05 Dec 2006, 2:29pm #11
Trevor
Administrator
Wait-ill-fix-it
Registered: Sep, 2005
Last visit: 3 hours ago
Posts: 226

There's no doubt I'll get all of my plugins working on 2.1 - it's just a matter of time. I'll update this thread and my blog when I've got something ready.

Offline
Wed, 07 Feb 2007, 7:18pm #12
pufaxx
New member
Registered: Feb, 2007
Last visit: Mon, 12 Mar 2007
Posts: 4

Hi there, I also love this plugin - functions like these should become standard for the next versions of WordPress

:-)

A few days ago I made an upgrade to WP 2.1, so I changed some lines of code to get Mass Edit Pages working on my blog. There were two things that needed to be changed.

1)

WP 2.1 decides whether a post is taken as a page or a post by "post_type" and not by "post_status" any more. So have a look at line 70:

$pages = $wpdb->get_results("SELECT * FROM $wpdb->posts WHERE post_status = 'static' ORDER BY menu_order");

This must be changed into:

$pages = $wpdb->get_results("SELECT * FROM $wpdb->posts WHERE post_type = 'page' ORDER BY menu_order");

... and you're nearly done.

2)

If caching is active, you can change your page order, the Mass Edit Pages menu will display your changes - but you won't see any effect on your blog. (I haven't tested yet, but I'm afraid, it might be the same with earlier versions of WordPress, too)

Anyway - WordPress must be told, that the cache for pages has to be cleared, when changes in page order are applied. The lines 42-48:

while ($i < $ii) :

$ID = $_POST[ID][$i];
$post_parent = $_POST[post_parent][$i];
$menu_order = $_POST[menu_order][$i];
$wpdb->query("UPDATE $wpdb->posts SET post_parent='$post_parent', menu_order='$menu_order' WHERE ID=$ID");
$i++;
endwhile;

must be changed into

while ($i < $ii) :

$ID = $_POST[ID][$i];
$post_parent = $_POST[post_parent][$i];
$menu_order = $_POST[menu_order][$i];
$wpdb->query("UPDATE $wpdb->posts SET post_parent='$post_parent', menu_order='$menu_order' WHERE ID=$ID");
clean_page_cache($ID); // else you won't see any effect, if caching is active!
$i++;
endwhile;

... and it should be working.

Please excuse my bad English, if you're German spoken, you might better understand my explanation written here

Greetz,

Gunnar

Offline
Fri, 09 Feb 2007, 6:26am #13
pufaxx
New member
Registered: Feb, 2007
Last visit: Mon, 12 Mar 2007
Posts: 4

I'm sorry - the plugin still does not work if you're doing changes in the post_parent-field.

The pages appear in the correct new order in every admin menu and via wp_list_pages - but they can't be reached. 404-Error. So WP2.1 seems to update edited pages somewhat other ...

:-(

I hope that I did not caus any trouble to anyone who had tried my version.

Offline
Mon, 12 Feb 2007, 5:21pm #14
Trevor
Administrator
Wait-ill-fix-it
Registered: Sep, 2005
Last visit: 3 hours ago
Posts: 226

Gunnar Tillmann also seems to have done some work on this front as well. I'm sorry for not updating the plugin already, but it's been difficult for me to get at a computer since I'm traveling right now. Plus, I haven't upgraded to 2.1 yet :) It looks like it isn't too hard, though, to get things working in 2.1 - thanks to everyone who's sent me tips so far.

http://www.gunnart.de/tipps-und-tricks/mass-edi...

Offline
Wed, 14 Feb 2007, 10:42am #15
pufaxx
New member
Registered: Feb, 2007
Last visit: Mon, 12 Mar 2007
Posts: 4

Now it works! Just some letters of code were missing.

Apply the changes written in my posting before, and add

wp_update_post($ID);

after
clean_page_cache($ID);

Read my blog-posting here

Offline
Wed, 14 Feb 2007, 2:14pm #16
macanuted
New member
Registered: Feb, 2007
Last visit: Thu, 15 Feb 2007
Posts: 1

Thanks Trevor for this great plugin, and thanks pufaxx for the help...

I have one question:

The "mass edit pages" tab shows only if I'm ADMIN user, how can I do to make it visible also for EDITOR users?

greetings from Argentina

Offline
Wed, 14 Feb 2007, 3:06pm #17
pufaxx
New member
Registered: Feb, 2007
Last visit: Mon, 12 Mar 2007
Posts: 4

I'd guess it could be a little complicated to make it work for admins with lower admin-rights ... the plugin must decide page-by-page whether the current user has the right to edit the listed page or not ...

I'm afraid this is something for a long night and lots of coffee.

:-)

Offline
Thu, 07 Feb 2008, 3:34pm #18
sccr410
New member
Registered: Feb, 2008
Last visit: Thu, 07 Feb 2008
Posts: 1

This plugin shows nothing for WP 2.3.3. I installed, clicked on "Manage" > "Mass Page Edit" but none of my pages show up.

Offline
Fri, 08 Feb 2008, 1:02am #19
Trevor
Administrator
Wait-ill-fix-it
Registered: Sep, 2005
Last visit: 3 hours ago
Posts: 226

I haven't tested it with 2.x at all - I think they made some changes to the WP architecture that are incompatible. Sorry, but I don't use this plugin on 2.x, so I'm not updating it :(

Offline
Tue, 03 Jun 2008, 4:15am #20
explorish
New member
Registered: Jun, 2008
Last visit: Tue, 03 Jun 2008
Posts: 1

hi,
is there an update for this in wp2.5? also, one for mass edit posts would be fantastic... any idea where i can find it? thanks a lot!

Offline
Tue, 03 Jun 2008, 8:26am #21
Trevor
Administrator
Wait-ill-fix-it
Registered: Sep, 2005
Last visit: 3 hours ago
Posts: 226

I think the one for 2.3 still works for 2.5: http://wordpress.org/extend/plugins/mass-edit-p...

Offline