vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Administrative and Maintenance Tools - vBSEO Google/Yahoo Sitemap Generator (https://vborg.vbsupport.ru/showthread.php?t=144730)

winstone 11-15-2007 09:42 PM

I'm using downloadsII mod on my site, so I included the downloads2.php file in sitemap, however I'm getting database error while generating the sitemap
Quote:

...
[addon module] vbseo_sm_downloads2.php [114s (+0s)]
Database Error Database error
can anyone please confirm that the addon is working with the latest version of downloadsII ?

Thanks

winstone 11-15-2007 11:06 PM

here is the working one for latest version of downloadsII:

replace vbseo_sm_downloads.php file content with:

PHP Code:

    $mods $db->query("SELECT id,name FROM " TABLE_PREFIX "dl_cats ORDER BY `id`");
    while (
$mod $db->fetch_array($mods))
    {    
        
$url $vbseo_vars['bburl'].'/downloads.php?do=cat&id='.$mod['id'];

        if(
VBSEO_ON)
            
$url vbseo_any_url($url);

          
vbseo_add_url($url1.0'''daily');
    }

    
$mods $db->query("SELECT id as fid FROM " TABLE_PREFIX "dl_files");
    while (
$mod $db->fetch_array($mods))
    {    
        
$url $vbseo_vars['bburl'].'/downloads.php?do=file&id='.$mod['fid'];

        if(
VBSEO_ON)
            
$url vbseo_any_url($url);
          
vbseo_add_url($url1.0'''daily');
    } 

changes in file are:

file_cats -> dl_cats
file_files -> dl_files
order by `order` -> order by `id` (not sure about this one but it's working)

and here is the code for vbseo_sm_download2.php with optimized links:
(should already have custom rewrite rules for downloadsII in vBSEO control panel)
PHP Code:

function ez_seo($ezlink){
    
$ezlink preg_replace('/[^a-z,0-9\.]/i''-'$ezlink);
    
$ezlink str_replace('---''-'$ezlink);
    
$ezlink str_replace('--''-'$ezlink);
    if (
$ezlink{0} == "-"$ezlink{0} = str_replace("-"""$ezlink{0});
    if (
substr($ezlink, -1) == "-"$ezlink substr($ezlink"", -1);
    return 
strtolower($ezlink);
}

    
$mods $db->query("SELECT id,name FROM " TABLE_PREFIX "dl_cats ORDER BY `id`") or die(mysql_error());
    while (
$mod $db->fetch_array($mods))
    {    
        
$url $vbseo_vars['bburl']."/downloads/".$mod['id']."/".ez_seo($mod['name'])."/";

        if(
VBSEO_ON)
            
$url vbseo_any_url($url);

          
vbseo_add_url($url1.0'''daily');
    }

    
$mods $db->query("SELECT ff.id as fid, ff.name as fname, fc.id as cid, fc.name as cname FROM " TABLE_PREFIX "dl_files ff LEFT JOIN dl_cats fc ON ff.category=fc.id") or die(mysql_error());
    while (
$mod $db->fetch_array($mods))
    {    
        
$url $vbseo_vars['bburl']."/downloads/".ez_seo($mod['cname'])."/".$mod['cid']."/".$mod['fid']."/".ez_seo($mod['fname'])."/";

        if(
VBSEO_ON)
            
$url vbseo_any_url($url);
          
vbseo_add_url($url1.0'''daily');
    } 

example output for file: TeSt - FiLe in category (HOT) SeCtION

category: domain.com/downloads/1/hot-section/
entry: domain.com/downloads/hot-section/1/123/test-file/

to change the format of output, just play with $url

Note: ez_seo function only works with English names & characters

PDM 11-16-2007 06:01 AM

why i can't view SE Bots Activity Log ?!! <<<< after Run Sitemap Generator

please guidance me

thanks

patch developer 11-19-2007 04:30 AM

i had this problem when i update to 3.6.8

Warning: fopen(/home/User/public_html/forums/vbseo_sitemap/data/downloads.dat): failed to open stream: Permission denied in /home/User/public_html/forums/vbseo_sitemap/vbseo_getsitemap.php on line 48

Warning: fwrite(): supplied argument is not a valid stream resource in /home/User/public_html/forums/vbseo_sitemap/vbseo_getsitemap.php on line 49


are there any solution for that error which i got when i'm pressing the link
http://MyWebSite.com/forums/sitemap_index.xml.gz

mpoorrajab 11-19-2007 05:33 AM

i see this error ...

Quote:

Fatal error: Call to undefined function vbseo_startup() in /home/daneshju/public_html/forum/vbseo_sitemap/vbseo_sitemap_functions.php on line 59

DarthCoder 11-19-2007 02:44 PM

When I install everything is fine, but when a user try to click on a link for example:
http://www.mysite.com/season-1/test-html
then it says document doesnt exist.

iojam 11-19-2007 06:20 PM

geevest.com,

are you able to open your sitemap index in browser?

winstone,
Quote:

Database Error Database error
can anyone please confirm that the addon is working with the latest version of downloadsII ?
what exactly is the db error message? (you can see it in page's html source or receive notification via email)

iojam 11-19-2007 06:24 PM

PDM,
Quote:

why i can't view SE Bots Activity Log ?!! <<<< after Run Sitemap Generator
this feature is only support for vBSEO-enabled boards, do you have vBSEO installed?


patch developer,

make sure that you defined permissions as described in installation instructions (0777 for vbseo_sitemap/data/ folder)


mpoorrajab,

vBSEO2.4.5 or greater is required, if you don't have it you should disable "Include vBSEO URLs" option.

snakeair 11-20-2007 12:27 AM

Thanks for the update. I just upgraded and works fine. :)

class101 11-20-2007 12:35 AM

cool!!!!!


All times are GMT. The time now is 09:10 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02318 seconds
  • Memory Usage 1,775KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (3)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete