Carry out the following steps:
Create a new folder in
blocks
namedpdf
. In this folder, create thedb.xml
file like we did before:<?xml version="1.0"?> <schema version="0.3"> <table name="btPdf"> <field name="bID" type="I"> <key /> <unsigned /> </field> </table> </schema>
Create
add.php
andedit.php
again; the content is again the same:<?php defined('C5_EXECUTE') or die(_("Access Denied.")); $this->inc('form_setup_html.php'); ?>
The forth file
form_setup_html.php
doesn't have any options in this case; it's even simpler than before:<?php defined('C5_EXECUTE') or die(_("Access Denied.")); ?> No options here!
As easy is
controller.php
, with just the mandatory things in it—no logic or anything else:<?php defined('C5_EXECUTE') or die(_("Access Denied.")); class PdfBlockController extends BlockController { protected $btTable...