Just wondering where this is going?
What are the first steps?

CommentFileSizeAuthor
#33 og_meta_tags.tar_.gz7.23 KBtoomanypets
#17 open_graph.zip4.96 KBegomac
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

chawl’s picture

subs

elliotttf’s picture

I'd also like to know. I need to implement this feature for a few sites I'm working on and would rather no redo someone else's work. If you need help working on this I'd be more than happy to lend a hand.

Carlos Miranda Levy’s picture

I'm willing to help, too.

scor’s picture

Carlos Miranda Levy’s picture

Took a look there.
I see you started work on D7 module.
I'll try to port to D6 or collaborate on both.

egomac’s picture

Any updates on this?

John Tolhurst’s picture

Interested, this is an important module for injecting some content into social networking activities, in addition to "Hey everybody, I'm eating jam toast".

John Tolhurst’s picture

Anybody interested in joining with me to place a bounty on this module?

John Tolhurst’s picture

What is this about?

So much of social networking is junk information, 'jam toast' level communication.

What opengraph offers is a method for turning a webpage into a smallish icon, so it can be shared around neatly. Kind of like exchanging football cards among friends.

This is really a cool tool for websites that have cool unique content. I think its an excellent mode for igniting viral marketing patterns.

There is a lot of goodwill out there, people who are happy and interested to share what they think is useful new stuff. If we can facilitate this happening on drupal sites, it will be a Good Thing.

8bitwright’s picture

This module would be very useful to me.

How can I help?

Carlos Miranda Levy’s picture

I'm willing to participate in bounty and even do some coding.

not_Dries_Buytaert’s picture

Subscribing. General descriptions of the 'Open Graph protocol' which could be added to the project's webpage:
Quote from http://opengraphprotocol.org/

The Open Graph protocol enables any web page to become a rich object in a social graph. For instance, this is used on Facebook to enable any web page to have the same functionality as a Facebook Page.

Quote from http://developers.facebook.com/docs/opengraph

The Open Graph protocol enables you to integrate your Web pages into the social graph. It is currently designed for Web pages representing profiles of real-world things — things like movies, sports teams, celebrities, and restaurants. Once your pages become objects in the graph, users can establish connections to your pages as they do with Facebook Pages. Based on the structured data you provide via the Open Graph protocol, your pages show up richly across Facebook: in user profiles, within search results and in News Feed.

not_Dries_Buytaert’s picture

The module should at least add following attributes to the html-tag of each webpage: xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"
However, in D6.17 the html-tag is generated by the theme specific 'page.tpl.php' file. The php code which does this for the Garland theme is on line 5:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php print $language->language ?>" lang="<?php print $language->language ?>" dir="<?php print $language->dir ?>">

The meta-tags (within the head-tag) could be added with modules like: http://drupal.org/node/532278

etaroza’s picture

So let's get started with it!

not_Dries_Buytaert’s picture

Title: What is the plan for this module? » Release (plan) for this module, requires change of Drupal 6.x core
Status: Active » Postponed

As I explained in my previous post #13, it is impossible to implement this module (i.e. without changing themes individually).
The 'page.tpl.php' file is missing a $html variable: http://api.drupal.org/api/drupal/modules--system--page.tpl.php
Personally, I can't believe this (such flexibility) hasn't been a design principle for Drupal from the beginning, anyway.
I have just submitted a feature request for the theming system of Drupal 6.x to solve this: http://drupal.org/node/843528
AFAIK, development of this 'Open graph' module can continue, after that request has been implemented.
Perhaps a Facebook-developer is willing to make Drupal compatible with Facebook.
So, I posted this topic: http://forum.developers.facebook.com/viewtopic.php?pid=242635#p242635

etaroza’s picture

Yeah, when I looked at scor's module for D7: http://github.com/scor/opengraphprotocol/blob/master/opengraphprotocol.m... it seems so straightforward to use drupal_add_html_head().

I think that even though you have to mess with the theme a bit, it doesn't really mean that the module cannot be implemented. It's just a matter of documenting properly how to use it, and what to tweak in the theme.

egomac’s picture

FileSize
4.96 KB

This is a quick and dirty port to 6. And here are some things to take note:

1. Removed facebook like or any facebook-related code. As we are building a core open_graph, can we say that we build first on the core open_graph and do the facebook as a submodule of this project? It would be more organize and easier to maintain in the future
2. There are 2 places to set your configuration. The global setting is found in the default settings path and the other one is content type specific. When the setting in the content type is not defined, it falls back to the default settings.

I repeat, this is a quick and dirty port so please bear if I missed out anything.

not_Dries_Buytaert’s picture

Title: Release (plan) for this module, requires change of Drupal 6.x core » Release (plan) for this module
Status: Postponed » Needs review

Too be bad: looks like the feature requested for D6 won't be implemented: http://drupal.org/node/843528#comment-3158938

egomac’s picture

Quick one: Build the module and add an instruction on the README on how to manually add the definition in the template. I believe there are even more areas in this module's development that needs attention rather than worrying about this one.

stevesmename’s picture

Issue tags: +Facebook Like

egomac,

Thank you for adding your open_graph module as an attachment. It worked well with my Facebook Like module that isn't "official" either. http://drupal.org/node/804112#comment-3123900

egomac’s picture

I tried contacting the main developer but I still haven't got any response. I applied for a CVS access but was denied. It would be great if we can commit this just to get things going.

jghyde’s picture

I'd like to join the effort here Should this project be a sub_module of nodewords?

joe

Fr0s7’s picture

I agree with taroza and egomac... This can still be developed and released with proper documentation on how to implement it.

Thanks to egomac for the attachment and stevesmename and not_Dries_Buytaert for their contributions to this discussion. Nice work so far!

Somebody really needs to get a hold of victorcoder (this module's maintainer) so we can get rolling on this. Either that, or we need somebody with CVS access to start a new project and check in what we have so far.

Subscribing.

victorcoder’s picture

Hi all, sorry for the delay. A preview release for this module must be released by the end of this month.

j0k3z’s picture

Im trying out egomac Drupal 6 port - There seems to be no way to NOT choose a type. For my site I only want one node type to be associated with facebook but the code seems to be added to all of my pages. The settings under the admin/content let me change which type but not remove that type

Also, when disabling the module the code still appears in the meta tags. I cant tell if this is a caching issue on my end or if I need to otherwise remove something in the database to remove it completely?

egomac’s picture

@j0k3z you might want to wait for victorcoder's official release. Like I said it was a quick and dirty port just to get things started with this module.

socki’s picture

That's great news. I'd love to see what you have done with it so far.

I have a project that i'm working on which I need this functionality, it would be great if i could spend time working you to get this over the finish line rather then having to work on something else in parallel. Hope that you can get something uploaded sooner then later... I'd be happy to help work out the kinks.

j0k3z’s picture

It's definitely a good start - thanks for sharing.

mottolini’s picture

Wondering if there is any "real" work going on this...
It's now end of september and we don't have anythimg released yet.
@victorcoder Please, we are all willing to help you, let us know how can we do it.
We don't want to wait forever and at the same time we don't want to waste our time developing something that is maybe already been developed by someone else...

Amarjit’s picture

I am also willing to work on this. I have already created a custom module for pulling in data from Facebook using OpenGraph.

Facebook seems to be scrapping Facebook connect for Open Graph. The sooner we get this out, the sooner developers can benefit from this.

Let's get this done.

John Tolhurst’s picture

I can help by offering USD100 for the solution, any others want to chip in?

victorcoder’s picture

Assigned: Unassigned » victorcoder
Priority: Normal » Major

No time no fun. Sorry guys but I don't have time to build up this module. I just commited the base code given by egomac just to have something in the repo.

Several people contacted me with some suggestions of already developed modules that offers this functionality and that are developed to different grades of completness.

Anyone with real interest of becoming the project owner just send your code with an explanation of what features it have to this thread, and the community would review it and vote to decide which one will be the one that will take this place.

toomanypets’s picture

FileSize
7.23 KB

Here's a custom module we wrote for this purpose. Take the best, leave the rest...

INTRODUCTION
------------

This module places Open Graph protocol <meta> tags on selected node
types.

The title, description and url tags are dynamically generated based on
the current node's title, teaser and url respectively. Defaults for all
other values are statically defined on the module's administrative page.
You may override some of the statically defined values per content type
by editing the content type.

If you have installed and configured the Facebook social plugins
integration module, the Facebook Application ID for this module will
default to the Facebook Application ID as defined on the Facebook social
plugins integration administrative settings page.

INSTALLATION
------------

Add the following html tag attributes in the top of your page.tpl.php
file (and any page.tpl.php derivatives) located in your theme directory:

xmlns:og="http://opengraphprotocol.org/schema/"
xmlns:fb="http://www.facebook.com/2008/fbml"

For example:

<html xmlns:og="http://opengraphprotocol.org/schema/"
  xmlns:fb="http://www.facebook.com/2008/fbml"
  xmlns="http://www.w3.org/1999/xhtml"
  lang="<?php print $language->language; ?>" xml:lang="<?php print $language->language; ?>">

If you are not planning to embed any of Facebook's social plugins in
your site, then you may exclude
xmlns:fb="http://www.facebook.com/2008/fbml" from your html tag
attributes.
hiddentao’s picture

Hey guys, I too had to implement the OG meta tags this for my current project too and got quite far into it before I came across this module and this page. Anyway, I decided to package up what I had and create a project page for it:

http://drupal.org/project/opengraph_meta

Ideally the Open Graph module (i.e. this one) should be the base module (similar to what modules/fb does for Facebook) and the meta tags module should be a sub-module inside it.

Dave Reid’s picture

Um, there's not much to open graph besides the meta tags, so I don't see why it had to be made into a separate project??

Annie Rothenberg’s picture

Hi folks,

I'm not a coder or programmer at all but I was looking for a module for this and was pleased to see that work is underway! I've downloaded and tried out both the og_meta_tags module by toomanypets and the opengraph_meta module by hiddentao. I found certain aspects of each one useful and thought you might like a bit of feedback:

og_meta_tags advantages:

  • change og:type by content type
  • set a variety of default meta tags for all content types using the module

og_meta_tags disadvantages:

opengraph_meta advantages:

  • set tags on individual nodes

opengraph_meta disadvantages:

  • no default values
  • limited og tags available (title, description, image)

Right now it's most important for me to have accurate image and description tags so I'm using opengraph_meta. I figured out how to set the og:url tag in my page.tpl.php file like this: "http://mysite/<?php print $_GET['q']; ?>"

Things I'd like to see this module do in the future:

  • default tags for all enabled content types
  • ability to override the og:type for different content types
  • ability to set different default tags for specific content types

Would it be possible to use tokens with these too? Like I said, I'm not a coder and really don't get how all of the php magic comes together. Still, it would be cool if I could set the default description tag for a content type with tokens from that content type's fields.

Well, just thought I would put all this out there. I hope it is helpful in some way and thanks so much for the work so far!

hiddentao’s picture

@Annie Rothenberg opengraph_meta does generate default values - it just doesn't populate the edit fields (but that behaviour can be changed if it would be less confusing). I hope to add more tags to it over the next month or so as the requirements come up in my project.

@Dave Reid agree that this shouldn't really be a separate project. But I wanted to have a module which was easily update-able from drupal.org.

g.k’s picture

subscribe

hiddentao’s picture

opengraph_meta now supports setting og:site_name and og:type (with default fallbacks for each content type). And the download links are working again :)

Annie Rothenberg’s picture

Fantastic! Thanks so much.

naeluh’s picture

subscribe

victorcoder’s picture

Status: Needs review » Closed (won't fix)