View Full Version : vBSEO Sitemap Addon
larina
10-26-2008, 04:46 PM
I took aproapes hack from this thread http://www.vbadvanced.com/forum/showthread.php?p=157947#post157947 (vBSEO Sitemap Addon for Dynamics) and changed it to use it with Links Directory.
You need vBSEO installed to use this hack. Furtheron spider friendly urls must be enabled inside the links directory options. The hack will take those spider friendly urls to the vBSEO sitemap.
Instructions:
1.
Open the attached file and replace the value 'http://yoursite.com/links/' in the script with your links URL (2x). Save the file and upload it to the folder forum/vbseo_sitemap/addons/
2.
Add a plugin from the Vbulletin's admincp with the details:
Add-on: vBulletin
Hook Location: init_startup
Title: FOR VBseo sitemap inclusion of Links URLs
Plugin PHP Code: $datastore_fetch[] = "'adv_links_cats'";
Active: Yes
3.
In the sitemap settings in Vbulletin's admincp under "Addon Generator Modules" put into the field: vbseo_sm_vba_links.php
Now you can test it by generating a sitemap manually.
larina
abroad
11-20-2008, 11:31 AM
I get this error message:
Warning: require_once(http://www.mydomain.com/includes/vba_links_functions.php) [function.require-once]: failed to open stream: no suitable wrapper could be found in /var/www/html/vbseo_sitemap/addons/vbseo_sm_vba_links.php on line 2
Fatal error: require_once() [function.require]: Failed opening required 'http://www.mydomain.com/includes/vba_links_functions.php' (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/html/vbseo_sitemap/addons/vbseo_sm_vba_links.php on line 2
(have replaced mydomain.com with my real domain name)
larina
11-20-2008, 02:02 PM
Hmm, the file is assuming, your domain-structure looks like that:
http://www.domain.com/forum/ (for the forum)
http://www.domain.com/forum/includes/ (for the place, where the file vba_links_functions.php is located)
http://www.domain.com/forum/vbseo_sitemap/addons/ (for the place, where the file vbseo_sm_vba_links.php is located)
http://www.domain.com/links/ (for links directory)
It seams your structure is somehow else?
Anyway, try to replace
includes/vba_links_functions.php (line 2 of the file vbseo_sm_vba_links.php )
with the whole server-path to vba_links_functions.php, whereever it is located at your server.
larina
abroad
11-20-2008, 03:03 PM
Have replaced it with:
require_once('/var/www/html/includes/vba_links_functions.php');
now I get a database error?!?
larina
11-21-2008, 07:56 AM
Are you using Links Directory version 3 ? And have you enabled spider friendly urls inside Links Directory?
And could you post the database error message here?
larina
abroad
11-21-2008, 08:05 AM
yes, version 3 and vba seo enabled.
There is no specific information in the error message...when I run the sitemap report it works well but at the very end I get this (only when I activate the plugin)
The MyDomain database has encountered a problem.
--------------------------------------------------------------------------------
Please try the following:
Load the page again by clicking the Refresh button in your web browser.
Open the www.mydomain.com home page, then try to open another page.
Click the Back button to try another link.
larina
11-21-2008, 08:14 AM
Hmm, somehow strange it does not work for you.
The database error message should be sent to the email-adress which is used inside the vbulletin config-file. I'd need to see the message to hopefully know what is going wrong.
larina
abroad
11-21-2008, 08:17 AM
Database error in vBulletin 3.7.3: Invalid SQL:SELECT * FROM vb_adv_links_categories WHERE private = 0; MySQL Error : Unknown column 'private' in 'where clause'Error Number : 1054Request Date : Friday, November 21st 2008 @ 12:02:48 PMError Date : Friday, November 21st 2008 @ 12:02:49 PMScript : http://www.mydomain.com/vbseo_sitemap/vbseo_sitemap.phpReferrer : http://www.mydomain.com/vbseo_sitemap/index.phpIP Address : 213.199.128.148Username : UnregisteredClassname : vB_DatabaseMySQL Version :
larina
11-21-2008, 08:46 AM
Sorry abroad, I really have no idea :(
It says, column "private" would be unknown, but this exists.
You could try to delete the part
WHERE private = 0
in the file.
But I assume something else is going wrong. I cannot see it from here :(
larina
lostcode
01-03-2009, 03:04 PM
Note: reborg (http://www.unix.com/members/39016.html) fixed this problem by changing the where clause on line 20:
from "private = 0" to "valid = 1"
Hello, our forum, www.unix.com , is also installed at the root directory.
We (also) get the following error when generating a site map:
[addon module] vbseo_sm_vba_links.php [6,841.9Kb mem used] [145s (+1s)]
Database Error Database error
The The UNIX and Linux Forums database has encountered a problem.
Please try the following:
* Load the page again by clicking the Refresh button in your web browser.
* Open the www.unix.com home page, then try to open another page.
* Click the Back button to try another link.
The www.unix.com forum technical staff have been notified of the error, though you may contact them if the problem persists.
We apologise for any inconvenience.
FIXED....
larina
01-03-2009, 05:53 PM
Thank you very much for the fix, lostcode. I just edited the file in post #1 and included the fix there.
Probably I was not facing this problem, as I have no private links :confused:
larina
lostcode
01-03-2009, 06:18 PM
You are welcome.
reborg recommends you also try:
valid = 1 AND active = 1
but we have not had time to verify that works too!
Cheers,
www.unix.com
larina
01-03-2009, 06:30 PM
valid = 1 AND active = 1
It works for me and I added it into the file in post #1.
Thanks again! :)
lostcode
01-04-2009, 12:49 PM
FYI, below are the database fields adv_link_categories (there is no "private" field):
catid title description parent haslinks styleid valid active catuserid allowusercats postcount linkcount parentlist password displayorder caticon lastlinkid lastlinktitle lastlinkusername lastlinkuserid lastlinkdateline lastpostid lastpostlinkid lastpostlinktitle lastpostuserid lastpostusername lastpostdateline options useroptions recipoptions newlinkemail newpostemail meta_description meta_keywords
www.unix.com
abroad
01-19-2009, 08:16 AM
DOes this work with the latest link Directory? I cant find my new links in the sitemap since I upgraded....
larina
01-19-2009, 08:24 AM
Yes it does work with the latest Links-version. Did you try to produce the sitemap manually?
For some reason vbSeo does not exactly the same when making the sitemap via cronjob and making it manually. Hopefully they will fix this. That's why I only make manual sitemaps and have turned off the cronjob.
abroad
01-20-2009, 03:16 PM
yes I was running the sitemap generator manually but if I search for a specific link in the sitemap file it does not appear there. There is only 1 link to the link directory
larina
01-20-2009, 03:37 PM
Have you taken over the fixes that lostcode gave us in this thread? I also have included them into the file in post #1.
It really should work. I just testet ... published a new link, ran the sitemap generator and the new link is inside my sitemap.
abroad
01-20-2009, 03:50 PM
ok now it works :)
larina
01-20-2009, 04:07 PM
I'm glad :)
abroad
01-20-2009, 04:08 PM
thanks a lot! Appreciate!
abroad
01-21-2009, 03:56 AM
just checked my sitemap file again this morning, and there were no links included...also run the sitemap generator manually....strange!!!
larina
01-21-2009, 07:40 AM
Have you turned off the cronjob inside admincp for the sitemap-generation?
vbSeo Sitemap also does not put the URLs from extra-urls.txt inside the sitemap if it is run via cronjob. But it works fine when it is run manually. And this is their very own script. For this someone could give me a fix, as you can read here http://www.vbseo.com/f2/i-cant-understand-how-extra-urls-txt-works-26033/
Same thing with this addon here, and also with the one for Dynamics. While the fix just mentioned does not help with those.
This would be a thing for vbSeo Support. I thought about asking them, but then I thought I just wait for the next vbSeo-Version, perhaps they will fix it anyway. It is a bug when running the sitemap via Cronjob brings total other results then when running it manually. Til it is fixed I just ONLY make manual sitemaps. That should solve your problem. Or open a ticket at vbSeo, if you don't want to wait for a fix.
abroad
01-21-2009, 08:52 AM
turned it off and run it manually...now they are back...funny :p
larina
01-21-2009, 10:15 AM
Yeah, just do it like this til there is a fix. I think it's no problem to do it manually from time to time.
abroad
01-21-2009, 01:14 PM
do you know which template (and variable in the title) I need to change so that only the name of the link appears in the search engines and not the name of my web site before as well?
larina
01-21-2009, 01:43 PM
Funny, that's what I just did some days ago.
There are lots of templates, just search for bbtitle and when you open such a template you find something like
$vboptions[bbtitle] -
inside the title-tag.
This you would need to remove if it should not be shown inside the titel of your pages.
I don't know if there is an easy way to do this for all templates that contain it. Under Styles & Templates there is a function, where you can let replace variables, perhaps try this. Or do some search at vbulletin.org. Myself I did it by hand for my page using this mod: http://www.vbulletin.org/forum/showthread.php?t=152931 so that at least I won't have to do it again after every vbulletin-update. If you chose to use this mod, I could put my title-changes into a xml-file, which you just would need to import then. But probably there are also other solutions.
ArowanaMan
02-21-2009, 01:31 AM
:eek:So Sweet thank you!!!
basmh
03-17-2009, 06:18 PM
hi,
I get this error message:
Warning: require_once(includes/vba_links_functions.php) [function.require-once]: failed to open stream: No such file or directory in /home/basmhnet/public_html/vb/vbseo_sitemap/addons/vbseo_sm_vba_links.php on line 2
Fatal error: require_once() [function.require]: Failed opening required 'includes/vba_links_functions.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/basmhnet/public_html/vb/vbseo_sitemap/addons/vbseo_sm_vba_links.php on line 2
How the edit this error message
Thanks
larina
03-18-2009, 01:24 PM
Hi basmh,
I don't know if I can help you. Are all url's set correctly in the file vbseo_sm_vba_links.php ?
You could try to change the line
require_once('includes/vba_links_functions.php');
to
require_once('/home/basmhnet/public_html/vb/includes/vba_links_functions.php');
Just an idea, what I would try if I had this problem. The script seems to look for the file vba_links_functions.php at the wrong place, but don't ask me why :confused:
larina
basmh
03-19-2009, 12:57 AM
hi,
Error message the problem is over
See the result became :D
[addon module] vbseo_sm_vba_links.php [3,507.8Kb mem used] [100s (+0s)]
[create sitemap file] filename: sitemap_9.xml.gz, number of urls: 8453 [3,334.4Kb mem used] [100s (+0s)]
[create sitemap index] filename: sitemap_index.xml.gz, number of sitemaps: 9 [3,336.4Kb mem used] [100s (+0s)]
Sitemap has been created. Click here to return [3,334.3Kb mem used] [101s (+1s)]
----------------
Now you can see the map :D
Click the link and saw the bottom of the page
http://www.basmh.net/vb/sitemap_9.xml.gz
You will see a folder ( links )
=============================
Just replaced the Annex vbseo_sm_vba_links.php
Just replaced the Annex
Modify the link to your site
basmh
jauburn
03-29-2009, 08:46 AM
How is this add-on different from the one of the same name that is now included with vBSEO?
larina
03-29-2009, 02:47 PM
jauburn, this add-on takes the spider friendly url's into the sitemap instead of the dynamic php-urls.
jauburn
03-29-2009, 02:56 PM
jauburn, this add-on takes the spider friendly url's into the sitemap instead of the dynamic php-urls.
Good news. Seems to be working.
Rozzz
07-05-2009, 02:21 PM
Can anyone confirm if this still works with 3.2.0?
Just wondering as it doesn't seem to add links to the sitemap for me.
Cheers,
Ross
Lima Bean
09-09-2009, 07:26 PM
Can anyone confirm if this still works with 3.2.0?
Just wondering as it doesn't seem to add links to the sitemap for me.
Cheers,
Ross
This hack does work and does add the seo friendly url's to the sitemap, however Google chokes on the sitemap and tosses off individual warnings for each url that the url not valid.
Worked great for me.. in fact when I first tried the plugin now included in vbseo, it generated an error - your version worked fine however :-)
jauburn
01-30-2010, 07:32 AM
Worked great for me.. in fact when I first tried the plugin now included in vbseo, it generated an error - your version worked fine however :-)
which plugin?
abroad
06-27-2010, 10:40 AM
does this work with link directory version 4?
mickknutson
08-01-2010, 10:01 AM
I do not get any links returned
[addon module] vbseo_sm_vba_links.php [11,572.1Kb mem used] [16s (+0s)]
I am using
VBseo 3.5.1
Sitemap 2.6
vb 4.0.5
and the latest Links.
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.