@ line 306

function theme_private_number(&$element) {
  return $element['#children'];
}

should be

function theme_private_number($element) {
  return $element['#children'];
}

&$element -> $element

CommentFileSizeAuthor
#3 theme_private_number-976786-1.patch486 bytessvax

Comments

decibel.places’s picture

Title: warning: Parameter 1 to theme_private_number() expected to be a reference, value given in C:\xampp\htdocs\writersnetwork\include » warning: Parameter 1 to theme_private_number() expected to be a reference, value given

(removed unnecessary local url info from title)

JayMN’s picture

PHP 5.3 or above causes this problem (see http://drupal.org/node/578124). I experienced this when my webhost upgraded from php 5.2.x to 5.3.x. Private number fields disappeared from forms, and php errors appeared in dblog (recent log entries).

There is a typo in the issue summary, above. The solution is to remove the @ symbol from line 306, as follows:

function theme_private_number($element) {

svax’s picture

Status: Active » Needs review
StatusFileSize
new486 bytes

Just removed the Pass by reference & in the theme_private_number($element) function.
This fixes the problem on PHP 5.3, but will need testing on PHP 5.2 and below.

decibel.places’s picture

@JayMN thanks for pointing out the typo, but there was a typo in your description, the & was removed, not the @

function theme_private_number(&$element)
->
function theme_private_number($element)

SchwebDesign’s picture

thanks for this fix.

SchwebDesign’s picture

Issue summary: View changes

fix typo where the & was repeated in the corrected line: function theme_private_number(&$element) -> function theme_private_number($element)