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

How to get title given a path or alias?

I did search Drupal web site for this, but after a hour, unable to sort this out.

Given a Drupal path (or alias, but I can use drupal_lookup_path() to go between them), how can I get the title of that path?

For example, given node/99 or forum/47, is there a way to get the title?
Probably menu_get_item()?
menu_get_item(NULL, 'node/99') returned empty array, so not sure if there is some other issue in the way I am calling it, or if this is not the way to do it.
Any pointers appreciated.

Need to restrict the number of a node type per user

I need to be able to control the number of a particular node type one type of user can create. I've written a function that figures out the number, but I'm not sure how to go about using it. Basically, what I want to have happen is this: If a user type has a particular permission set, when he/she tries to create a new node of this type, it redirects them to another page saying "you can't, this is why". I have the new permission created and tested, as well.

Upload and attach files to new nodes via external URL

I'm building an import module that pulls information from an external URL. Everything works great except... when I want to attach a file to a node via another external URL.

The upload.module API information was impossible for me to figure out. I'm guessing it should look something like this:

     $path = "http://www.test.com/file.pdf";

     $node->upload =  $path;
      _upload_prepare($node);
      upload_save($node);

Could a Drupal upload.module expert help me out?

Thanks!

Google Gadgets!

So I've written two Google Gadgets recently (http://www.unitorganizer.com/google/algebra/algebra.xml and http://www.unitorganizer.com/google/towersofhanoi/towersofhanoi.xml) and found the process to be extremely easy, given that I had some mini-applications already.

So then I wondered to myself, would it be possible to point the url of a Google Gadget at a MENU_CALLBACK in Drupal?

The specifications of a Google Gadget require xml, in a form similar to:

<?xml version="1.0" encoding="UTF-8" ?> 
<Module>
  <ModulePrefs title="My first gadget" /> 
  <Content type="html"> 
  <![CDATA[ 
    <B>Welcome to my first gadget!</B> 
  ]]> 
  </Content> 
</Module>

So then I thought, it must be possible to turn all sorts of Views and blocks into Google Gadgets, simply by hijacking the code and presenting the correct headers etc...

Anyone interested in helping develop something like this? I'm really not a Views guru, but I can create a callback pretty easily. Presumably Google will even let us submit our URL ourselves to their handler for content directory submissions. We could then create a module that would allow users to post Views that would normally show up in a block (because these are Google Gadget sized) to the Google Gadget directory. We should even be able to create a link that lets the person add the View to their homepage automatically.

Views & CCK: searching "exposed filters"

Look at site (in Dutch,language doens't matter)

You can search a small database, and you can use some filters. I'm using Views and CCK.

How can I change the options? Now you can choose bigger than, bigger or equal than, equal to, not equal to, smaller than, .... I only need two options: smaller than and bigger than. In the views-module i don't find that option.

Insert multiple content in a same post.

Hi,

I'm looking a module for creating multiple content into the same form.

I've a very lot of content to insert in database, and i would like to have possibility to enter most possible in the same page.

If you know this type of module, ..
thanks ;)

Nico.

Pages

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