[Wordpress] Pressmark: Bookmarks with Wordpress CMS

Pressmark with a Wordpress installation with all you need to start a social bookmarking website (like del.icio.us, sabros.us, …).


You can see a demo of Pressmark installation on bookmark.alexgirard.com

Pressmark includes Wordpress Prologue theme, which has been used by Wordpress team to have a twitter-like dev-blog.

Prologue include Gravatar support, so go to upload your avatar on gravatar.com to have a nicer output!

If you feel like adding your own modification to the code, you can clone/fork the project on Github: http://github.com/alx/pressmark/. All contributions will be welcomed!

Ideas to extend Pressmark:

  • Bookmarlet, Jabber bot for easy posting;
  • Import from bigger social-bookmark accounts (delicious, magnolia, …)
  • Cross-blogging to decentralized bookmark management in various blog spaces

Installation

  • Get Pressmark sources:
    • Download it from Github
    • If you’ve got git installed, clone it from Github (to easily get last updated)

      git clone git://github.com/alx/pressmark.git pressmark
  • Move the source to your webserver, ask a geek how to do it if you don’t know :)
  • Wordpress configuration: copy ‘wp-config-sample.php‘ to ‘wp-config.php‘ and fill up the MySQL database information.
  • Access to the website where you’ve installed Pressmark, and begin the “2 min. installation” from Wordpress
  • Now that your website is ready, go in the administration pages and activate the following options:
    • In ‘Design‘: select ‘Prologue‘ theme;
    • In ‘Setting‘: select ‘Anyone can register‘ and set the ‘New User Default Role‘ to ‘Author‘ if you want your users to post links;
    • In ‘Plugins‘: activate ‘WP-OpenID‘ plugin

Tags: , , , , ,

Hi

I am already using wordpress and prologue. What do I need to download to add Pressmark capabilities without doing a clean wordpress install?

Great idea!

Alexandre Girard

Alexandre Girard’s avatar

I’d recommend you just download the customized prologue theme from pressmark in your case, there’s no important logic outside of it (index.pp and function.php)

God luck :)

@alexandre: and what about post-form.php? Also, how difficult would it be to include choice of ‘categories’ in the post-form? I’ve asked this at wordpress.org with no response.

Cheers

@alexandre: follow-up…I uploaded index.php and functions.php and it throws me a syntax error on line 41. I see the use of ‘pressmark-url’ throughout index.php. Could this be an issue?

Thx

Alexandre Girard

Alexandre Girard’s avatar

Hi Scott,

yes, there was a typo on line 41, a missing ‘;’, add it or sync with the last git commit.

post-form is the form use to send the bookmark info to index.php, it would be fairly simple to add a category dropdown in it, but we prefer to use lazy tags.

@alexandre: would you be willing to point out how I might substitute “tags” or “title” with “category”? I suspect some changes in functions.php and the index page obviously.

Thx

Hi:
Please help me.
I download your scripts from http://github.com/alx/pressmark/tarball/master
and install the scripts, but it does not work.
Could you help me??
my site http://www.casinostags.com/

Alexandre Girard:
Which version of wordpress do you used for your Pressmark?
I have some problems using version 2.6.

Alexandre Girard

Alexandre Girard’s avatar

Hi cpayment,

Pressmark has recently been upgraded to wp 2.6 - source on http://github.com/alx/pressmark/tree/master - but not tested.

Could you send me a list of your problem so I could have a look?

Thanks,

Alex

Hi Alex,

Yesterday I’ve installed Preessmark on my blog here http://www.bookmarkr.ru

I did everything you say in the instructions: http://blog.alexgirard.com/wordpress-pressmark-bookmarks-with-wordpress-cms/ but after installation it’s not working properly. When you press on the username or the comments (0), it sends me to the 404 page: http://www.eskhosting.com/notfound.page/

Can you please tell me what I possible did wrong? And what I should do to fix it?

Ruslan

Hi Ruslan,

Thanks for the feedback.

You’re the second one today telling me about this error, I’ll investigate it tomorrow and send you some way to resolve it as soon as possible.

Speak to you soon,

Alex

Hi Alx,

I installed the latest 2.6.2 package. Somehow everytime I try to add a link it’s redirecting me to login even when I am logged in. Any idea what i might be doing that is not right.

thanks,

dd

Hi all,

I’ve just pushed on github a new version of Pressmark that should resolve this login issue.

https://github.com/alx/pressmark/tree

Take care, the theme name has changed to Pressmark, it may gives you problem if you use the same database as a previous install.

Cheers,

Alex

Thanks Alex.

Now I can’t locate the option for the gravatar.

The gravatar support might be broken.

Thanks dd, I’m going to review it.

DonĀ“t hesitate to fork the project on github.com and send me your patches when you’ve got some, I’l be glad to add them on my branch ;)

hi :-)
anyone knows how to add categories to the post form in the theme?

Hi Alex,

I changed line 418 of wp-login.php from:

$redirect_to = admin_url();

to

$redirect_to = front_page();

Cheers,

Hi dd,

I’ll be gld to add the change in main branc, but what’s the reason?

I avoid changing the wordpress core files unless necessary, it greatly help when it’s time to upgrade wordpress version :)

Hi Alex,

Hold on a sec on adding that. I have to fix the log out too.

Well, from the users perspective, when they log in to tag, if they are directed to the profile page it causes confusion. The need to go to the front page.

One solution is to have a widget like mini meta handle the redirects after log in. That is one way around not changing the core.

———–
Prologue might need a modification too. It might be better to show the tagging interface even when the user is not logged in. It will encourage more people to tag. One can sign them in when they click post.

I will keep playing with it and update you.

Thanks dd for the update ;)

Alex,

You may want to include this plugin for people who want to redirect users to their homepage after login. It also takes care of the logout re-direct. Works with Wordpress 2.6.2. Don’t know about other versions.

Sweet solution. No core file edits. Takes care of the redirects without any settings.

Plugin Name: From Where You Came
Version: 1.0.0
Description: Makes the “Login” and “Logout” links take you back from where you came.
Author: Viper007Bond
Author URI: http://www.viper007bond.com/

add_filter( ‘loginout’, ‘fromwhereyoucame’ );

function fromwhereyoucame( $link ) {
$currenturl = ‘http://’ . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];

if ( !is_user_logged_in() )
$link = str_replace( ‘”>’, ‘?redirect_to=’ . urlencode( $currenturl ) . ‘”>’, $link );
else
$link = str_replace( ‘”>’, ‘&redirect_to=’ . urlencode( $currenturl ) . ‘”>’, $link );

return $link;
}

?>

http://files.viper007bond.com/wordpress/fromwhereyoucame.zip