I'm feeling like I must be really close, but am just a little off from rendering out the my first Drupal module correctly (though of course the next step is submitting and processing the form via ajax,guess I'm not quite out of the woods yet)
Anyways, from following along through "Pro Drupal Development 7", reading and asking some questions here on stack, I've gotten to the point where I've got my Drupal module set up.
\sites\all\modules\custom\mymodule
---- mymodule.info
---- mymodule.css
---- mymodule.js
---- mymodule.tpl
---- mymodule.module
All of the requirements seem to be functioning to get the module in my blocks list, the CSS, & JS are visible on page if I choose to view source.
For testing purposes, my TPL file just has the following in it.
<h1> HERE </h1>
The module file (from what I understand, it's the place where I write my theme hook) has the following (from what I gather) key functions.
function mymodule_theme($existing, $type, $theme, $path){
return array(
'mymodule' => array(
'variables' => array('content' => "FOO"),
'file' => 'mymodule',
'path' => drupal_get_path('module', 'mymodule')
)
);
}
function mymodule_page(){
$content = "";
return theme('mymodule', $content);
}
I'm pretty sure I'm just having a small, relatively simple issue - but have been hammering away for an hour on my own. Does anyone know the answer, what am I missing here ?
Thanks!