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

A Module For Selling Ebooks

Hello, a few days ago I finished coding a Drupal module for selling ebooks.

It borrows some ideas from the great ecommerce package but is supposed to be simpler and doesn't require registered users to buy and download ebooks.

It supports Drupal 4.7 but I'm already porting it to 5.0. It can work with Authorize.net and Paypal.

Regards!

Showcase Module - use AJAX to put categorized teasers into a block

I will eventually post this as a standard Drupl.org project - but since they are taking a while to set up my CVS account, I thought I would post here.

This is a custom module designed by www.LiquidCMS.ca. Until I have a project page setup on drupal.org - please see this link (www.LiquidCMS.ca/showcase1) for more info, demo and ZIP file.

The module allows a slide show presentation of teasers from a set of categorized nodes into a specified block. The module uses AJAX to return these teasers from the database.

The admin->settings for this module allow the site adminstrator to set the following parameters:
Block ID: the ID of the block that you want the showcase to display in (defaults to "showcase"
Category: the category of nodes to use for showcase (defaults to "showcase")
Delay: the time delay between slieds in the showcase
Start Delay: the delay before the showcase starts to run
Control Enable: whether to enable the showcase control panel
Top: the top absolute coordinate of the control panel
Left: the left absolute coordinate of the control panel

Although typically Drupal designers think of blocks as going in the left/right borders - a block may be located anywhere. For example the "liquid" theme used for the LiquidCMS site has a block with ID = "block-block-showcase" in the page header (in page.tpl.php).

Hope this is of use to people,

Peter Lindstrom

Question: How much could I partion one instance of a Drupal website?

So with different site configs, it appears that I could have one instance of Drupal and run different websites using different themes and different databases. Has anyone does this effectively? Seems great for a couple cases I can think of with our biz:

1. We have one business that owns several radio stations and we're building their site. So I could have one instance of drupal and set up different configs based on the domain name right? Each having their own data and theme instead of installing drupal for every single site.

error when not logged in

I am getting this error when viewing my site without logging in. user warning: Unknown column 'grant_edit' in 'where clause' query: SELECT COUNT(*) FROM node_access WHERE (nid = 0 OR nid = 1) AND ((gid = 0 AND realm = 'all')) AND grant_edit >= 1 in /home/warpgate/public_html/drupal/includes/database.mysql.inc on line 120.

How to determine module URL?

I'm sure this is a very easy question, but I haven't been able to figure it out for anything. How do I determine the URL of the currently running script? The closest I've been able to come up with is request_uri(), but that won't work because it leaves the any query strings in tact. I need a way to get just the URL of the current module.

For example, I have a module that includes different pages depending on which date was passed, like so:
/dailystrips?date=xxxx.xx.xx

make list with download and delete

I want to make a list of files in {dir_name} with download and delete.

I stuck between function editor_delete() and modul_delete_confirm_submit() , when I press delete button (first function) nothing happened. But I can't understand why ? And I don't know how to make dowload for files in the list.

I've been trying to fix a problem with my module, but
Here's my (shortened) code example:

<?php
if ($may_cache) {
$menu_type = MENU_CALLBACK |MENU_VISIBLE_IN_TREE
|MENU_MODIFIABLE_BY_ADMIN;

$retval[] = array(
"path" => "admin/module",
"title" => t("module"),
"access" => user_access('access module page'),
"callback" => "module_page",
"type" => $menu_type,
);

$retval[] = array('path' => 'admin/settings/module',
'title' => t('module'),
"access" => user_access('module configuration'),
'callback' => 'module_configure');

if(arg(2) == 'delete')
$retval[] = array('path' => 'admin/module/delete/'. arg(3), 'title' => '', 'access' => user_access('access module page'), 'type' => MENU_CALLBACK, 'callback' => 'editor_delete');
}

return($retval);

}

function module_page() {
$content .= _module_files_display3();
return($content);
}

function _module_files_display3() {

$header = array(t('File name'), array('data' => t('Operations'), 'colspan' => 2));
$dirname = 'mydir';

Pages

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