I creat a module. I have my .js file that catch attributes in an IFrame(h5p) with console.log)
When i clear the cache, i go directly to the page that i want and console.log is working( i catch attributes) but when i clear the cache and go to Home page(or any other page in drupal) and then i go to the page that i want, nothing happens (console.log doesn't work).
Hi, I have a content type called Car, where I want to load existing uploaded media programmatically while adding new content when media field is empty. I have the media id number, I tried Media::create by doing so I am getting duplicates of the same image. I tried Media::load by getting media id, its not working. any assistance would be really helpful.
I have a module that queries for a specific webform submission data and sends an array of the results to the view.
When I dpm the array before the return, it shows what I would expect. An array of strings. In my view, I am getting only one field object and it is the first letter of each element in my array. I was expecting to see a field list of each element in the array
Hi, I am trying to run a query in a custom module to get submissions from a web form. I am new to Drupal and Drupal database queries; but not new to databases and queries. My queries work in phpMyAdmin. I am working on a project that is in Drupal 7. I have tried many examples from Drupal documentation but every query I try I get:
SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'FROM node node' at line 3