Drupal is no doubt one of the best content management systems out there and is being used by thousands of sites across the world. The system is very secure but as soon as some security vulnerabilities are found it may be prone to attack/spam. I recently had a client's website being spammed (hundreds of user accounts were being created everyday) so I started looking for some solutions and came across these modules which are extremely effective at stopping spam.
Let’s say you have two tables with the table structure as follows:
PARENT: id (PK), name
CHILD: id(PK), parent_id(FK), value
If you want to get the list of parent along with all child values in a single row, you can run an SQL query as follows:
Read more… SQL Tricks – Multiple child rows in one row (Single column)
Let’s say you have two tables with a table structure as follows:
PARENT: id (PK), name
CHILD: id(PK), parent_id(FK), field_id, value
If you want to get the list of parent along with all child values in a single row but multiple columns, you can run an SQL query as follows:
Read more… SQL Tricks – Multiple child rows in one row (Multi column)
I recently had one of my Drupal sites hacked. The Drupal core wasn't up to date with its security patches and consequently it left the backdoor open, allowing a hacker to add malicious script to the Drupal core files.
This hack added a malicious script to Drupal’s core files namely index.php, .php and .js files inside themes directory etc.