Go Back   BuyScripts Forums > vShare YouTube Clone > vShare Modifications

Reply
 
LinkBack Thread Tools Display Modes
  #21 (permalink)  
Old 05-18-2009, 11:01 AM
Senior Member
 
Join Date: May 2007
Location: Planet Earth
Posts: 1,449
Default

Well, it is *probably* due to the error in my xml tag. I just took it out and am resubmitting to google....the only other problem after that is the www part (I hope).
__________________

Reply With Quote
  #22 (permalink)  
Old 05-18-2009, 11:05 AM
Member
 
Join Date: May 2009
Posts: 58
Default

If you dont give up you wont fail.
Reply With Quote
  #23 (permalink)  
Old 05-18-2009, 11:07 AM
Senior Member
 
Join Date: May 2007
Location: Planet Earth
Posts: 1,449
Default

If this doesn't pan out I'll find the original sitemap posted for 2.6 in the forums (hopefully it didn't get deleted for being old) and change the reference to the database to reflect the changes in 2.7 since that old one always worked for me in the past (for 2.6) and see what the difference is between that one and yours.
__________________

Reply With Quote
  #24 (permalink)  
Old 05-18-2009, 11:29 AM
Junior Member
 
Join Date: May 2009
Posts: 9
Default

Here it is:

http://www.ikhebdexfactor.nl/sitemap.php

Quote:
Originally Posted by carefree2 View Post
Post a link to your sitemap.php and ill have a look at it
Reply With Quote
  #25 (permalink)  
Old 05-18-2009, 11:32 AM
Senior Member
 
Join Date: May 2007
Location: Planet Earth
Posts: 1,449
Default

I have a question, in the original for 2.6 it has this:

Code:
echo "<?xml version='1.0' encoding='iso-8859-1'?>";
echo "<urlset xmlns='http://www.sitemaps.org/schemas/sitemap/0.9' xmlns:video='http://www.google.com/schemas/sitemap-video/1.0'>";
Would the reference to the fact that this is for videos be of any importance?
__________________

Reply With Quote
  #26 (permalink)  
Old 05-18-2009, 11:51 AM
Junior Member
 
Join Date: May 2009
Posts: 9
Default

I will try this

Thanks for keeping this updated!!
Reply With Quote
  #27 (permalink)  
Old 05-18-2009, 11:54 AM
Junior Member
 
Join Date: May 2009
Posts: 9
Default

Pimp it works now! great many thanks
Reply With Quote
  #28 (permalink)  
Old 05-18-2009, 12:07 PM
Senior Member
 
Join Date: May 2007
Location: Planet Earth
Posts: 1,449
Default

Oh good! I couldn't get carefree's code to work with 2.7 so I took RAMMSTEINS code, which looks like this and it works for me in 2.7:

Code:
<?php
header("content-type:text/xml;charset=utf-8");

require 'include/config.php';
$url = VSHARE_URL;

echo "<?xml version='1.0' encoding='iso-8859-1'?>";
echo "<urlset xmlns='http://www.sitemaps.org/schemas/sitemap/0.9' xmlns:video='http://www.google.com/schemas/sitemap-video/1.0'>";

# channels
$sql = "SELECT channel_id, channel_name FROM `channels`
                ORDER BY `channel_sort_order` ASC";
$res = mysql_query($sql,$conn)
or die( "Error: " . mysql_error() );
while ($info = mysql_fetch_row($res)) {
srand ((double) microtime( )*1000000);
$random_number = rand(6,7);
$SefUrl=strtolower(preg_replace("/[^a-zA-Z0-9]+/","_", $info[1]));

echo "<url><loc>$url/channel/".$info[0]."/".$info[1]."/</loc>";
echo "<changefreq>monthly</changefreq>";
echo "<priority>0.$random_number</priority>";
echo "</url>";
}

# videos
$sql = "SELECT video_id, video_title, video_add_date FROM `videos` WHERE
           `video_active`='1' AND
           `video_approve`='1' AND
           `video_type`='public'
            ORDER BY `video_id` DESC";
$res = mysql_query($sql,$conn)
or die( "Error: " . mysql_error() );
while ($info = mysql_fetch_row($res)) {
srand ((double) microtime( )*1000000);
$random_number = rand(4,6);
$SefUrl=strtolower(preg_replace("/[^a-zA-Z0-9]+/","-", $info[1]));

echo "<url><loc>$url/view/".$info[0]."/".$SefUrl."/</loc>";
echo "<lastmod>".$info[2]."</lastmod><changefreq>monthly</changefreq>";
echo "<priority>0.$random_number</priority>";
echo "</url>";
}

# tags
$sql = "SELECT tag FROM `tags` WHERE
           `active`='1' AND
           `tag_count` > 0
            ORDER BY `tag_count` DESC";

$res = mysql_query($sql,$conn)
or die( "Error: " . mysql_error() );
while ($info = mysql_fetch_row($res)) {
srand ((double) microtime( )*1000000);
$random_number = rand(1,4);
$SefUrl=strtolower(preg_replace("/[^a-zA-Z0-9]+/","_", $info[1]));

echo "<url><loc>$url/tag/".$info[0]."/</loc>";
echo "<changefreq>monthly</changefreq>";
echo "<priority>0.$random_number</priority>";
echo "</url>";
}

mysql_close($conn);

echo "</urlset>";
?>
The only thing I had to do to my site was remove the ampersand (&) from my channel titles in vShare which caused the same problem as it did with 2.6. I'm weeding thru this to see what I did last time to fix it, but for now I just took that out of my channel titles in vShare admin panel.
__________________


Last edited by grynmoors; 05-18-2009 at 12:09 PM.
Reply With Quote
  #29 (permalink)  
Old 05-18-2009, 12:30 PM
Senior Member
 
Join Date: May 2007
Location: Planet Earth
Posts: 1,449
Default

Quote:
Originally Posted by ikhebdexfactor View Post
Pimp it works now! great many thanks
Yours is doing the same thing that mine was doing, it's creating a "list" of all the videos on the site in one long string without a break, antd it's not actually linking them. Try RAMMSTEINS code.
__________________

Reply With Quote
  #30 (permalink)  
Old 05-18-2009, 12:37 PM
Junior Member
 
Join Date: May 2009
Posts: 9
Default

changed the code to RAMMSTEINS code works great

Quote:
Originally Posted by grynmoors View Post
Yours is doing the same thing that mine was doing, it's creating a "list" of all the videos on the site in one long string without a break, antd it's not actually linking them. Try RAMMSTEINS code.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[addon] Google Sitemap Generator RAMMSTEIN Template Modifications 5 11-07-2008 03:25 AM
Google Video Sitemap CliftonH Web Site Promotion 6 08-10-2008 10:20 PM
Sitemap autodafe Feature Requests 23 02-28-2008 11:08 PM
New Google video sitemap !!! chadon Feature Requests 2 12-21-2007 05:48 PM
Sitemap Generator for vShare autodafe General Discussions 14 10-24-2007 03:50 PM


All times are GMT. The time now is 02:34 PM.


Powered by vBulletin. Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
SEO by vBSEO