Jump to content

image Create from String


S!r.ReaDy

Recommended Posts

imagecreatefromstring(): Couldn't create GD Image Stream out of Data

This error occurs  when creating custom settings for the theme, and especially for image radio setting, after the sync from file system or disabling Designers mode and sync.

Sample code.
 

<?php

return new \IPS\Helpers\Form\Radio( "core_theme_setting_title_{$row['sc_id']}", $value, FALSE, array( 'options' => array(
  'ai' => "<img src='" . $theme->resource('enhancements/a.png', 'core' ) . "' alt='[a] [i]' class='ipsImage'>",
  'ia' => "<img src='" . $theme->resource('enhancements/b.png', 'core' ) . "' alt='[i] [a]' class='ipsImage'>",
			), 'parse' => 'raw' ), NULL, NULL, NULL, 'theme_setting_' . $row['sc_key'] );

php 7.2

 

 

in php 7.3 gives Failed to read the file

Edited by S!r.ReaDy
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...