import XML file

Hello, how can I import a XML file to a vocabulary? I'm on Drupal 7.

Thanks

Difference between D7 upgrade from v6.x & D7 clean installation

Noticed that there are difference between a new and clean installation of D7 and a D7 that has been upgraded from D6 (6.20). Among other when adding Page (which is called Basic Page in new D7 inst.) in the D7 upgraded installation version, there is no possibility of adding meny link; the option is clearly missing?!

Also the Bartik template has the Main Menu where the D7 upgrade inst is missing the Main Menu both in the list of menus and as well when using the Bartik template.

How to display new discussion block on only forum pages

Hello!

How can I display the the latest forum discussion block at only forum related pages?

In block settings i ticked show only on listed pages below and put in:

forum
forum/*

That does it for the most part, however, when a user enters a forum post and look at the comments, the latest discussion block is no longer visiable.

How can I make it happen the way I want it too?

Regards
Martin

views and organic groups

Hello

I would like some help to understand how to place a view in a group.

Prerequisites:
Drupal 7
Views - 3.0 alpha1

I have created a content type "Group" that is used to create a group.
I have created a content type: "Group content " that is used to post contents in a group.

What I want:
When a user clicks on a "Group", he/she shall see the "Group post" and below that all the "Group content" post are listed.

Strange issue with clean url

I am using D7 and having strange issues with the clean urls.
When i enable them, no form gets submitted, i can't login or do any action where a form submission is required.
For example, the contact page, if it is accessed here: http://sandbox.onetwist.com/?q=en/contact it works, but if it is accessed here:
http://sandbox.onetwist.com/en/contact it doesn't work anymore.

Adding node fields programmatically

Hello,
I created a module to provide a content type and several fields (text) for that content type.
The content type's purpose is to hold values that is parsed from a feed.
After creating the content type en fields the node is working good when I use the Fields UI to create a new node. I can enter en edit all data and all is desplayed properly.

However, when I create the node trough coding, the parsed data does not appear in the node object.
Strange thing is that the $node-> title and $node-> body, which are both also parsed from the feed, works good. Only the other field fail.

Here's the code:
<?php
function my_function_fill_nodes($id, $item_to_save, $web_page) {
// code removed - XPAT retrieving node details

$node = new stdClass();
$node-> type = 'ysm';
$node-> internal_id = $id; // TODO
$node-> title = $object_title;
$node->language = 'en';
node_object_prepare($node);
foreach (XXXXXXXXXXXXXXX) { // parsing a DOM object
switch(XXXXXXXXXXXXXX) {
case 'A' :
$node-> price[$node-> language][0]['value'] = $retrieved_value;
break;
case 'B' :
$node-> model[$node->language][0]['value'] = $retrieved_value;
break;

// this goes on for 10 items
default:

echo($retrieved_value . '| not matched
');
}
}
// seperate code parsing the body text ($body_text)

Pages

Subscribe with RSS Subscribe to RSS - Drupal 7.x