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

video module

've just installed the 4.6 version and the video module but the mysql server isnt able to reckognize the video.mysql file contained in the package. here's the error:

user error: Table 'vegedb02.video' doesn't exist
query: SELECT * from video WHERE vidfile = '' and nid <> '0' in whole path on line 66.

Please help with javascript and Drupal

Hello, first of all, I have a javascript, and I want to insert it in Drupal. The javascript shows/hide a

tag when a link is clicked . ( onclick atribute).

OK, in my module, I add the Javascript with drupal_add_js, and the link is something like this: "<a href="#" onclick="show('the_class_atribute_of_the_div')">Show</a>"...
But nothing happens when I click on it.

I tried also this : "<a href="javascript:show('the_class_atribute_of_the_div')">Show</a>"

Help With hook_db_rewrite_sql Please

Hi, I'm writing a module for 4.7.2 and I want to have two permissions: 'view own entry' and 'view all entries'. I've implemented this in the hook_node_access function with no problem, but pages promoted to the front page or any lists are still visible.

A bit of searching showed me I need to use hook_db_rewrite_sql, but this is where my knowledge of Drupal and my ability to follow the documentation crumbles. I think I understand the purpose of this function does but not fully enough to begin this bit of my code.

taxonomy/term/17/flickrpic, Is it possible to extend the taxonomy pages

I searched around the site for about an hour or more, I lost count. I did find some interesting things that will help my site but not what I am looking for right now. With that said this is what I am trying to do and am hoping someone can point me in the right direction because my first couple of tries have not worked.

Block configure problems (please help!!)

Attention you hotshot drupal programmers, seize the day and help a newbie who is desperately in need of some advice. I have created a module who's sole purpose is to serve as a kind of block container. Essentially, it queries several database tables that hold info for user created nodes. The problem is as follows, I only want this block to show on the "front page", but whenever I select the configure option for it I get a blank page and my error log fills up with the following:

Message array_shift(): The argument should be an array in /home/httpd/html/drupal/includes/form.inc on line 469.
Severity error

My module looks like this:

<?php

/**
* @file
* Enables users to submit Rick and Fled stories
*/

/**
* Implementation of hook_help().
*/
function true_help($section) {
switch ($section) {
case 'admin/help#true':
$output = '

'. t('The true module. ') .'

';
$output .= '

'. t('The true module.') .'

';
$output .= t('

', array('%node-add-true' => url('node/add/true'), '%admin-settings-content-types-true' => url('admin/settings/content-types/true')));

Organic Groups 4.7.2 with postgresql errors

I am running Drupal 4.7.2 with postgresql 8.0.3 after installing organic groups the install failed after enabling it in modules. I then looked at the og.install and did not see any switch statement for postgresql. I copied the sql regarding the tables and ran it as the db owner from psql.

Please see copies below:

CREATE TABLE og (
nid int NOT NULL,
selective int NOT NULL default '0',
description varchar(255) NULL,
image varchar(255) NULL,
theme varchar(255) NULL,
website varchar(255) NULL,
register int(1) NOT NULL default 0,
directory int(1) NOT NULL default 0,
language varchar(12) NOT NULL default '',
PRIMARY KEY (nid)
)

CREATE TABLE og_uid (
nid int NOT NULL,
og_role int NOT NULL DEFAULT 0,
is_active int NOT NULL DEFAULT 0,
is_admin int NOT NULL DEFAULT 0,
uid int( NOT NULL,
mail_type int NULL,
PRIMARY KEY (nid, uid)
)

This seem to have cured the problem but what worries me is the following in og.install :

$sql = "ALTER TABLE {node_access} DROP PRIMARY KEY, ADD INDEX `nid_gid_realm` ( `nid` , `gid` , `realm`)";
db_query($sql);

$sql = "ALTER TABLE {node_access} CHANGE grant_view grant_view int(11) unsigned NOT NULL default '0'";
db_query($sql);

$sql = "UPDATE {system} SET status = 1 WHERE name = 'og_basic'";

Pages

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