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

Is there a code example for theming a flexinode_x flexinode content type?

The flexinode README states "Alternately, you can override the theme_flexinode_* functions to change
the look of all fields of a certain type.". Is there a code example available for doing this in xtemplate?

thanks,

Robert Douglass

---------------
visit me at http://www.robshouse.net

Flexinode field_file.inc still not working for me

I've updated my CVS installment to include the flexinode field_file.inc commit http://drupal.org/cvs?commit=5205 from Bèr / JonBob, but still cannot upload files. The file gets transferred to the temp folder but never makes it to the files folder. Are other people having success with this?

-Robert Douglass
----------------
visit me at http://www.robshouse.net

Modifying contact module

Anyone out there succeeded in tweaking the contact module?

I'm trying to take out the email addresses and replace that with a prvaite message link.

(am a newbie, so apologies in advance if that is a stupid question).

Am also trying to tweak the search page. Anyone know how to exclude fields in the search page/form?

Jason

the real multi-language Drupal, an elegant way

Hello Drupal community,

please, could you consider/criticize?

Yesterday, I have finished with synchronization bugs in i18n module, and today morning there came to me an idea on how to build true multi-language support in Drupal. It is a fresh idea, may be stupid.

shortly spoken - we can translate queries, not tables

You see, the approach of i18n module is to translate tables prepending language code. What worries me, is the number of things it affects. For example, menus module - i18n makes an array of $db_prefix and this produces PHP notice and this produces error in menus module; the i18n module synchronization had some bugs itself see - http://drupal.org/node/view/10708 and you may find probably more bugs here, at Drupal's.

And again, what is probably worse, is the approach of i18n module - we are duplicating objects. Instead of having one document with language versions, we are having two or more versions of tables that should contain the same objects. But this is true only at the beginning, later, the objects will start to live their own life making synchronization difficult.

my point is this - we do not need to create different tables for different languages, we need only some content to be translated and therefore we can manage to alter queries before they are executed.

instead of

cz_node
=======
nid | type | title | story | score | created ...
------------------------------------------------
1   | story| můj-X | tady..| 5245  | 101245

en_node
=======
nid | type | title | story | score | created ...
------------------------------------------------
1   | story| myX   | text  | 1255  | 101245

we could have

node
=======
nid | type | title | cz_title | story | cz_story  | score | created ...
------------------------------------------------
1   | story| myX   | můj-X    | text  | tady...   |1255   | 101245

Doing this we will keep our objects un-duplicated, they will share the same administrative data and they will be updated properly. User can choose what he/she wants to translate -(exactly, what columns of the table should be translated) and for other modules? The other modules will be totally unaware that something was changed - nothing changes for them.

Consider this query - it creates new vocabulary:

INSERT INTO vocabulary (name, nodes, description, multiple, 
required, hierarchy, relations, weight, vid) VALUES ('New vocabulary', 
'page', '', '0', '1', '2', '0', '0', '88')

before it is issued (that means - somewhere before _db_query() ) it may be altered to this

INSERT INTO vocabulary (name, nodes, en_description, multiple, 
required, hierarchy, relations, weight, vid) VALUES ('New vocabulary', 
'page', '', '0', '1', '2', '0', '0', '88')

Do you see "en_description"? Only one column needs to be translated - not the whole table, we can change original query, we do not need to make separate tables. Of course, the colums must exist, but this would be task for administrative part of module - in administration stage, when user enables multi-language versions of something, the columns will be created created automatically and their names stored.

the problem is:

new module

I just recently have created a new module.

Basically what this would do is display in a block latest postings on a particular taxonomy.

There're lot of things need to be done:
1. put more link
2. select what node types to display on the block
3. include related terms and synonyms on that block

here's the code, feel free to test and comment on it. thanks...

[%
function taxonomy_block_link($type, $node = 0, $main = 0) {
if ($type == "system") {
drupal_set_html_head("
rel=\"stylesheet\"
href=\"modules/taxonomy_block/taxonomy_block.css\" />\n"
);
}
}

function taxonomy_block_help($section = "admin/help#taxonomy_block") {
$output = "";

switch ($section) {
case 'admin/help#taxonomy_block':
$output = "

Display list items from taxonomy in a block.

";
break;
case 'admin/system/modules#description':
$output = t("Display in a block the list of items/nodes from taxonomy.");
break;
}

return $output;
}

function taxonomy_block_block($op = "list", $delta = 0) {
if ($op == "list") {
$vocabularies = taxonomy_get_vocabularies();
$ctr = 0;
foreach ($vocabularies as $vocabulary) {
if (variable_get("taxonomy_block_show_" . $vocabulary->vid, 0)) {
$vocab_tree = taxonomy_get_tree($vocabulary->vid, 0);

Need help integrating phorum5 with drupal

Hi,

I have a site running since 1997 (www.bmwe30.net) that I'm currently converting to drupal.
I'm currently using webbbs to power the site's forums, which I'll replace with phorum5 (www.phorum.org).

Pages

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