How to limit field select list using node access?

Hello, perhaps someone can point me in the right direction:

I've got a few organizations (each an instance of a new Content Type called Organization). All users will belong to one of these Organizations. Each Organization will have an internal blog (using the Blog content type), only viewable by the other users in that Organization. Each Organization will have one admin who is responsible for that Organization.

I've figured out how to use the modules References, Node Access Node Reference and Node Access User Reference to sort of set this up: the Organization content type has a User Reference field so that an admin can assign users to the Organization.

So then I set up the Blog type with a node reference field to point to Organization.

The problem I'm having is: when I log in as a user who is a member of an Organization, the select list shows EVERY Organization, and not the one the user belongs to. So for example I'm a member of Organization A, I should only be able to create a Blog post for Organization A, but I'm able to select Organizations, A, B, and C.

How do I limit the select list to include only the nodes I'm allowed to post in?

Enabling MathML in a drupal form

For my first module I need to display some MathML in a form. I wanted to display the MathML-code in an element called showmath:

$form['showmath'] = array(
  '#prefix' => '<div>',
  '#markup' => $mathmlcode,
  '#suffix' => '</div>',
  );
 

My example $mathmlcode is the following:

<math xmlns="http://www.w3.org/1998/Math/MathML">
<msup>
	<mi>a</mi>
	<mn>2</mn>
</msup>
</math>

At first MathML did not display properly. I found a javascript at link which I inserted at the beginning of the page.tpl.php of my current theme. With this change mathml displayed properly in Firefox and Chrome but still refused to work in MS InternetExplorer.
After some testing I changed the MathML-code to:

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:m="http://www.w3.org/1998/Math/MathML">
<OBJECT ID="mathplayer" CLASSID="clsid:32F66A20-7614-11D4-BD11-00104BD3F987"> <!--comment required to prevent this becoming an empty tag--></OBJECT>
<?IMPORT NAMESPACE="m" IMPLEMENTATION="#mathplayer" ?>
<m:math xmlns="http://www.w3.org/1998/Math/MathML">
	<m:msup>
	<m:mi>a</m:mi>
	<m:mn>2</m:mn>
	</m:msup>
</m:math>

How to update a D7 -dev version to another?

I have installed several -dev versions on my site, and would like to update to a newer -dev version. But how can I do this? The update manager only suggests "green" releases for update, even if these are months-old alpha releases. When I try to install the newer -dev package through "/admin/reports/updates/install", I get an error that this module is already installed. AFAIK, I can't uninstall the old dev package without data loss either, because its database tables will be deleted, and possibly other uninstall operations executed.

So how can I update?

Regions inside content

Hi,
is it possible with Drupal, to have custom regions inserted IN the content?
I am wondering this, because I need to create a grid layout, with 8 boxes, just on my homepage, for now. Is there a way to accomplish this? Moreover, this boxes could be used in other sections pages, and it is the customer who will finally choose where to use them. The only place where it is sure they will be used is homepage, as I said. This box must draw content from site sections like Events, for example.
I hope someone could point me to info on how to get this kind of result.

Is it worth moving to Drupal 7 just yet?

Hi,

I am about to start creating a web site and I am thinking about using Drupal 7. I have used it quite a bit so far and really liked it. However I realize that many modules (such as gMaps) are still being developed for the newer version of Drupal.

Do people generally think it is a good idea to move to Drupal 7 or is it probably best to keep using Drupal 6 for slightly longer?

Thanks in advance

How to use Jquery in nodes

Hello,
I try to use something like this in my node:

<div id="link">LINK</div>
<div id="container">First Container</div>
<div id="container" style="display:none">Second Container</div>

I added a js-file to my template with the following content:

Pages

Subscribe with RSS Subscribe to RSS - Drupal 7.x