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.12.x) »
  • Modules »
  • WBLingual - how to get rid of ugly URL
  • Print
Pages: [1]   Go Down

Author Topic: WBLingual - how to get rid of ugly URL  (Read 9571 times)

Offline CodeALot

  • Posts: 579
  • Gender: Male
WBLingual - how to get rid of ugly URL
« on: October 10, 2019, 02:16:28 PM »
When switching from one language to another (in this case, to English) the URL of the 'landing page' shows unwanted variables.   (?_wb=.... etc)
Code: [Select]
https://exampledomain.com/en/what-we-do/?_wb=en/what-we-do/

Am I overlooking something? Doing something wrong? :)  I don't want ugly URL's

WB 2.12.2 r379
WBLingual 2.0.2
ShortURL active
Logged

Offline hgs

  • WebsiteBaker Org e.V.
  • **
  • Posts: 1883
    • EFG MG
Re: WBLingual - how to get rid of ugly URL
« Reply #1 on: October 11, 2019, 08:38:06 AM »
I can confirm that,
https://domäne.org/de/gallery/?_wb=de/gallery/
AFTER another "click" in the language
https://domäne.org/de/ueber-uns/
it is then clean again, so only when changing the URL via the flags the URL is "wrong".
What do the developers say?
Logged
LG Harald

"Fange nie an, aufzuhören - höre nie auf, anzufangen." Marcus Tullius Cicero (106-43 v.Chr.)

"Never begin to stop - never stop beginning." Marcus Tullius Cicero (106-43 BC)

Offline dbs

  • Betatester
  • **
  • Posts: 8914
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: WBLingual - shorturl - how to get rid of ugly URL
« Reply #2 on: October 11, 2019, 09:04:23 AM »
Halrald, you have also shorturl active.
?_wb= is part of the htaccess code for shorturl.
Logged
https://onkel-franky.de

Offline astricia

  • Posts: 783
  • Gender: Female
    • netSchmiede24
Re: WBLingual - how to get rid of ugly URL
« Reply #3 on: October 11, 2019, 10:43:31 AM »
I had this problem on a website a few months ago and contacted Ruud about it, since he developped shorturl. He said this was caused by WebsiteBaker and he made "a small change in class.frontend.php" to prevent this happening. It worked - but unfortunately I don't know what exactly he changed....

I have attached the new class.frontend.php from that particular server (as txt - you need to rename it), so maybe this helps.

Astrid
Logged

Offline hgs

  • WebsiteBaker Org e.V.
  • **
  • Posts: 1883
    • EFG MG
Re: WBLingual - how to get rid of ugly URL
« Reply #4 on: October 11, 2019, 10:56:16 AM »
Quote from: dbs on October 11, 2019, 09:04:23 AM
Halrald, you have also shorturl active.
?_wb= is part of the htaccess code for shorturl.
Yes I have shortURL active
Logged
LG Harald

"Fange nie an, aufzuhören - höre nie auf, anzufangen." Marcus Tullius Cicero (106-43 v.Chr.)

"Never begin to stop - never stop beginning." Marcus Tullius Cicero (106-43 BC)

Offline dbs

  • Betatester
  • **
  • Posts: 8914
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: WBLingual - how to get rid of ugly URL
« Reply #5 on: October 11, 2019, 11:00:13 AM »
@astricia: thanks, to you and Ruud. Seems to work. File ist from 2.12.1 but the change is the same for 2.12.2
framework/class.frontend.php line 192. change this:
Code: [Select]
\header('Location: '.$this->page_link($this->page['link']).'?'.$_SERVER['QUERY_STRING']);to this
Code: [Select]
\header('Location: '.$this->page_link($this->page['link']));
Logged
https://onkel-franky.de

Offline hgs

  • WebsiteBaker Org e.V.
  • **
  • Posts: 1883
    • EFG MG
Re: WBLingual - how to get rid of ugly URL
« Reply #6 on: October 11, 2019, 11:12:28 AM »
 (Y)
Then, if there are no concerns from the developers, it should be transferred to the next version like this.
@dbs please create a ticket, because my internet is currently very slow on vacation.
Logged
LG Harald

"Fange nie an, aufzuhören - höre nie auf, anzufangen." Marcus Tullius Cicero (106-43 v.Chr.)

"Never begin to stop - never stop beginning." Marcus Tullius Cicero (106-43 BC)

Offline hgs

  • WebsiteBaker Org e.V.
  • **
  • Posts: 1883
    • EFG MG
Re: WBLingual - how to get rid of ugly URL
« Reply #7 on: October 11, 2019, 01:54:49 PM »
Tested on a bilingual site. Everything runs as it should. (Y)
Thanks to all
Logged
LG Harald

"Fange nie an, aufzuhören - höre nie auf, anzufangen." Marcus Tullius Cicero (106-43 v.Chr.)

"Never begin to stop - never stop beginning." Marcus Tullius Cicero (106-43 BC)

Offline CodeALot

  • Posts: 579
  • Gender: Male
Re: WBLingual - how to get rid of ugly URL
« Reply #8 on: October 11, 2019, 03:01:18 PM »
Works! Thanks all  8-)
Logged

Offline crnogorac081

  • Posts: 2161
  • Gender: Male
Wblingual
« Reply #9 on: October 11, 2019, 05:34:46 PM »
I would like to ask what is happening with link eg. http://wb_url/my_pretty_url/?page=2

Is _get('page') going to be dumped too if we apply the proposed fix :?

I would suggest to only remove _wb from $_SERVER['QUERY_STRING'] if exists..
« Last Edit: October 11, 2019, 06:35:24 PM by dbs »
Logged
Web developer

Offline dbs

  • Betatester
  • **
  • Posts: 8914
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: WBLingual - how to get rid of ugly URL
« Reply #10 on: October 12, 2019, 03:37:49 PM »
Dev Dietmar will take a look at the change. The way I see it, there will be another solution.
Logged
https://onkel-franky.de

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.12.x) »
  • Modules »
  • WBLingual - how to get rid of ugly URL
 

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