I have a drupal site. I want to create an iframe with content from my drupal site that other sites can embed.
I think this can be achieved:
Method 1 Create a php script that is autonomous from the drupal mechanism.
Import the configuration file and therefore gain access to the database. Create content as a separate web page. Distribute the URL of this script as the iframe source url. Problems: I can not provide drupal functionality in an iframe, for example, interaction with a registered user.
Method 2 Create an iframe from inside drupal.
Create a new module that defines the menu entry using hoom_menu (url for iframe). Define the contents of the iframe from the callback function in the menu entry. Then somehow assign a custom theme page.tpl.php to the desired iframe URL so that only the contents of the iframe are displayed without any other page elements (blocks, menus, footer, etc.).
Any comments, especially for method 2, would be greatly appreciated! :)
source share