DropletsExtension

Ralf Hertsch

#9
Moin miteinander,

I've just released DropletsExtension 0.14.

DropletsExtension now supports Facebook Open Graph Meta tags. You can know set facebook=true with the print_page_head() function within the template of your website:


<?php
  
if (file_exists(WB_PATH.'/modules/droplets_extension/interface.php')) { 
    require_once(
WB_PATH.'/modules/droplets_extension/interface.php');
    
print_page_head(true);
  }
  else { 
?>

   <meta name="description" content="<?php page_description(); ?>" />
   <meta name="keywords" content="<?php page_keywords(); ?>" />
   <title><?php page_title('''[WEBSITE_TITLE]'); ?></title>
 <?php }
?>



With print_page_head(true) DropletsExtension will write 5 additional meta tags:


<meta property="og:image" content="http://phpmanufaktur.de/media/content/addons/droplets_extension/droplet-extension-300x400.png" />
<meta property="og:type" content="article" />
<meta property="og:title" content="DropletsExtension - der Nachbrenner für ihre Code-Schnipsel" />
<meta property="og:description" content="Droplets sind eine geniale und einfache Möglichkeit Programmcode genau dort auszuführen, wo er gerade benötigt wird. DropletsExtension stattet Droplets mit den Fähigkeiten vollwertiger Addons aus und macht sie noch leistungsfähiger." />
<meta property="og:url" content="http://phpmanufaktur.de/cms/topics/dropletsextension-der-nachbrenner-fuer-ihre-code-schnipsel.php" />


For the tag og:image DropletExtension will use the first image of the content (WYSIWYG section or TOPICS article). This grant, that facebook will use this image and don't select any image from your site.

The other tags will be set similiar to the general informations of the page.

Mor informations, download: DropletsExtension

Regards
Ralf

Ralf Hertsch


Please let us discuss this in the german thread and not in two threads in two languages at the same time.

Regards
Ralf

BlackBird

Hm, as far as I remember, I managed to include Droplets in Search. :roll:
[url=http://wbaddons.webbird.de]http://wbaddons.webbird.de[/url] [url=http://www.WebsiteBaker.org/forum/index.php/topic,27476.msg189845.html#msg189845]Don't miss this[/url]

Ralf Hertsch

Quote from: BlackBird on June 05, 2011, 05:57:41 PM
Why did you create a new module instead of extending the Droplets module? (Like I did...)

I've explained this question in the german thread too.

In this case it's not possible to extend the Droplets module, because Droplets is an admin-tool.

To integrate droplets into the WebsiteBaker search, it is necessary to to have a page modul. The reason is: WebsiteBaker checks only active page modules for the file search.php which can deliver results to the WebsiteBaker search function.

For this reason DropletsExtension is a page module and works as interface for all droplets.

Regards
Ralf


BlackBird

Why did you create a new module instead of extending the Droplets module? (Like I did...)
[url=http://wbaddons.webbird.de]http://wbaddons.webbird.de[/url] [url=http://www.WebsiteBaker.org/forum/index.php/topic,27476.msg189845.html#msg189845]Don't miss this[/url]

Ralf Hertsch

Hello John,

Quote from: pcwacht on May 24, 2011, 02:04:49 PM
DropletsExtension can load css :

if (function_exists('is_registered_droplet_css') && !is_registered_droplet_css('droplet_name'))) {   
  register_droplet_css('droplet_name', PAGE_ID, 'module_directory', 'frontend.css'); 
}

Maybe enhance this to include javascript as well?

this is really no problem, I will add an register function for JavaScript!

Regards
Ralf

pcwacht

Did have a quick look at your page wich explain this nifty droplet addon

One question comes to mind,
DropletsExtension can load css :

if (function_exists('is_registered_droplet_css') && !is_registered_droplet_css('droplet_name'))) {   
  register_droplet_css('droplet_name', PAGE_ID, 'module_directory', 'frontend.css'); 
}

Maybe enhance this to include javascript as well?

Dunnoh if it is needed , but I could imagine it could be handy as well.

John
[url="http://www.ictwacht.nl"]http://www.ictwacht.nl[/url] = Dutch ICT info
[url="http://www.pcwacht.nl"]http://www.pcwacht.nl[/url] = My first
both still work in progress, since years.....

crnogorac081

This sounds great Ralf, I like idea..
Web developer

Ralf Hertsch

Hello,

droplets are one of the best and important feature of WebsiteBaker.

As long as you are using droplets only for small code-snippet it's all fine - but droplets are also used as interface for addons, i.e. for connecting Admin-Tools with the frontend or for interaction with the user. In these cases droplets have some poor restrictions:


  • the WebsiteBaker search functions ignores the output of droplets completly
  • droplets are not able to change the page title, description or keywords
  • droplets can't autoload css files

DropletExtension counterbalance these restrictions an give droplets the abilities of regular page modules.

A full description is available at phpManufaktur:

DropletExtension - der Nachbrenner für ihre Code-Schnipsel (german only, please use translation)

Download DropletExtension

Regards
Ralf