WebsiteBaker Logo
  • *
  • Templates
  • Help
  • Add-ons
  • Download
  • Home
*
Welcome, Guest. Please login or register.

Login with username, password and session length
 

News


WebsiteBaker 2.13.6 is now available!


Will it continue with WB? It goes on! | Geht es mit WB weiter? Es geht weiter!
https://forum.websitebaker.org/index.php/topic,32340.msg226702.html#msg226702


The forum email address board@websitebaker.org is working again
https://forum.websitebaker.org/index.php/topic,32358.0.html


R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WB
https://forum.websitebaker.org/index.php/topic,32355.0.html


* Support WebsiteBaker


  • Home
  • Help
  • Search
  • Login
  • Register

  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Droplets & Snippets »
  • The solution for Short (SEO Friendly) URL's
  • Print
Pages: 1 2 [3] 4 5 ... 7   Go Down

Author Topic: The solution for Short (SEO Friendly) URL's  (Read 184127 times)

Offline dbs

  • Betatester
  • **
  • Posts: 8914
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: The solution for Short (SEO Friendly) URL's
« Reply #50 on: February 24, 2012, 04:31:07 PM »
Quote
since you submitted google_sitemap.php you should renamed it that way to not cause error on GTools
i renamed file google_sitemap_shor turl.php to google_sitemap.php, because google knows it.
nothing to do with .htaccess.
right?
Logged
https://onkel-franky.de

Offline Xagone

  • Posts: 482
  • Gender: Male
  • Developper
    • Xagone Inc
Re: The solution for Short (SEO Friendly) URL's
« Reply #51 on: February 24, 2012, 04:43:35 PM »
nope

Did you indicate your sitemap in the robots.txt?
Logged
Xagone Inc. (formerly VotreEspace)
http://xagone.com/

Offline dbs

  • Betatester
  • **
  • Posts: 8914
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: The solution for Short (SEO Friendly) URL's
« Reply #52 on: February 24, 2012, 04:56:45 PM »
my "sitemap" is google_sitemap.php.
no entry in robots.txt for this.
Logged
https://onkel-franky.de

Offline Stefek

  • Posts: 6177
  • Gender: Male
  • ("ړ)
Re: The solution for Short (SEO Friendly) URL's
« Reply #53 on: March 15, 2012, 01:50:26 AM »
Ruud, Love you for this solution. Did I mention it already?
  :-P
Logged
"Gemeinsam schafft man mehr."

gemeinsam
1. mehreren Personen oder Dingen in gleicher Weise gehörend, eigen
2. in Gemeinschaft [unternommen, zu bewältigen]; zusammen, miteinander
#Duden

Offline Xagone

  • Posts: 482
  • Gender: Male
  • Developper
    • Xagone Inc
Re: The solution for Short (SEO Friendly) URL's
« Reply #54 on: May 03, 2012, 06:20:42 PM »
Just adding to the 404 solution,

after $page_id = get_seo_link($page);


you add 2 lines:
Code: [Select]
if (!$page_id) $page_id = *PAGE ID OF YOUR 404 PAGE*;
header("HTTP/1.0 404 Not Found");
i've added the header("HTTP/1.0 404 Not Found"); to be shure to send the 404 error header witch google and many other web tools use to check if the page exists. with the first method, witch is fine, the header returned was:
200 OK
but if you do not want this fail page to be refered to/indexed, you need to have
404 Not Found
in your http header
Logged
Xagone Inc. (formerly VotreEspace)
http://xagone.com/

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: The solution for Short (SEO Friendly) URL's
« Reply #55 on: May 03, 2012, 10:49:54 PM »
Good addition, but please implement it like:
Code: [Select]
if (!$page_id) {
  $page_id = *PAGE ID OF YOUR 404 PAGE*;
  header("HTTP/1.0 404 Not Found");
}
otherwise every page will have the status 404!
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

Offline Xagone

  • Posts: 482
  • Gender: Male
  • Developper
    • Xagone Inc
Re: The solution for Short (SEO Friendly) URL's
« Reply #56 on: May 03, 2012, 10:54:04 PM »
lol, you are SO right! thanks!

I ALMOST blew up my SEO
Logged
Xagone Inc. (formerly VotreEspace)
http://xagone.com/

Offline dana

  • Posts: 53
    • Webdesign by Dana
Re: The solution for Short (SEO Friendly) URL's
« Reply #57 on: May 10, 2012, 04:41:55 PM »
Hello Ruud, thank you so much for this snippet!

I have a question, is it possible to somehow work in a 301 redirect for URL's without a trailing slash, so as to avoid duplicate content? Like so:

Code: [Select]
www.domain.com/homeredirects to
Code: [Select]
www.domain.com/home/
I'd do it myself but I'm afraid of breaking it. :-D
Logged
Webdesign by Dana

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: The solution for Short (SEO Friendly) URL's
« Reply #58 on: May 10, 2012, 04:54:23 PM »
Do you really think Goole would see these two links as duplcate content???

The best solution would be to remove the extra / from the generated links (in the droplet). The extra / has no function, it is pure cosmetic.

change:
Code: (untested) [Select]
$wb_page_data = str_replace($linkstart.$link.$linkend, $newvalue.'/', $wb_page_data);into:
Code: (untested) [Select]
$wb_page_data = str_replace($linkstart.$link.$linkend, $newvalue, $wb_page_data);
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

Offline dana

  • Posts: 53
    • Webdesign by Dana
Re: The solution for Short (SEO Friendly) URL's
« Reply #59 on: May 10, 2012, 05:03:13 PM »
Well, both are somewhat okay, but I'm anal about these kinds of things. :D Thank you so much! :)
Logged
Webdesign by Dana

daydreamer

  • Guest
Re: The solution for Short (SEO Friendly) URL's
« Reply #60 on: June 18, 2012, 12:49:46 PM »
How would I get this to work with bakery module please?

Thanks
Logged

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: The solution for Short (SEO Friendly) URL's
« Reply #61 on: June 18, 2012, 01:00:59 PM »
Bakery does not use pages that are listed in the "pages" table.
The droplet will therefore not translate bakery links to a short version.

If you use the latest .htaccess (with redirecting deeplinked /pages/.....php pages to their short variant) you need to add a line to prevent bakery pages to be shortened.
instead of the block:
Code: [Select]
# If called directly - redirect to short url version
RewriteCond %{REQUEST_URI} pages
RewriteRule ^pages/(.*).php$ /$1/ [R=301,L]
use
Code: [Select]
# If called directly - redirect to short url version
RewriteCond %{REQUEST_URI} !pages/bakery/
RewriteCond %{REQUEST_URI} pages
RewriteRule ^pages/(.*).php$ /$1/ [R=301,L]
This way /pages/bakery/ pages will use the original urls.
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

daydreamer

  • Guest
Re: The solution for Short (SEO Friendly) URL's
« Reply #62 on: June 18, 2012, 01:57:46 PM »
Great thanks works fine, would be nice to see it work with other modules in the future  :-)
Logged

Offline dana

  • Posts: 53
    • Webdesign by Dana
Re: The solution for Short (SEO Friendly) URL's
« Reply #63 on: August 19, 2012, 08:55:13 PM »
I seem to be having problems with my multilanguage site. I've tried clicking around and this happened:

1) I clicked to switch to non-default english.
2) Then I clicked back to default language.
3) Then back to english version - this appeared in the address bar:

Code: [Select]
http://www.dana-svedova.cz/en/home/?_page=en/home/&lang=EN

When I click about in the english version, sometimes the address bar has that gibberish on multiple pages. When I hover over links, the format is the correct one, ie. blabla/en/home/

Does anyone have any idea what could be wrong?
Logged
Webdesign by Dana

Offline Xagone

  • Posts: 482
  • Gender: Male
  • Developper
    • Xagone Inc
Re: The solution for Short (SEO Friendly) URL's
« Reply #64 on: August 19, 2012, 10:41:24 PM »
I seen this on my multilingual websites too, it's normal because WB try to force a lang var and the htaccess repeat it the first time.

but it should not affect SEO.
Logged
Xagone Inc. (formerly VotreEspace)
http://xagone.com/

Offline dana

  • Posts: 53
    • Webdesign by Dana
Re: The solution for Short (SEO Friendly) URL's
« Reply #65 on: August 20, 2012, 05:03:52 PM »
Oh, ok. I thought it was something on my end. :) Thank you, Xagone! :)
Logged
Webdesign by Dana

Offline dbs

  • Betatester
  • **
  • Posts: 8914
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: The solution for Short (SEO Friendly) URL's
« Reply #66 on: August 21, 2012, 08:56:08 AM »
Hello,

is it possible?
I've made a multilingual-site, but use at the moment only one language (de).
My wish is: all pages have url without pages/de/ and the home-page shows only www.domain.de instead www.domain.de/de/home/

Can short-url do this?

dbs
« Last Edit: August 21, 2012, 09:01:16 AM by dbs »
Logged
https://onkel-franky.de

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: The solution for Short (SEO Friendly) URL's
« Reply #67 on: August 21, 2012, 10:32:48 AM »
You should be able to do that by chaging the droplet and the short.php.

For SEO reasons I would not advice this if you ever want to start using the /de/ in the future.
At that time you will need to rebuild your ranking all over again.
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

Offline dbs

  • Betatester
  • **
  • Posts: 8914
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: The solution for Short (SEO Friendly) URL's
« Reply #68 on: August 21, 2012, 10:36:08 AM »
You're right, it stays like it is. Thx.
Logged
https://onkel-franky.de

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: The solution for Short (SEO Friendly) URL's
« Reply #69 on: August 24, 2012, 03:25:58 PM »
Released a new version (2.3) today that fixes a problem with not translated links in WYSIWYG sections when using WB2.8.3.

See: http://short.allwww.nl/download
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

daydreamer

  • Guest
Re: The solution for Short (SEO Friendly) URL's
« Reply #70 on: September 21, 2012, 09:20:54 PM »
My pages change from

/pages/about.php

to
/about

but links are still /pages/about.php and not /about
Logged

Offline nibz

  • Posts: 684
  • Gender: Male
Re: The solution for Short (SEO Friendly) URL's
« Reply #71 on: September 21, 2012, 11:17:49 PM »
Dit you enclude the short url droplet in your template?!
Logged

daydreamer

  • Guest
Re: The solution for Short (SEO Friendly) URL's
« Reply #72 on: September 22, 2012, 12:00:05 AM »
No how do I add it in to the template index.php?
Thanks
Logged

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: The solution for Short (SEO Friendly) URL's
« Reply #73 on: September 22, 2012, 12:07:10 AM »
First create the droplet and paste the content of the file "dropletcode.txt" in there.
Name the new droplet something like "shorturl".
Somewhere in the html output of your template index.php (i.e. directly after the </html>) write [[shorturl]]

That should do it.
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

daydreamer

  • Guest
Re: The solution for Short (SEO Friendly) URL's
« Reply #74 on: September 22, 2012, 12:15:57 AM »
Great thanks wasn't aware you needed the droplet as well
Logged

  • Print
Pages: 1 2 [3] 4 5 ... 7   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Droplets & Snippets »
  • The solution for Short (SEO Friendly) URL's
 

  • SMF 2.0.19 | SMF © 2017, Simple Machines
  • XHTML
  • RSS
  • WAP2