Skip to main content
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
Results tagged with
Search options not deleted user 19722

Version tags should be used for questions that apply to a version only, not to merely say what version a site is using.

-3 votes
1 answer
914 views

Drupal queue item not being processed [closed]

I am creating queue items from a cronjob. But it seems they are not getting processed. Any ideas why? Do we need to process the items separately? I mean i have created the worker class and everything …
Pratip Ghosh's user avatar
0 votes
0 answers
350 views

Empty link creation

Is there a way to create an empty link in D8? What I want specifically is <a href="javascript:void(0)">Link</a> Url::fromUserInput('#', ['fragment' => '#']) creates an anchor tag with ## link. Tha …
Pratip Ghosh's user avatar
3 votes
2 answers
1k views

Alternative for .inc files

I was wondering what is the correct alternative of .inc files in Drupal 8? …
Pratip Ghosh's user avatar
0 votes
0 answers
242 views

D8 override core class

I am using SHS module. What I want to do is, override the SHS widget such that the I can alter the query used to fetch the data in the widget. Till now, I have overriden the route controller and have …
Pratip Ghosh's user avatar
0 votes
1 answer
249 views

D8 alter hook sequence

I was wondering if using hook_module_implements_alter() is a good practice in D8 also to alter the order of execution of hooks? I came to hear that it is suggested to do this with events that was int …
Pratip Ghosh's user avatar
0 votes
0 answers
95 views

Callbacks as objects

I find that in Drupal 8 we can specify the submit/validate callbacks as objects. So I was wondering, if we are form-altering a certain form, how do we specify the submit callback as an object? … Also I'd like to ask if this is a good practice in Drupal 8 to separate these callbacks, and put them in a separate class file, so that the module file remains clean and lazy loading works properly. …
Pratip Ghosh's user avatar
1 vote

Views query alter add grouping

I am not sure why people down-voted my question. It might have been a little silly to ask if there's a way to alter the group by of a views query using hook_views_query_alter because I think aggregati …
Pratip Ghosh's user avatar
1 vote
1 answer
2k views

Create custom URL pattern

Using the pathauto module, we could have created custom URL patterns using the hook_pathauto(). I could not find any such way to achieve the same in D8. ref. https://envisioninteractive.com/drupal/us …
Pratip Ghosh's user avatar
1 vote
1 answer
357 views

Missing module error while running unit test

I am trying to run a unit test for one of my contributed modules in my local development environment. But it keeps throwing an error: $:/path/to/web$ sudo -u www-data -E phpunit -c core/phpunit.xml pr …
Pratip Ghosh's user avatar
0 votes
1 answer
2k views

Views query alter add grouping

Can anyone please help me how to add/alter/remove aggregate options like count/sum/average etc. along with groupings using hook_views_query_alter in Drupal 8. I cant seem to find a suitable example. …
Pratip Ghosh's user avatar
0 votes
1 answer
400 views

Shortcode in template

I have installed and configured Shortcode in a D8 project. However, when I try to use a short code like [column] or [button], it gets rendered as is in the node view page. I have used a block panel i …
Pratip Ghosh's user avatar
0 votes
0 answers
219 views

Date time save in database

I have two very basic vanilla installation of Drupal 8. One I have installed a few months back, and one I installed today. I have an identical datetime range field in both of them. …
Pratip Ghosh's user avatar
-1 votes
1 answer
167 views

Breadcrumbs not appearing

I have a custom theme extending the bootstrap theme. In my theme there are no extra files except the .info.yml file. Everything else is inherited from bootstrap. I have also kept the regions in my cus …
Pratip Ghosh's user avatar
0 votes

Breadcrumbs not appearing

I had to check the conditions applied to the block when it is placed inside a region. For me, this was the case. The issue happened because of some default values stored from one of my custom conditio …
Pratip Ghosh's user avatar
1 vote
1 answer
1k views

Different node form id for add/edit

I recently found that unlike Drupal 7, D8 has a different form id for addition and edit of nodes. Is there a specific reason for that? Because this makes the hook_form_FORM_ID_alter() less granular as …
Pratip Ghosh's user avatar

15 30 50 per page