Page 1 of 1

[SOLVED] $node->image Bug in 1.9.2

Posted: Fri Jan 14, 2011 10:32 pm
by reto
Hi all,

The MenuManager.module.php for some reasons removes double slashes (probably that was intended to fix some incorrect path-glueing, but it's just lazy coding). It now removes the protocols double slashes as well.
Check the commented lines (str_replace) which brake the image URL:

Code: Select all

	  if( !empty($tmp) && $tmp != -1 )
	    {
	      $url = get_site_preference('content_imagefield_path').'/'.$tmp;
	      $url = $config['image_uploads_url'].'/'.$url;
	      //$url = str_replace('//','/',$url);
	      $onenode->image = $url;
	    }
	  $tmp = $content->GetPropertyValue('thumbnail');
	  if( !empty($tmp) && $tmp != -1 )
	    {
	      $url = get_site_preference('content_thumbnailfield_path').'/'.$tmp;
	      $url = $config['image_uploads_url'].'/'.$url;
	      //$url = str_replace('//','/',$url);
	      $onenode->thumbnail = $url;
	    }
cheers,
Reto

Re: $node->image Bug in 1.9.2

Posted: Sat Jan 15, 2011 12:32 am
by Dr.CSS
Yes it is a known thing and is fixed in next version...

Re: $node->image Bug in 1.9.2

Posted: Sat Jan 15, 2011 10:50 am
by reto
Ok, that's great news, thanks!

regards,
Reto