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

Your donations will help to:

  • Pay for our dedicated server
  • Pay for domain registration
  • and much more!

You can donate by clicking on the button below.


  • Home
  • Help
  • Search
  • Login
  • Register

  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.13.x) »
  • General Help & Support »
  • PreCheck::sanitizeFilename diacritics
  • Print
Pages: [1]   Go Down

Author Topic: PreCheck::sanitizeFilename diacritics  (Read 3401 times)

Offline KEnik

  • Posts: 27
PreCheck::sanitizeFilename diacritics
« on: August 09, 2022, 09:27:35 PM »
Hi,
PreCheck::sanitizeFilename
Create wrong "link"s
From : Hvězdárna dětem opět od září v programu
       
Good old/pages/posts/hvezdne-leto-na-moninci-opet-s-hvezdarnou-zebrak-1481.php
Wrong New /pages/posts/Hv-zdne-leto-na-Mon-nci-op-t-s-Hv-zd-rnou-ebr-k-1481.php

       

modules/news/savePost.php:211
Code: [Select]
// Work-out what the link should be
    $newLink     = '/posts/'.PreCheck::sanitizeFilename($title).$oReg->PageSpacer.$iPostId;

Temporary fixed by old function ( maybe do not work well in all situation!):
Code: [Select]
public static function sanitizeFilename($val,$caseSensitive = false,$mPageStyle=null)
    {
        return page_filename($val);
}

Can I do pull request If I fix this by editing new function?

Logged

Offline dbs

  • Betatester
  • **
  • Posts: 8914
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: PreCheck::sanitizeFilename diacritics
« Reply #1 on: August 09, 2022, 10:42:34 PM »
The "wrong new" looks very bad. There is a fix needed i think.
You can also use in savePost.php the line 38 instead of 39. Is the same solution like yours.
Logged
https://onkel-franky.de

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.13.x) »
  • General Help & Support »
  • PreCheck::sanitizeFilename diacritics
 

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