Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
Version tags should be used for questions that apply to a version only, not to merely say what version a site is using.
2
votes
Accepted
How to provide pagename.tpl.php to specific page?
copy this code to template.php (donot forget to change the yourtheme name)
function yourtheme_preprocess_page(&$vars) {
// Do we have a node?
if (isset($vars['node'])) {
// Ref suggestions c …
0
votes
Views partial Contextual Filter on username
You can achieve it by many way...make a relation with content:author and you will get all available options under user like (User: Name, User: First Name,User: last Name,User: Authentication name, Use …
1
vote
How to define custom messages in Drupal 7
I am using this to replace an existing drupal message to my custom message.
function _exclude_message($mymessage, $mytype="status"){
$flag = false if ($messageArr = drupal_set_message()) { foreach($ …
0
votes
Views partial Contextual Filter on username
ok, then you can use views_query_alter to make a relation
function mymodule_views_query_alter(&$view, &$query)
{
if ($view->name == 'your_view_name')
{
//dpm($query, __FUNCTION__);
//dpm($vie …
-2
votes
Accepted
How to insert an image into a drupal form
May be this will help..
function my_module_start_form($form, &$form_state) {
$image_options = array(
'path' => 'path/to/img.jpg',
'alt' => 'Test alt',
'title' => 'Test title',
'width' => '50%',
'h …
2
votes
Create relation between two select list for Hierarchical select option
Hope this will help you
function mymodule_form_alter(&$form, &$form_state, $form_id){
//put your form id
if ($form_id == 'two_state_node_form') {
$options_first = dynamic_add_options();
$v …
0
votes
Any way to do DISTINCT ON?
I have use this some time, Hope this will help you.
$result = db_query("SELECT node.uid AS node_uid, node.created AS node_created, COUNT(DISTINCT node.title) AS node_title, COUNT(DISTINCT field_data_ …
0
votes
How to display search query in view's results page?
I don't know whether this will help you or not but you can try this, For the title of the expose filter result you can try to add in between Global: Result summary or Global: Text area from add head …
0
votes
How to add a javascript function after uploading file
Hope this will help, use hook_file_presave inside that you can use drupal set message.
/**
* implementing hook_node_presave
*/
function mymodule_file_presave($file) {
//dpm($file);
//
if (isset( …
3
votes
Accepted
How to add a css class to sidebar first render
Create a template file with name region--sidebar-first.tpl.php in side the your theme template folder. Copy below code to inside the newly created template file
<?php if ($content): ?>
<div cla …
0
votes
redirect index.php?var1=aaa&var2=bbb
Redirect is the drupal 7 version of path redirect. …
1
vote
Accepted
File field fails to upload any files
Check the size of the files, maybe they are to big. Check the max. file sizes on your server and in Drupal!.
PHP configuration check:
check the following parameters:
post_max_size
upload_max_files …
0
votes
2
answers
70
views
Webform (*) instead of required word
I have a situation I want to put (*) instead of "required" word inside the place holder of a webform field is it possible from webform admin.
4
votes
1
answer
2k
views
Difference between Hook and function [duplicate]
I have a confusion regarding the hook and a normal function, So can any one tell me what is the significant difference between a Drupal hook and a normal PHP function in Drupal.
3
votes
Display a thank you message instead of a page redirect after submitting a Webform in a block?
You can do it, from the webform configuration page: Use Redirection location or Confirmation message.