spot7.org logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML Categories
  Home » DRUPAL » Page 1
upload image on mobile device for drupal site
You can add images to Drupal, but mobile devices don't allow you to upload any photos to image fields. (Android allows it as I remember.) HTML5 allows this, but sadly that's mostly a no go with Drupal 7 at the moment. However, it turns out the fix is nice and easy via the HTML Media Capture method. Add the following snippet of jQuery, so it runs when pages load: $('div.image-widget-data input[ty

Categories : Drupal

Drupal 7: How to assign each node to different block (or region)?
To achieve this you need to create a View which grabs nodes you need (you can filter on promoted field, by content type, publication date, field value...). This view must create a block (block display mode), then you can assign this block to whatever region you like in block interface. You can create as many Views as you need, filtering nodes the way you want. More info : https://www.drupal.org/

Categories : Drupal

Custom spaces editable from back office in Drupal
There is the block module, which is part of core. Are you using Drupal 6/7/8? Anyway go into your admin section and look under structure, for blocks. You can create custom blocks and place them in a region. If you want different regions then you can define these in your themes .info file. Inside the blocks you can put whatever content you like.

Categories : Drupal

Indexing from Drupal Search API to Solr: Bad Request
I solved it myself... somewhat. The problem is that the schema.xml of the module isn't working properly with 4.10.x for some weird reason. It works if you DON'T start Solr in Cloud mode. It works properly with 3.x even in Cloud mode. I know, this isn't really helping but maybe you have the same problem as me.

Categories : Drupal

Integrating custom jQuery plugin in Drupal 7
You could include them directly in your theme's page.tpl.php file as but it is not recommended to edit modules or themes since it would affect maintainability. A cleaner way is to add the js in your theme's info file. Look for the scripts section and add a line to your plugin. Something like this: scripts[] = js/plugin.js Another approach would be to implement a custom module where you would

Categories : Drupal

Viewing, adding and editing database content
You were not clear if you need to merely manage the data, or edit the data in Drupal. If managing data is the need, use a front-end. Since you are using Drupal, you must be using PHP. If you are new to accessing databases, you may like to use PHPMyAdmin http://www.phpmyadmin.net. It may be already included with your PHP distribution if you installed PHP with MAMP, or XAMMP or one of the similar pa

Categories : Drupal

drupal_write_records() doesn’t work for those fields which was created by hook_update_n()
hook_schema or hook_update_N? Drupal provides a very powerful and structured way of upgrading your sites and making DDIC changes. The two important hooks are hook_schema() provides a structured, DB independent way of defining you table schema. When a new module is installed, the hook_schema() is automatically invoked (yes that's the case in Drupal 7, while in Drupal 6 it had to be explicitly used

Categories : Drupal


Recently Add
Getting fid of attached file in Drupal 7
upload image on mobile device for drupal site
Drupal 7: How to assign each node to different block (or region)?
Custom spaces editable from back office in Drupal
Indexing from Drupal Search API to Solr: Bad Request
Integrating custom jQuery plugin in Drupal 7
Viewing, adding and editing database content
drupal_write_records() doesn’t work for those fields which was created by hook_update_n()
© Copyright 2017 spot7.org Publishing Limited. All rights reserved.