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

multiple CSS

Hi.

I have two specific question regarding CSS

1. If i want to attach a stylesheet to a module, how can I do that.
2. how can i specify multiple stylesheet to a theme

Looking forward for quick reply
Thank you
Ritesh

which module to create user tags assigned by webmaster?

I am looking for a module that tags users with tags such as "editor" and "newcomer."

for example, this joomla page shows tags under the user's name
http://forum.joomla.org/index.php?topic=40946.0;prev_next=next

I need some help with creating forms (beginers)

Hallo I have two beginers questions about creating modules.

My first question is: I have created a module with some help from "How to create your own simple node type (from story node)", but I dont want the title-textfield in the form. Can i disable the title-textfield in my form or is there a better whay of creating forms for modules?

Two nodes of different types from the same form. Is it even possible?

The case:
I'm making a new node type called 'business', so that business owners can register their business with my catalog.
I want the business owners to be able to add their logo to the node, or use a previously added logo (for store chains etc).
I want each logo to be an image type node.

This is no problem:
I've figured out how to list images filtered by a taxonomy term / image-gallery and use it in a form.

The problems:
The problems starts when a new logo is to be added.
I want this to be as simple as possible for non techy store owners to use, with a minimal chance of messing things up.
So far I've come up with two ideas, but I have not been able to figure out how to code any of them.

Suggestion 1:
Is it possible for me to somehow create two nodes of different types from the same form? i.e. create a new image node under a given taxonomy term with the data from the business node form.
I'm struggling to figure out what function (probably one in node.module) to call to bypass the node creation form in the image module. What I would like to do is to call some create_node($type, $form_fields, $terms) function. Does one excist?, or maybe I can call several functions to accomplish this.
It should be possible to automate the node_creation process like syscrusher has done in his image_import module, (http://drupal.org/project/image_import). Sadly it escapes me how it is done, I got lost somewhere in all the debug functions still in there.

Drupal.org-style Code Quoting

What module (or filter) does Drupal.org use to support inline display of HTML and PHP code in forum posts (or any post for that matter?) I'd like to add similar functionality to my Drupal site, but haven't been able to track down what enables this.

Apply node filters without calling node_view ... any ideas?

With the CCK maturing and Views the best thing since sliced bread, drupal is becoming, among many other things, an incredible backend for flash only projects.

I have created a "flashapi.module" that I use to expose just a few functions via xmlrpc that cover most of everything I need in flash, like:

flashapi_get_node(nid) - returns a node object
flashapi_get_view(view_name) - returns an array of node objects in a view (simply amazing)
flashapi_send_contact_email(name, email, subject, message, etc.) - sends an email
...

Here is the code for flashapi_get_view()


function flashapi_get_view ($appkey, $view_name)
{
  $app = flashapi_validate_app($appkey);
  if($app !== true) {
    return flashapi_error($app);
  }
  
  $view = views_get_view($view_name);
  if ($view == null)
  {
    return flashapi_error('View does not exist.');
  }
  
  $result = views_build_view('result', $view);
  while ($node = db_fetch_object($result['result'])) {
    $nodes[] = flashapi_node_format(node_load($node));
  }
  
  return $nodes;
}

Right now, when returning a node object, the object does not have any filters applied to it.

My question is:
How can I return a node object via flashapi_get_node or a list of nodes via flashapi_get_view, with filters applied?

I can't just run node_prepare() on the node, or check_markup() on the desired fields, becuase I will also need to trigger the hooks in CCK to filter the custom fields there.

Pages

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