Hi, I am working on a theme, which needs a module to extend its functionality ( ajax callbacks, etc... -> http://sotak.co.uk/drupal-admin-theme-vol-1 )
I wonder what would be the best practice, how to give this module to users. Should I create a new project on d.o. in contrb/modules and put the module here and write into themes README file that you need to download and install it? Or should I commit it under theme's directory?
Won't it be nice if drupal could look into themes directory too to check if there are some modules inside the themes so it can stay packed together? :) Maybe new line in .info file which will specify type of contribution? eg. module/theme
marek
I suggest you create an issue node and/or write a patch for drupal 7 that allows themes to have module dependencies, and possibly allows modules to be installed from themes directories
For drupal < 7, wrap any module-dependent code in if (module_exists('MODULENAME')).
Bevan/
Yea, I should do that. thanks for suggestion. :)
The modules functionality right now is just jquery interaction right now, and the theme works without it.
Marek
On Fri, Feb 22, 2008 at 1:02 AM, Bevan Rudge bevan@civicactions.com wrote:
I suggest you create an issue node and/or write a patch for drupal 7 that allows themes to have module dependencies, and possibly allows modules to be installed from themes directories
For drupal < 7, wrap any module-dependent code in if (module_exists('MODULENAME')).
Bevan/ _______________________________________________ themes mailing list themes@drupal.org http://lists.drupal.org/mailman/listinfo/themes
What sort of jquery? You can do jquery from the theme, too. It only needs a module if it has to hook back to some Ajax/AHAH functionality.
On Thursday 21 February 2008, Marek Sotak wrote:
Yea, I should do that. thanks for suggestion. :)
The modules functionality right now is just jquery interaction right now, and the theme works without it.
Marek
On Fri, Feb 22, 2008 at 1:02 AM, Bevan Rudge bevan@civicactions.com wrote:
I suggest you create an issue node and/or write a patch for drupal 7 that allows themes to have module dependencies, and possibly allows modules to be installed from themes directories
For drupal < 7, wrap any module-dependent code in if (module_exists('MODULENAME')).
Bevan/ _______________________________________________ themes mailing list themes@drupal.org http://lists.drupal.org/mailman/listinfo/themes
The jquery actually has a click function for a.href with specified class. This can be for sure in theme but then it calls something like mycallback/admin/build, etc... which is an ajax call, so i need to get only content, not whole page.
So the module has a menu item, mycallback% where it takes the wildcard, gets the menu item for that (so if mycallback/admin/build will be called it will take admin/build) and calls the function from menu router item (page_callback) with arguments. Then I am just printing output of this function and exiting (standart ajax method).
Can't do this in theme though.
marek
On Fri, Feb 22, 2008 at 5:05 AM, Larry Garfield larry@garfieldtech.com wrote:
What sort of jquery? You can do jquery from the theme, too. It only needs a module if it has to hook back to some Ajax/AHAH functionality.
On Thursday 21 February 2008, Marek Sotak wrote:
Yea, I should do that. thanks for suggestion. :)
The modules functionality right now is just jquery interaction right
now,
and the theme works without it.
Marek
On Fri, Feb 22, 2008 at 1:02 AM, Bevan Rudge bevan@civicactions.com
wrote:
I suggest you create an issue node and/or write a patch for drupal 7 that allows themes to have module dependencies, and possibly allows modules to be installed from themes directories
For drupal < 7, wrap any module-dependent code in if (module_exists('MODULENAME')).
Bevan/ _______________________________________________ themes mailing list themes@drupal.org http://lists.drupal.org/mailman/listinfo/themes
-- Larry Garfield AIM: LOLG42 larry@garfieldtech.com ICQ: 6817012
"If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long as he keeps it to himself; but the moment it is divulged, it forces itself into the possession of every one, and the receiver cannot dispossess himself of it." -- Thomas Jefferson _______________________________________________ themes mailing list themes@drupal.org http://lists.drupal.org/mailman/listinfo/themes