Forum

 

Please consider registering
guest

Log In Register

Register | Lost password?
Advanced Search:

— Forum Scope —



— Match —



— Forum Options —




Wildcard usage:
*  matches any number of characters    %  matches exactly one character

Minimum search word length is 3 characters - maximum search word length is 84 characters

Topic RSS
iTunes category and metadata can't be changed
26 August, 2010
7:54 pm
dannywithay
Member
Forum Posts: 5
Member Since:
26 August, 2010
Offline

Our podcast has incorrect meta information on the iTunes store — the author is listed as "Unknown" and the category is listed as "Buddhism". Additionally, the main podcast picture is blank, and will not update.

I've tried everything I can think of — even manually edited the podcast.php file in the sermonbrowser plugin folder. All of the incorrect info was missing from the podcast.php file (there was no author, the category was "religion and spirituality" with no subcategory — which I understand makes it default to "buddhism" as it's the first subcategory alphabetically, etc).

It's been several months, and nothing at all works. Is there anyone who might have some insight as to why it's not changing.

Our iTunes link is http://itunes.apple.com/us/pod…..d306939248

And the link on the website is http://www.citychurchftl.com/w…..-teaching/
under the "sermon audio" option.

Thanks in advance!

27 August, 2010
7:44 am
Tim_CNBC
Enthusiast
Forum Posts: 31
Member Since:
5 February, 2010
Offline

You need to make some changes to podcast.php

Here is the one from my church:

<rss xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd&quot; version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"&gt;
<channel>
<atom:link href="<?php echo sb_xml_entity_encode(sb_get_option('podcast_url')) ?>" rel="self" type="application/rss+xml" />
<title><?php echo sb_xml_entity_encode(get_bloginfo('name')) ?> Podcast</title>
<itunes:author>City North Baptist Church</itunes:author>
<description><?php echo sb_xml_entity_encode(get_bloginfo('description')) ?></description>
<link><?php echo sb_xml_entity_encode(get_bloginfo('home')) ?></link>
<language>en-us</language>
<copyright>© 2010 City North Baptist Church</copyright>
<image>
<url>http://www.citynorthbaptist.com/wp-content/uploads/sermons/images/cnbclogo.jpg</url&gt;
<title>City North Baptist Church</title>
<link>http://www.citynorthbaptist.com</link&gt;
</image>
<itunes:explicit>no</itunes:explicit>
<itunes:owner>
<itunes:name>City North Baptist Church</itunes:name>
<itunes:email>office@citynorthbaptist.com</itunes:email>
</itunes:owner>
<itunes:image href="http://www.citynorthbaptist.com/wp-content/uploads/sermons/images/cnbclogo.jpg&quot; />
<itunes:summary>City North Baptist – where people feel welcomed and challenged to get to know God better. Each week's morning and evening service is recorded and made available.</itunes:summary>
<lastBuildDate><?php sb_print_iso_date(isset($sermons[0]) ? $sermons[0]: time()) ?></lastBuildDate>
<pubDate><?php sb_print_iso_date(isset($sermons[0]) ? $sermons[0]: time()) ?></pubDate>
<generator>Wordpress Sermon Browser plugin <?php echo SB_CURRENT_VERSION ?> (http://www.4-14.org.uk/sermon-…..or&gt;
<docs>http://blogs.law.harvard.edu/tech/rss</docs>
<category>Religion &amp; Spirituality</category>
<!– iTunes Browse Podcasts Category –>
<itunes:category text="Religion &amp; Spirituality">
<!– iTunes Browse Podcasts Subcategory –>
<itunes:category text="Christianity"/>
</itunes:category>
<category>Christianity</category>
<itunes:keywords>City North Baptist Church, Murray Lean, Joe Khan, Dave Herron, Jesus, Church, brisbane, citynorthbaptist.com, jesus</itunes:keywords>
<?php
$mp3count = 0;
$accepted_extensions = array ('mp3', 'm4a', 'mp4', 'm4v','mov', 'wma', 'wmv');
foreach ($sermons as $sermon) {
if ($mp3count > 365)
break;
$media = sb_get_stuff($sermon);
if (is_array($media['Files']) | is_array($media['URLs'])) {
foreach ($media as $media_type => $media_names)
if (is_array($media_names) && $media_type != 'Code')
foreach ((array)$media_names as $media_name)
if (in_array(strtolower(substr($media_name, -3)), $accepted_extensions)) {
$mp3count++;
?>
<item>
<guid><?php echo sb_podcast_file_url($media_name, $media_type) ?></guid>
<title><?php echo sb_xml_entity_encode(stripslashes($sermon->title)) ?></title>
<link><?php echo sb_display_url().sb_query_char().'sermon_id='.$sermon->id ?></link>
<author><?php echo sb_xml_entity_encode(stripslashes($sermon->preacher)) ?></author>
<itunes:author><?php echo sb_xml_entity_encode(stripslashes($sermon->preacher)) ?></itunes:author>
<?php if ($sermon->description) { ?>
<description><![CDATA[<?php echo stripslashes($sermon->description) ?>]]></description>
<itunes:summary><![CDATA[<?php echo stripslashes($sermon->description) ?>]]></itunes:summary>
<?php } ?>
<enclosure url="<?php echo sb_podcast_file_url($media_name, $media_type).'" '.sb_media_size($media_name, $media_type).sb_mime_type($media_name); ?> />
<?php $duration = sb_mp3_duration($media_name, $media_type);
if ($duration) { ?>
<itunes:duration><?php echo $duration ?></itunes:duration>
<?php } ?>
<category><?php echo sb_xml_entity_encode(stripslashes($sermon->service)) ?></category>
<pubDate><?php sb_print_iso_date($sermon) ?></pubDate>
</item>
<?php
}
}
}
?>
</channel>
</rss>
27 August, 2010
5:59 pm
dannywithay
Member
Forum Posts: 5
Member Since:
26 August, 2010
Offline

Thanks @bookfreak — I'm afraid I still don't understand though. I'm pretty new to this.

Here's the contents of our podcast.php file — do you notice anything out of place?
Thanks again!

datetime));
} else
echo date('D, d M Y H:i:s O', strtotime($sermon));
}

//Prints size of file
function sb_media_size($media_name, $media_type) {
if ($media_type == 'URLs') {
if(ini_get('allow_url_fopen')) {
$headers = array_change_key_case(@get_headers($media_name, 1),CASE_LOWER);
$filesize = $headers['content-length'];
if ($filesize)
return "length="{$filesize}"";
}
} else
return 'length="'.@filesize(SB_ABSPATH.sb_get_option('upload_dir').$media_name).'"';
}

//Returns duration of .mp3 file
function sb_mp3_duration($media_name, $media_type) {
global $wpdb;
if (strtolower(substr($media_name, -3)) == 'mp3' && $media_type == 'Files') {
$duration = $wpdb->get_var("SELECT duration FROM {$wpdb->prefix}sb_stuff WHERE type = 'file' AND name = '{$media_name}'");
if ($duration)
return $duration;
else {
require_once('getid3/getid3.php');
$getID3 = new getID3;
$MediaFileInfo = $getID3->analyze(SB_ABSPATH.sb_get_option('upload_dir').$media_name);
$duration = isset($MediaFileInfo['playtime_string']) ? $MediaFileInfo['playtime_string'] : '';
$wpdb->query("UPDATE {$wpdb->prefix}sb_stuff SET duration = '{$duration}' WHERE type = 'file' AND name = '{$media_name}'");
return $duration;
}
}
}

//Replaces & with &
function sb_xml_entity_encode ($string) {
$string = str_replace('&amp;', '&', str_replace('&', '&', $string));
$string = str_replace('"', '"', $string);
$string = str_replace("'", ''', $string);
$string = str_replace('', '>', $string);
return $string;
}

// Convert filename to URL, perhaps with stats
// Stats have to be turned off for iTunes compatibility
function sb_podcast_file_url($media_name, $media_type) {
$user_agent = isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : '';
if (stripos($user_agent, 'itunes') !== FALSE | stripos($user_agent, 'FeedBurner') !== FALSE)
$stats = FALSE;
else
$stats = TRUE;
if ($media_type == 'URLs') {
if ($stats)
$media_name=sb_display_url().sb_query_char().'show&url='.URLencode($media_name);
} else {
if (!$stats)
$media_name=get_bloginfo('wpurl').sb_get_option('upload_dir').URLencode($media_name);
else
$media_name=sb_display_url().sb_query_char().'show&file_name='.URLencode($media_name);
}
return sb_xml_entity_encode($media_name);
}

// Returns correct MIME type
function sb_mime_type($media_name) {
require ('filetypes.php');
$extension = strtolower(substr($media_name, strrpos($media_name, '.') + 1));
if (array_key_exists ($extension, $filetypes))
return ' type="'.$filetypes[$extension]['content-type'].'"';
}

$sermons = sb_get_sermons(
array(
'title' => isset($_REQUEST['title']) ? $_REQUEST['title'] : '',
'preacher' => isset($_REQUEST['preacher']) ? $_REQUEST['preacher'] : '',
'date' => isset($_REQUEST['date']) ? $_REQUEST['date'] : '',
'enddate' => isset($_REQUEST['enddate']) ? $_REQUEST['enddate'] : '',
'series' => isset($_REQUEST['series']) ? $_REQUEST['series'] : '',
'service' => isset($_REQUEST['service']) ? $_REQUEST['service'] : '',
'book' => isset($_REQUEST['book']) ? $_REQUEST['book'] : '',
'tag' => isset($_REQUEST['stag']) ? $_REQUEST['stag'] : '',
),
array(
'by' => 'm.datetime',
'dir' => 'desc',
),
1,
1000000
);

if (function_exists('wp_timezone_override_offset'))
wp_timezone_override_offset();

header('Content-Type: application/rss+xml');
echo ''."n";
?>

<atom:link href="" rel="self" type="application/rss+xml" />

CityChurch Fort Lauderdale
For the benefit of the city – spiritually, socially, culturally

en-us
© CityChurch Fort Lauderdale
no

brad@citychurchftl.com

Wordpress Sermon Browser plugin (http://www.4-14.org.uk/sermon-browser)
http://blogs.law.harvard.edu/tech/rss
Religion & Spirituality

15)
break;
$media = sb_get_stuff($sermon);
if (is_array($media['Files']) | is_array($media['URLs'])) {
foreach ($media as $media_type => $media_names)
if (is_array($media_names) && $media_type != 'Code')
foreach ((array)$media_names as $media_name)
if (in_array(strtolower(substr($media_name, -3)), $accepted_extensions)) {
$mp3count++;
?>

id ?>
preacher)) ?>
description) { ?>
<![CDATA[description) ?>]]>
<![CDATA[description) ?>]]>

<enclosure url=" />

service)) ?>

28 August, 2010
12:29 am
Tim_CNBC
Enthusiast
Forum Posts: 31
Member Since:
5 February, 2010
Offline

Send it in a message to me, or use the code tags, as the important bits have been cut off by the forum!

28 August, 2010
3:44 am
dannywithay
Member
Forum Posts: 5
Member Since:
26 August, 2010
Offline

Here's a link to download the current version of the file.

http://dl.dropbox.com/u/314411…..odcast.php

Just to make sure that I'm sending (and editing) the correct file, this is from /wordpress/wp-content/plugins/sermon-browser/sb-includes/

Thanks again!

29 August, 2010
4:38 am
Tim_CNBC
Enthusiast
Forum Posts: 31
Member Since:
5 February, 2010
Offline

Yep that;s the right one!

I've edited your file for you, and changed the right stuff, have a quick scan to see if I've left any of my church info in it. But it should be fine to just drop on top of the old file.

Download: public.me.com/thebookfreak58

Tim

29 August, 2010
3:35 pm
dannywithay
Member
Forum Posts: 5
Member Since:
26 August, 2010
Offline

Thanks so much! I'll let you know how it goes!

1 September, 2010
8:19 pm
dannywithay
Member
Forum Posts: 5
Member Since:
26 August, 2010
Offline

It worked! We've been at this for months, and unable to figure it out. Thank you so much!

16 September, 2010
3:28 am
kangaman
New Member
Forum Posts: 1
Member Since:
16 September, 2010
Offline

Hi friends,

I have tried editing the podcast.php file a few times every time I touch something, the public feed rss link and itunes link come up blank.

Got any ideas what that is, been at it all day!!

Forum Timezone: Europe/London

Most Users Ever Online: 40

Currently Online: 0be1, sim
15 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

malpan - 2453

jogen - 2440

VanWatterson - 652

GeraldSebring - 364

LucasWoltman - 362

RandellFeenstra - 362

Member Stats:

There have been 7 guest posters

There are 1937 members

There are 1 moderators

There are 1 admins

Forum Stats:

Groups: 1

Forums: 2

Topics: 973

Posts: 3782

Newest Members: damianv, twinton, ellison13579, Daigh, mchunful, jesua

Moderators: Ben Miller (383 )

Administrators: Mark Barnes (425)

 

Comments are closed.