Reason Number 48 Drupal Drives Me Crazy

11.13.13

0 Comments

A user requests the ability to browse and insert links to nodes (pages) from the WYSIWYG editor, similar to how it works for uploaded files. A quick google search returns TinyMCE Node Picker which sounds perfect. Oh, wait …

This module will de discontinued and replaced with Node Picker as soon as a stable release is available.

So I go over to Node Picker, see there are no Drupal 7 releases, and read this:

This project is looking for a new maintainer. Please post in the issue queue if you are interested.

Please see LinkIt and LinkIt Picker for actively developed replacement for Node Picker.

So I go look at LinkIt and LinkIt Picker, and LinkIt Picker looks like what I want, but it’s project page notes…

WARNING: Linkit picker 1.x is currently NOT compatible with Linkit 2.x
….
Maintenance status: Seeking co-maintainer(s)
Development status: No further development

Hmmm, that sounds bad, especially since LinkIt is currently on … version 3!

Ugh, what a morass. This is not an isolated incident. Happens all the time with Drupal. Sigh.

Project Euler Problem 1

1.10.12

0 Comments

Endeavoring to be more of a producer than a consumer, ran across Project Euler which looks to be low friction but somewhat useful and interesting. Unfortunately their register/login system is broken:

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/admin/domains/projecteuler.net/public_html/includes/login_preprocess.php on line 11

So I’ll keep track on my own blog I guess and see how far along I get.

Problem 1:

If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. The sum of these multiples is 23.

Find the sum of all the multiples of 3 or 5 below 1000.

And my solution, in PHP:

$sum = 0;

for($i = 0; $i < 1000; ++$i)
{
  if(!($i % 3) || !($i % 5))
  {
    $sum += $i;
  }
}
echo number_format($sum);

Answer: 233,168

Next Page »Next Page

Categories