Download & Extend

Some API fixes for the D6 port of reptag arising from testing

Project:Rep[lacement]Tags
Version:6.x-1.x-dev
Component:Code / API
Category:bug report
Priority:normal
Assigned:dman
Status:closed (fixed)

Issue Summary

Two fixes:

D6 now returns content type definitions as an object, not an array from content_types. Large (but simple) fixes were needed in _reptag_admin_content_form() converting $type['name'] to $type->name etc throughout

D6 requires theme functions to be declared to the theme registry - so theme funcs declared and used by tag plugins need extra work.
For now, I've just put a declaration of theme_reptag_node_embed($node) into reptag.module. So that {NODE:n} works again. If many other tags want to declare theme funcs, this may need some other solution.

Maybe more to come as I try some tests.

Again - I don't mind becoming a maintainer for this mod.

.dan.

AttachmentSize
reptag-drupal6_api_fixes-20081123.patch6.16 KB

Comments

#1

Status:needs review» fixed

Hi dman!

Sorry for my ignorance over the last weeks. I have been extremely busy with job-related tasks. I didnt manage to take a look at the issues queue frequently nor did I answer private mails for at least 6 weeks :( I know that shouldnt happen, but I couldnt help.
However, things are getting readjusted and I will be able to spent some time on the code. For the moment I committed some updates to the 6--1 branch based on your patch.

D6 now returns content type definitions as an object

True, but CCK still returns an array. I simply added a cast to array so it should work in either case.

D6 requires theme functions to be declared to the theme registry

Oh yes, I missed that completely. The easiest solution to this problem is to introduce a hook_theme for the .tags modules as well. So all modules implementing custom theme_ functions must declare those in reptag_mymodule_theme().

As for the co-maintainer task I would really appreciate you jumping in. There are still some unresolved issues (e.g. support for Views2 rendering). I just granted you CVS access for reptag, so you are welcome to commit patches yourself. For larger or structural changes I'd prefer to review and discuss them with you in the issues queue first.

Cheers, Thilo

#2

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.