Getimagesize error

Hi

I turned on debug mode and getting this error.

<errormsg>getimagesize() [<a href='function.getimagesize'>function.getimagesize</a>]: Read error!</errormsg>
<errornum>8</errornum>
<errortype>Notice</errortype>
<scriptname>/home/***/httpdocs/ds2/modules/image.module.php</scriptname>
<scriptlinenum>213</scriptlinenum>

Also the ticker images dont display. Ticker cache files are created in the library folder but they are empty.

İ tried installing it in two different servers. Result and error are the same. No ticker images. Other fuctions seem to be working fine.

Hi,

I’ll reply here and close your other topic.

This would indicate that the CMS has a problem downloading the ticker files

Could you go to report fault page and see if everything there is checked? or are there any ?
Could you go to modules page and click verify all?

I’ll assume that you are using Windows client, ticker images(rss media feed) and other embedded content should be in your player local Xibo library (…/MyDocuments/XiboLibrary by default).

If you don’t have them there, then player could also have some problems with downloading them, could you please show us a screenshot of your player’s status window (press “i” while Xibo player is running)

Thanks,
Peter

Report vault is clean. No errors. Files are downloaded in local folder but the ticker image files are empty(0kb). They are also 0kb in the server. As in the previous topic this issue just started. Also my local server nstallation works fine. Can this be a regional issue. (posting from Türkiye)

Yes, so both CMS and player can’t download those files
Potentially your RSS feed provider is disallowing direct links to those files, it’s not a regional issue, but it might be related to the feed you’re using.

Could you please try different feed with debugging enabled?
If you are out of ideas, then try this one:
http://www.nasa.gov/rss/dyn/image_of_the_day.rss

After this test we will know for sure, if your current feed is causing the problem, or is the problem somewhere else.

Nasa feed is not working as well. Can i point out again that this issue just started. I was using 1.7.3 when problem occured. I made another installation with 1.7.4. The problem is the same.

latest status window:

It isn’t a player problem - we will need your CMS logs from the Report Fault wizard.

I would imagine that your CMS cannot download the image URL’s that come with the ticker (for some reason!) - hence the 0KB files you noticed in the library

Sorry, i am pasting the entire report here!


LOG Dump

Date,Page,Function,Message
"2015-07-10 15:41:52",“layout”,"",“Loading permissions for layoutid 6"
“2015-07-10 15:41:52”,“layout”,“IsValid”,”[IN]"
“2015-07-10 15:40:51”,“layout”,"",“Loading permissions for layoutid 6"
“2015-07-10 15:40:51”,“layout”,“IsValid”,”[IN]"
“2015-07-10 15:39:50”,“layout”,"",“Loading permissions for layoutid 6"
“2015-07-10 15:39:50”,“layout”,“IsValid”,”[IN]"
“2015-07-10 15:38:49”,“layout”,"",“Loading permissions for layoutid 6"
“2015-07-10 15:38:49”,“layout”,“IsValid”,”[IN]"
“2015-07-10 15:37:49”,“layout”,"",“Loading permissions for layoutid 6"
“2015-07-10 15:37:49”,“layout”,“IsValid”,”[IN]"
“2015-07-10 15:36:49”,“layout”,"",“Loading permissions for layoutid 6"
“2015-07-10 15:36:49”,“layout”,“IsValid”,”[IN]"
“2015-07-10 15:35:48”,“layout”,"",“Loading permissions for layoutid 6"
“2015-07-10 15:35:48”,“layout”,“IsValid”,”[IN]"
“2015-07-10 15:35:16”,“User”,“DisplayList”,“SQL: SELECT display.displayid, display.display, displaygroup.description, layout.layout, display.loggedin, IFNULL(display.lastaccessed, 0) AS lastaccessed, display.inc_schedule, display.licensed, display.email_alert, displaygroup.DisplayGroupID, display.ClientAddress, display.MediaInventoryStatus, display.MacAddress, display.client_type, display.client_version, display.client_code, display.screenShotRequested, display.storageAvailableSpace, display.storageTotalSpace, currentLayout.layout AS currentLayout, currentLayout.layoutId AS currentLayoutId FROM display INNER JOIN lkdisplaydg ON lkdisplaydg.DisplayID = display.DisplayID INNER JOIN displaygroup ON displaygroup.DisplayGroupID = lkdisplaydg.DisplayGroupID LEFT OUTER JOIN layout ON layout.layoutid = display.defaultlayoutid LEFT OUTER JOIN layout currentLayout ON currentLayout.layoutId = display.currentLayoutId WHERE displaygroup.IsDisplaySpecific = 1 ORDER BY displayid. Params: array (
).”

The tricky bit is that we need to catch it the first time a feed loads, or you need to reduce your “update interval” on the ticker to 0 (temporarily) so that the files are downloaded again when you capture the log.

With the update interval set to 0, each time the ticker loads in the designer it will attempt to download and cache those images again. At that point the log should contain the calls to get the images.

I set the interval to 0 and tried to catch the error. On log page of cms i see this over an over again;

<errormsg>getimagesize() [<a href='function.getimagesize'>function.getimagesize</a>]: Read error!</errormsg>
<errornum>8</errornum>
<errortype>Notice</errortype>
<scriptname>/home/***.com/httpdocs/ds2/modules/image.module.php</scriptname>
<scriptlinenum>213</scriptlinenum>

By the way only images are not loading, i can get texts from the rss

Any progress on this issue guys?

I am getting a new error with the previous one;

<errormsg>curl_setopt_array(): CURLOPT_FOLLOWLOCATION cannot be activated when an open_basedir is set</errormsg>
<errornum>2</errornum>
<errortype>Warning</errortype>
<scriptname>/home/***.com/httpdocs/ds2/lib/data/file.data.class.php</scriptname>
<scriptlinenum>260</scriptlinenum>

As suspected, your CMS environment doesn’t allow those images to be downloaded due to configuration. You might want to have a look at this: curl - CURLOPT_FOLLOWLOCATION cannot be activated - Stack Overflow

Hello again.
I set the curl settings properly. But problem is still on. Now ticker cache files are not even being downloaded to server library(previously cache files were being created but with 0 kb size)

I am trying to overcome the issue with using another template for ticker (which doesnt download the images but directly connects to the rss feed.) İ created a template json file for my custom view (accordingly to this guide Creating Ticker Templates using "Override Template") and verified all modules. But cant see the template for ticker under appearance tab.

You just tick the override box and put your code inside the relevant fields? From then onwards your ticker is using your template.

You have something fundamental wrong with your CMS installation - it should be able to download those images (that has nothing to do with the template by the way - it happens whenever there is a [Link|image] substituted field requested).

The bottom line is that if you want to have images from the feed in your ticker, you need to make the changes necessary for the CMS to download those images OR you need to refer to those images directly and let the player download them.

Thank you for your patience guys. Turns out my web hosting company was switching settings back and forward without any notice. Tested with another server and it looks alright.

By the way the ticker json ticker templates are pretty slick. I created a few for my taste. Is it ok to share them here for others to use?

Hi,

I am glad that you found out what was causing this issue and that it’s fixed now.
You’re absolutely welcome to share your ticker templates with community, the best way to do that would be in code blocks.

You bet :smiley:

you can use <code></code> to share your, erm, code :smile: or you are quite welcome to pop them in a blog or something and link to them.

Here is a fix:
In this file https://github.com/xibosignage/xibo-cms/blob/a660ffb488bc05c00dc0b22cced18c06368d252e/lib/data/file.data.class.php#L247
On line 247 i added:

		if (!ini_get('open_basedir') && !ini_get('safe_mode')) {
		$httpOptions[CURLOPT_FOLLOWLOCATION] = true;
	} else {
		$httpOptions[CURLOPT_FOLLOWLOCATION] = false;
	}

That is certainly a reasonable workaround - although some services do rely on the Location header to serve images from RSS feeds, so the workaround is self defeating in that sense.

1.8 uses HTTP Requests: https://github.com/rmccue/Requests which I believe will try to handle this situtation transparently… i am not 100% sure though

Yes true. I have that line from simplepie. See:

Thanks for that information about 1.8!