Image Sizes

nate
@nate
12 years ago
917 posts
I have an image that is by default 52x512 or 5spx height and 512px width. Jamroom keeps returning a 512x512 image.

How to I override this?
updated by @nate: 12/27/13 10:53:46PM
brian
@brian
12 years ago
10,149 posts
How are you calling it? Is it in a template or a PHP script?

Thanks!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
nate
@nate
12 years ago
917 posts
A php script.
brian
@brian
12 years ago
10,149 posts
Is it an item image or a skin image? Can you show me what you are doing right now?

Thanks!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
nate
@nate
12 years ago
917 posts
Image:
$media .= " waveform: \"{$_conf['jrCore_base_url']}/{$module_url}/image/audio_waveform_image/{$_rt['_item_id']}/crop=false/xxlarge/\"},";

Function:
function view_xtPlayList_list($_post,$_user,$_conf)
{ if ( !isset( $_post['tracks'] ) ) { return false; } $tracks = rtrim($_post['tracks'], ","); $_rs = explode( ',', $tracks ); $module_url = jrCore_get_module_url($_post['mod']); $media = ""; //load all songs requested foreach ($_rs as $_trk => $val) { $_rt = jrCore_db_get_item($_post['mod'],$val); $profile_url = "{$_conf['jrCore_base_url']}/{$_rt['profile_url']}"; $audio_url = "{$profile_url}/{$module_url}/{$_rt['_item_id']}/{$_rt['audio_title_url']}"; $date = date("Y-m-d", $_rt['_created']); $audio_price = strlen($_rt['audio_file_item_price']) > 0 ? $_rt['audio_file_item_price'] : 0; $promo = 'false'; $bought = 'false'; $media .= "{title_id: \"{$_rt['_item_id']}\",\n"; $media .= " track_id: \"{$_rt['_item_id']}\",\n"; $media .= " artist: [[{$_rt['_profile_id']}, 1, \"{$_rt['profile_name']}\", \"{$profile_url}\"], [{$_rt['_item_id']}, 1, \"{$_rt['audio_title']}\", \"{$audio_url}\"], [3809, 2, \"{$_rt['profile_name']}\", \"{$profile_url}\"]],\n"; $media .= " title: \"{$_rt['audio_title']}\",\n"; $media .= " title_url: \"{$audio_url}\",\n"; $media .= " track_url: \"{$audio_url}\",\n"; $media .= " label: [13088, \"{$_rt['audio_label']}\", \"{$module_url}\"],\n"; $media .= " genre: \"{$_rt['audio_genre']}\","; $media .= " genre_url: \"/{$module_url}/genre={$_rt['audio_genre']}\",\n"; $media .= " catnumber: \"SSR1301000\",\n"; $media .= " promo: {$promo},\n"; $media .= " duration: \"{$_rt['audio_file_length']}\",\n"; $media .= " r_date: \"{$date}\","; $media .= " price: {hbr: {$audio_price}, wav: {$audio_price}},\n"; $media .= " bought: {$bought},\n"; $media .= " image: \"{$_conf['jrCore_base_url']}/{$module_url}/image/audio_image/{$_rt['_item_id']}/large/\",\n"; $media .= " thumb: \"{$_conf['jrCore_base_url']}/{$module_url}/image/audio_image/{$_rt['_item_id']}/small\",\n"; $media .= " mp3: \"{$_conf['jrCore_base_url']}/{$module_url}/stream/audio_file/{$_rt['_item_id']}/key=1/file.mp3\",\n"; $media .= " waveform: \"{$_conf['jrCore_base_url']}/{$module_url}/image/audio_waveform_image/{$_rt['_item_id']}/crop=false/xxlarge/\"},"; } // Trim last comma $data = rtrim($media, ","); header("Content-type: text/xml"); $response = "<root>\n"; $response .= "<data>\n"; $response .= "[{$data}]\n"; $response .= "</data>\n"; $response .= "</root>\n"; return $response; }
brian
@brian
12 years ago
10,149 posts
Remove the crop parameter from the image URL and see if that works.

Thanks!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
nate
@nate
12 years ago
917 posts
That did it. Thanks.
brian
@brian
12 years ago
10,149 posts
Natedogg265:
That did it. Thanks.

No problem! Thanks!

- Brian


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net

Tags