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

Help using Views module API to display list of custom nodes

Hi

I was looking for some help using the Views API. I want to query on custom fields when I make my node listing so I dont' think I can use the form to generate my page. I am trying to use the various handlers to just make a simple listing available as a first step. I took the example table description from the API.txt file and put it in my module with no changes except the name:

Translate language strings

I use 3 languages german, french and english.

- I switched to french and created a new term "contact"
- if I go to localisation now an search for this string to translate I will find it and there is a de whitch need translation
- but opening the translation dialog will show me a german and a french field to fill it.

is this a bug or a feature?

4.7 search do not work but advanced search is ok

The 4.7 search do not work at http://cms.stnetwork.de but advanced search is ok. I run /cron.php and poormanscron is also running fine, but why do only the advanced search display results?

best wishes from germany, holger

www.ebec.net | www.stnetwork.de

Using simplevote on comments?

I have the votingapi and simplevote modules working smoothly on a 4.7 install, but I'm working towards having similar rating functionality on comments.

If I understand the documentation correctly, votingapi provides the possibility to do this, correct?

_user() question - Last stumbling block for my module

Hi

I am desperate for figure this out, its really the last thing I need to finish off my Drupal site. I am using 4.7-beta4 and I want a status bar for users. The information for the bar should be loaded into $user. The API suggests that
this is possible but using the hook _user.

I have tried this numerous ways and I can get any information I add to $user to be persistent. I have posted about this a number of times including 46551 and 46414. I realise that it seems to work for everyone so could some please please
point out what I am doing wrong in this example where I try to add a string to $user and display it in a block:


<?php
function block_example_help($section) {
switch ($section) {
case 'admin/modules#description':
// This description is shown in the listing at admin/modules.
return t('An example module showing how to define a block.');
}
}

function block_example_block($op = 'list', $delta = 0, $edit = array()) {
switch ($op) {
case 'list':
$blocks[0]['info'] = t('Example: configurable text string');
return $blocks;
case 'configure':
$form = array();
if ($delta == 0) {
$form['block_example_string'] = array(
'#type' => 'textfield',
'#title' => t('Block contents'),
'#size' => 60,
'#description' => t('This string will appear in the example block.'),
'#default_value' =>
variable_get('block_example_string', t('Some example content.')),
);
}
return $form;
case 'save':
if ($delta == 0) {
variable_set('block_example_string', $edit['block_example_string']);
}
return;
case 'view': default:
switch ($delta) {
case 0:
$block['subject'] = t('Title of block #1');
$block['content'] = block_example_contents(1);
break;
}
return $block;
}
}
function block_example_contents($which_block) {
global $user;
if ($which_block == 1) {
$output = variable_get('block_example_string', t('A default value.'));
$output .="

Profile style information (People, Businesses, or other listings) using templates

I am working on a project for a paid professional listing service that pairs contractors with customers. While somewhat new to Drupal, I have decided to implement this solution using it. I am just soliciting some advice…

First, is there already a preexisting module that offers much of the features I am seeking? I have checked for myself and I do not believe there is an out of the box solution, but I do not want to reinvent the wheel.

Pages

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