function gdoc_field_help in Embedded Google Docs Viewer 7
Same name and namespace in other branches
- 8 gdoc_field.module \gdoc_field_help()
Implements hook_help().
Describe the purpose and usage of this module.
File
- ./
gdoc_field.module, line 19 - A field formatter for the File field, which renders the file as an embedded document, using Google's Google Docs embeddable file viewer. At the current time this viewer will reasonably display files of these types: Adobe .pdf, Microsoft…
Code
function gdoc_field_help($path, $arg) {
$helptext = '';
if ($path == 'admin/help#gdoc_field') {
$helptext = '<p>';
$helptext .= t('This module provides a new format for the File field type.' . ' This format presents the file as a fully rendered object within a web page -' . ' i.e. it displays the contents of the file as appropriate to its filetype' . ' (Adobe Acrobat .pdf, Microsoft Word .doc/.docx, Micrososft Excel .xls/.xlsx, Microsoft Powerpoint .ppt/.pptx),' . ' using the Google Docs embedded rendering engine.</p>' . '<p>N.B.: Only files that are public may use this formatter -' . ' Google Docs must be able to access the file in order to ' . ' render and display it. In other words, it won\'t work on' . ' a typical development laptop, or if your server is behind' . ' a firewall where Google is unable to access it.');
$helptext .= '</p>';
$helptext .= '<p>';
$helptext .= t('To use this field format, add a File field to a new or existing content type (such as Basic Page) on the content type\'s Manage Fields form.' . ' The File field type provides only one widget type - File - so select that. On the content type\'s "Manage Display" form,' . ' there will be a drop-down select list of available display formats for the File field. To display the file within the embedded' . ' Google Docs viewer, choose the \'Google Embedded Document Viewer\' format.');
$helptext .= '</p>';
$helptext .= '<p>';
$helptext .= t('The document viewer may be styled using the CSS selector \'.gdoc-field\'. By default, the viewer\'s width is 100% and its height is 400px, with a 1px black border.');
$helptext .= '</p>';
}
return $helptext;
}