Jump to content

SEO friendly knowledgebase links


jasonBV

Recommended Posts

Ok, got it working with a few kinks.

 

http://secure.pc-core.net/knowledgebase/13/75/How_do_I_login_to_my_VPS_Power_Panel_(VZPP).html

 

404 error.

http://secure.pc-core.net/knowledgebase/13/87/Are_iptable_modules_supported_on_vps_Can_I_install_APF_firewall.html

 

Works.

 

Why do some work and some not?

 

Also, the links like this:

 

Knowledgebase

You are here: Support > Knowledgebase > Managed VPS and Dedicated Hosting > Managed VPS

 

They are relative, how do I fix this to absolute values, they give 404 errors when you try to go back to the category.

 

I don't want to use SEO for the categories.

Link to comment
Share on other sites

  • 3 weeks later...
  • Replies 93
  • Created
  • Last Reply

Top Posters In This Topic

Hi! I'm using the default template and the link for category article is:

 

a href="knowledgebase.php?action=displaycat&catid={$kbcat.id}"

 

and for article is:

 

a href="knowledgebase.php?action=displayarticle&catid={$kbarticle.category}&id={$kbarticle.id}"

 

The default template don't get /knowledgebase/{$kbcat.id}/{$kbcat.name|...

 

How can I use the string replace to use with the default template?

 

Thanks

Link to comment
Share on other sites

Works perfectly!! Now I need solve the problem of replacement of accents by letter without the accent (eg "é" by "e" and, "á" by "a").

 

Thanks!

Try adding those characters to the "replace" action:

 

Original by jasonBV:

<a href="/knowledgebase/{$kbarticle.category}/{$kbarticle.id}/{$kbarticle.title|regex_replace:"/ /":"_"|regex_replace:"/[\?\'\.\,\!]/":""}.html">{$kbarticle.title}</a>

 

Edited to ignore á é í ó ú and ¿

<a href="/knowledgebase/{$kbarticle.category}/{$kbarticle.id}/{$kbarticle.title|regex_replace:"/ /":"_"|regex_replace:"/[\?\á\é\í\ó\ú\¿\.\,\!]/":""}.html">{$kbarticle.title}</a>

 

Hope this helps.

Link to comment
Share on other sites

anyone knows how to extend this to the announcements ?

 

thanks.

 

You should be able to use the same concept for the announcements as well by adding the entry to your .htaccess file and modifying your announcements template.

Link to comment
Share on other sites

My categories dont display nor do the pictures and when i click on the number (number of articles in cat) i get a 404 error and the correct SEO url. I can see my top articles but when i click on those i get the correct url but 404 error any thoughts please.

 

Thank you,

 

Cameron

Link to comment
Share on other sites

  • 2 weeks later...

I am going through my Hosting site and trying my best to SEO, I am not brilliant at it but I understand where its coming from.

 

I understand that google does not like duplicate content? So if I have two pages with identical content it wont look good on google.

 

So...

 

If a page links to one of the old URLs knowledgebase.php?action=displaycat&catid=2instead of the new URL knowledgebase/2/3/Storage.php

 

Could you explain how I could use .htaccess to

301 Moved permanently (redirect) to the new page?

 

Sorry if that is not explained too well. I find it hard to explain.

 

Any help would be greatly appreciated.

Link to comment
Share on other sites

We seem to be having trouble enabling this.

 

When we add:

RewriteEngine On
RewriteRule ^knowledgebase/([0-9]+)/([0-9]+)/[a-z0-9_-]+\.html$ /knowledgebase.php?action=displayarticle&catid=$1&i d=$2 [L,NC]
RewriteRule ^knowledgebase/([0-9]+)/([^/]*)$ /knowledgebase.php?action=displaycat&catid=$1 [L,NC]

 

to our .htaccess file, we get an Internal Server 500 error.

 

Any ideas as to why?

 

We have other rewrites in our .htaccess for our forums, so in theory, this should work much the same but it does not.

 

Cheers,

 

Dale Evans

Manager

Link to comment
Share on other sites

  • 3 weeks later...

This works great. Only problem is the other links on the page get mucked due to the /cat/id bit which is added to the url (from the dynamic url).

 

Is is possible to just remove these? so we have like whmcsinstall/knowledgebase/Article.html

 

Im a mod rewrite newbie really.

 

Cheers,

 

Ben

Link to comment
Share on other sites

My knowledgebase.tpl looks nothing like the ones you described so heres my offer.

 

I will give someone $25US via Paypal that will let me send them my knowledgebase.tpl have it modified so I have a SEO friendly KB. But with the $25 I also need to have all my other pages end with a .html instead of .php, like knowledgebase.php, support.php, contact.php announcements.php and all the others...you get my drift. If you can just explain this in very simple instructions, you can just do a few and i will do the rest. Thanks

 

 

PM me if interested.

Link to comment
Share on other sites

My knowledgebase.tpl looks nothing like the ones you described so heres my offer.

 

I will give someone $25US via Paypal that will let me send them my knowledgebase.tpl have it modified so I have a SEO friendly KB. But with the $25 I also need to have all my other pages end with a .html instead of .php, like knowledgebase.php, support.php, contact.php announcements.php and all the others...you get my drift. If you can just explain this in very simple instructions, you can just do a few and i will do the rest. Thanks

 

 

PM me if interested.

 

i'll 2nd this request

Link to comment
Share on other sites

Hi

i put htaccess into www/ (is a cpanel server)

i change link into .tpl fils

All work but i've a big problem with CSS and all Customer Are

 

When i visit knowledgebase all relative link are with

knowledgebase/CAT/ID/link.php

 

example

 

without mod_rewrite i can

domain/cart.php

 

with mod_rewrite

knowledgebase/cat/id/cart.php

 

where i wrong?

 

i must change all link into .tpl ?? from (example) /ticket.php /cart.php to domain/cart.php ?

THANKSSS

Link to comment
Share on other sites

  • 2 weeks later...

I have tried and tried, but cannot get this working.

 

The URL rewrite works fine, but the pages that are being rewritten are missing CSS and images.

 

I tried replacing the / with _ like minadreapta said, but when I do that, it gives me a 404 document not found.

 

Any ideas?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated