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

how do i search by field on a flexinode

I'm creating a webform that will post to a custom search module which I intend to perform a query on a flexinode type. the problem is that the node and fields are a 1 to many relationship. I don't know if I can create a temp table on the fly and join that with the node so that I can search on it or what. I'm real confused...

Ajax-style preview

Is it possible to use the Custom image gallery theme with an AJAX-style preview feature any theme? My site has a gallery but I really like the slide show on the Meta theme.

www.streamlinefencenc.com

PHP scripting issue for a block

If I have posted this in the wrong place apologies, please let me know. I didn't see a Block development forum.

I am retrieving two fields from a Mediawiki database. They are being brought in fine but due to my limited PHP skills I am having problems displaying them properly.

Here is the code:

global $user;
db_set_active('mw');
$sql2=("SELECT field1, field2 FROM mw_tablename ORDER BY field3 LIMIT 2;");
$result2=db_query($sql2);
while ($u = db_fetch_object($result2)) {
$items[]=l($u->field1, "http://www.domain/mediawiki/index.php?title=" . $u->field1);
$items[]=l($u->field2, "http://www.domain/mediawiki/index.php?title=" . $u->field2);
}
db_set_active('default');
return(theme('item_customblock', $items,"My Block Title"));

There are up to 3 records returned and I want to display them something like this:

Field1 '1st record'
field2

Field1 '2nd record'
field2

Field1 '3rd record'
field2

Field1 is the title for the record and field 2 the content. I want field 2 to be a hyperlink and field1 NOT. I can display them both as hyperlinks but I don't have the knowledge to switch off the hyperlink for the first field. Removing the hyperlink in the first $items[] line breaks the code.

Any input much appreciated,
Paul

Suggestion for comment spam

Hi guys,

how about a simple module that adds a question:

Are you a spam bot? Yes/No (radio buttons)

and it is set to be "yes" by default. Only a person who chooses "No" will be allowed to post their comment.

Better than spam module, since the spam comment won't even reach the database.

CCK or Core? Drupal 5.1

I would like to file a feature request that all content types have the ability to be automatically outlined when the url ends in /parent/NODE_ID as when creating children pages with the book module.

I am unsure where to file this request as CCK has now been integrated into core but still seems to be maintained for 5.x.

Your guidance is appreciated.

Nik

mail.module conflic with event.module

Recently I installed the mail.module and made administrator could mail the important bulletin or event nodes to users by role. I thought this module suit for a mail-contact tool.

However, I found a crucial problem when I mailed event nodes by mail.module: it repeat printed the start-time, end-time and "this message have been sent to: XX roles" in every emails. More terrible, if this role has three members, these redundant messages would increase time-by-time. The result is the no.3 member will get a e-mail contained eight repeat time messages.

Pages

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