This forum is for module development and code related questions, not general module support. For general support, use the Post installation forum.

simple page module

Hi,

I'm a newbie to drupal and read the module developers tutorial but it left me still a bit puzzled.

i need to integrate my webapp to drupal as a module. front-end usage is quite simple, i just need to show one page that queries data from the database and formats it according to a html template.

i'm know how to use hook_menu() to create the link to the page, but can really figure out what method should i use to show the data.

there shouldnt be any edit/submit pages. just the plain html page that is generated in the correct method. The method should also be able to get the logged user name from the framework so the module is able to query user specific data (how do i request the logged uid, or username, from drupal?)

function modulename_menu($may_cache) {
  $items = array();

  if ($may_cache) {
$items[] = array('path' => 'modulename/parameter', 'title' => t('view generated html'),
      'access' => user_access('view datapage'));
  return $items;
}

i understand that the modulename defines the module, and parameter defines the page somehow? how do i read that parameter? what hook is called to create the html in the middle column of the page shown in the browser?

this must be pretty simple, and most likely found easily in some tutorial, but i just dont seem to figure out where it is.

what is the minimum skeleton module for showing a link in the left menu to "datapage" page that you just can view (no add/edit form at all) and shows a bare page with text "datapage"?

feedback module alternative for 4.6

anybody else doesn't like the feedback module?

i had a look at its code, and imho it isn't very clean. so i made a stripped down version of it (no validation of the email address by contacting SMTP server), but i implemented some features of the contact.module in 4.7.

the features i added, are

  • flood prevention
  • a optional configurable list of categories, like the new contact module

further i payed attention to secure the module, so that it's not possible to relay spam or spam you (flood prevention).

SimpleNews

Drupal 4.6.5

I finally had a need for a newsletter module. So, I decided to pick simplenews.mod from our choices.

Nice!... very nice!

I think it is one of the best newsletter modules I have "ever seen" or loaded.

I have only completed the simple test so far. Will have others test drive it tomorrow.

Big thanks!

Quicktags link fix

I modified the quicktags link button so now instead of returning "Link Text" between the a tags, it inserts the highlighted text (normal for most programs)

Change line 78 from
array('ed_link','link','','','l', -1, 'edInsertLink'),
to
array('ed_link','link','','</a>','l', -1, 'edInsertLink'),

How to create multiple nodes at the same time?

I would like to create multiple nodes from a single form in a module. All the "hooks" seem to be for the single node that is getting created. I can't find any documentation or examples to assist.

Can someone point me in the right direction?

Thanks !

Path Access Problem

I installed the Path_access module and restricted one page on my site, now, for some reason when i am not logged in and try to go to the home page i am getting a fatal error... need help desperately.

Pages

Subscribe with RSS Subscribe to RSS - Module development and code questions