Skip to main content

Home/ Drupal for Developers/ Group items tagged create

Rss Feed Group items tagged

Daniel Gregoire

Apache Solr and Drupal Default's Search | Trellon - 0 views

  • One issue that comes up from ApacheSolr being a separate search page is that the search form does not go to it by default. This is the $search_box in the page.tpl.php template. The way we change this behavior is to add a new submission handler to that form. You can create a custom module for this or put it in your custom theme. <?php/*** Implementation of hook_form_alter()*/function custommodule_form_alter(&$form, $form_state, $form_id) {  // Add submission handler to redirect to apachesolr  if ($form_id == 'search_theme_form') {    // Add a submit, because the search form redirects to a specific place    $form['#submit'][] = 'custommodule_search_submit';  }}/*** Implementation of form submit function*/function custommodule_search_submit($form, &$form_state) {  // Get form ID  $form_id = $form['form_id']['#value'];  // Create new redirect  $form_state['redirect'] = 'search/apachesolr_search/'. trim($form_state['values'][$form_id]);}?>
Daniel Gregoire

Programmatically Create, Insert, and Update CCK Nodes | doug | CivicActions - 2 views

  • Always use content_database_info to get the database info. For example:   $field1 = content_database_info(content_fields('yourfield1', 'yourtable'));  $table1 = $field1['table'];  $column1 = $field1['columns']['value']['column'];  $field2 = content_database_info(content_fields('yourfield2', 'yourtable'));  $table2 = $field2['table'];  $column2 = $field2['columns']['value']['column'];  if ($table1 == $table2) {    $sql = "SELECT n.*, t1.$column1, t1.$column2 FROM {node} n ";    $sql .= " INNER JOIN {$table1} t1 ON t1.nid = n.nid AND t1.vid = n.vid";  }  else {    $sql = "SELECT n.*, t1.$column1, t2.$column2 FROM {node} n ";    $sql .= " INNER JOIN {$table1} t1 ON t1.nid = n.nid AND t1.vid = n.vid";    $sql .= " INNER JOIN {$table2} t2 ON t2.nid = n.nid AND t2.vid = n.vid";  }  $sql .= " WHERE n.nid = %d";
  •  
    Important point: Using special functions to let CCK get the proper name of the field (allowing users to make CCK changes in the UI and let your code continue to work).
innoraft

Drupal 8 Cache Context: An efficient way for context based caching. | Blog | Innoraft - 0 views

  •  
    Cache Context is basically a service that helps in creating multiple cached versions of something depending upon the context/request; be it a view, block or any other section on the page.
paresh sagar

Top Drupal Web Development Company in India & USA - 0 views

  •  
    Top Drupal Web Development Company in India & USA. Our Drupal developers use a combination of custom and contributed Drupal Modules to create innovative solutions for your clients.
paresh sagar

10 points to consider before hiring a Drupal developer - 0 views

  •  
    A developer should have a curious mind to create unique solutions for a project. Make sure to check the innovative skills of the person before hiring a Drupal developer for your website.
clariene Austria

Never Pay for Leads Again! Online Leads are Free. - 2 views

Leads don't grow in trees. You probably know the value of a lead to your business and how much you would pay for a lead. But what if you could create a system for lead generation marketing that wo...

started by clariene Austria on 14 May 12 no follow-up yet
clariene Austria

Never Pay for Leads Again! Online Leads are Free. - 2 views

Leads don't grow in trees. You probably know the value of a lead to your business and how much you would pay for a lead. But what if you could create a system for website lead generation that worke...

started by clariene Austria on 04 Jun 12 no follow-up yet
Scott Blackburn

How to make CCK fields do some of the same tricks as taxonomy terms | !&# - 0 views

  • In Drupal, taxonomy.module implements hook_term to provide links among content which shares a given term. Site builders often use this feature to provide indexes and RSS feeds of their content. Taxonomy.module's purpose is to support the creation of controlled vocabularies which we can use to classify our site's content. If taxonomy.module were a prescription drug, this would be its "on-label" or indicated use. Using taxonomy.module vocabularies and terms to store essential data about our content is what I call an "off-label" use. You're not really creating a controlled vocabulary, and the term-node relationship in these cases isn't always classificatory. However, a clever web developer will use the tools that get the job done, and often taxonomy.module is the perfect tool for making this happen. Because this information is essential to your node's content, CCK fields are indicated for this use. However, CCK fields don't have built-in linking among nodes which share values for the same field. Also absent is any built-in RSS feed for a CCK field's value. This requires some theming and Views.
Scott Blackburn

[SOLVED] Error message when creating a new forum topic | drupal.org - 0 views

  •  
    added to og_forum.module if ($key == '') { continue; }
Daniel Gregoire

Create your own API Site in Drupal 6 | drupal.org - 2 views

  •  
    Method for setting up a local/mirror copy of api.drupal.org. Core and contrib explained (though see comments for more details).
mobeen ahmmaad

SEO Service « Uncategorized « seo-marketting.com - 0 views

  •  
    Internet marketing has created a buzzword around the world. Interests among the businessmen are increasing rapidly about internet marketing. Therefore, the number of people wanting to optimize their websites through SEO service has also increased. If you intend to do online business you will definitely want your website to be in the first page of a search.
‹ Previous 21 - 37 of 37
Showing 20 items per page