PDA

View Full Version : RSS2 External.php and image attachments question


brandon515
09-30-2016, 07:37 PM
I am using the following url to display my forums rss feed on another page: http://domain.com/external.php?type=rss2

My question is, how would I go about limiting the size of the image attachments that are being displayed?

Currently it is displaying the image and the thumbnail, but both of them are really large. I'd like to specify that they can only be x number of pixel by x number of pixels max.

Would I need to edit my external.php file?

Thanks

MarkFL
10-01-2016, 01:37 AM
You could use CSS selectors to limit the size of images. :)

brandon515
10-01-2016, 04:43 PM
You could use CSS selectors to limit the size of images. :)

Would I ad the css to the external.php file?

MarkFL
10-01-2016, 05:04 PM
What I would do is add the CSS via a plugin, hooked at "parse_templates" with code of the form:

if (THIS_SCRIPT === 'script_name')
{
$template_hook['headinclude_css'] .= '<style>...put CSS selector(s) here...</style>';
}

Replace script_name with the name defined by the external script.