Advertisement:

Author Topic: Pretty URLs  (Read 2253500 times)

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 20,457
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Re: Pretty URLs
« Reply #7680 on: May 28, 2018, 01:31:04 PM »
It was mentioned a few pages back on the edits to be made
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Offline Xpresskonami

  • Jr. Member
  • **
  • Posts: 209
  • Gender: Male
    • @spyloaded_com on Twitter
Re: Pretty URLs
« Reply #7681 on: May 28, 2018, 03:22:57 PM »
It was mentioned a few pages back on the edits to be made

please can I have the link to the page please and please
Spyloadedng

Online GigaWatt

  • The Smiley Guy
  • Support Specialist
  • Sophist Member
  • *
  • Posts: 1,324
  • Gender: Male
    • Macedonian electronics forum
Re: Pretty URLs
« Reply #7682 on: May 28, 2018, 03:59:38 PM »
I think this might be the one.
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Offline Xpresskonami

  • Jr. Member
  • **
  • Posts: 209
  • Gender: Male
    • @spyloaded_com on Twitter
Re: Pretty URLs 1.0RC22 - Updated for SMF 2.0 RC3
« Reply #7683 on: May 28, 2018, 10:09:19 PM »
I have a problem with apostrophe / simple quote ( ' ) in the name of Boards : Firefox can open the page.

Boards without ' => ok
Boards with ' => not ok

I had this problem with the names of topics, Pretty URLs would write single apostrophes in the URLs.
They still worked, but that's not a good thing for indexing by search bots (which I could see in Google's Webmaster Tools) and not all browsers handel them well.

So we altered Sources/Subs-PrettyUrls.php like this:

Code: [Select]

'-' => array ('-', ' ', '.', ',', "'", '"'),
'_' => array ('_'),
'!' => array ('!'),
'~' => array ('~'),
'*' => array ('*'),
//"\x12" => array ("'", '"'),

And all is well.

I would think that this works for Board URLs as well (same principle).

This is exactly issues am talking about, what how can i set up this to get ride of the characters `()[]
Spyloadedng

Online GigaWatt

  • The Smiley Guy
  • Support Specialist
  • Sophist Member
  • *
  • Posts: 1,324
  • Gender: Male
    • Macedonian electronics forum
Re: Pretty URLs
« Reply #7684 on: May 29, 2018, 06:39:24 AM »
This is exactly issues am talking about, what how can i set up this to get ride of the characters `()[]

Maybe something like this ???.

Code: [Select]
'-' => array ('-', ' ', '.', ',', "'", '"','(',')','[',']'),
'_' => array ('_'),
'!' => array ('!'),
'~' => array ('~'),
'*' => array ('*'),
//"\x12" => array ("'", '"'),

Just to make things clear, I've never used this mod and I have no idea how it actually works (what's behind the hood), so I can't take responsibility if you apply these changes and something goes wrong.

Keep a backup of the original Subs-PrettyUrls.php in case you need to uninstall the mod, since it may not uninstall properly if you make these changes manually.
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Offline Xpresskonami

  • Jr. Member
  • **
  • Posts: 209
  • Gender: Male
    • @spyloaded_com on Twitter
Re: Pretty URLs
« Reply #7685 on: May 29, 2018, 01:12:51 PM »
It was mentioned a few pages back on the edits to be made

Come in here Vbgamer45 please. How can the characters be fix. ?? Many users needs this.
Spyloadedng

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 20,457
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Re: Pretty URLs
« Reply #7686 on: May 29, 2018, 01:23:37 PM »
I think you would take out '(',')',
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Offline Xpresskonami

  • Jr. Member
  • **
  • Posts: 209
  • Gender: Male
    • @spyloaded_com on Twitter
Re: Pretty URLs
« Reply #7687 on: May 29, 2018, 01:29:31 PM »
I think you would take out '(',')',

Yes.. but in what line will this be placed in the file. that's what I want to know
Spyloadedng

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 20,457
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Offline floyde

  • Jr. Member
  • **
  • Posts: 288
Re: Pretty URLs
« Reply #7689 on: May 29, 2018, 07:16:56 PM »
good night friends,

I installed this mod PrettyUrls1.1.6 so it is giving me this error below, can someone help me

I do not know! I use the new version 2.0.15 and gave 500 error.

Can someone help me ?
rewrite_module is enabled


Code: [Select]
Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@cxxxxxxxxxx.com.br to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

Offline Xpresskonami

  • Jr. Member
  • **
  • Posts: 209
  • Gender: Male
    • @spyloaded_com on Twitter
Re: Pretty URLs
« Reply #7690 on: May 29, 2018, 07:42:02 PM »
Update
1.1.6
!Fix for non latin characters in topics if mysql default-character-set is not utf8. This will fix wrong topics in urls like this site.tld/correct-board-title/t123/msg456 thanks to digger

I just install the new mod of the 1.6 and i see the character as been in the code , but it keep showing in my urls

Quote
   //   Do you know your ABCs?
   $characterHash = array (
      'a'   =>   array ('a', 'A', 'à', 'À', 'á', 'Á', 'â', 'Â', 'ã', 'Ã', 'ä', 'Ä', 'å', 'Å', 'ª', 'ą', 'Ą', 'а', 'А', 'ạ', 'Ạ', 'ả', 'Ả', 'Ầ', 'ầ', 'Ấ', 'ấ', 'Ậ', 'ậ', 'Ẩ', 'ẩ', 'Ẫ', 'ẫ', 'Ă', 'ă', 'Ắ', 'ắ', 'Ẵ', 'ẵ', 'Ặ', 'ặ', 'Ằ', 'ằ', 'Ẳ', 'ẳ', 'а', 'А'),
      'ae'   =>   array ('æ', 'Æ'),
      'b'   =>   array ('b', 'B', 'б', 'Б'),
      'c'   =>   array ('c', 'C', 'ç', 'Ç', 'ć', 'Ć', 'č', 'Č', 'ц', 'Ц'),
      'd'   =>   array ('d', 'D', 'Ð', 'đ', 'Đ', 'ď', 'Ď', 'д', 'Д'),
      'e'   =>   array ('e', 'E', 'è', 'È', 'é', 'É', 'ê', 'Ê', 'ë', 'Ë', 'ę', 'Ę', 'е', 'Е', 'ё', 'Ё', 'э', 'Э', 'Ẹ', 'ẹ', 'Ẻ', 'ẻ', 'Ẽ', 'ẽ', 'Ề', 'ề', 'Ế', 'ế', 'Ệ', 'ệ', 'Ể', 'ể', 'Ễ', 'ễ', 'ε', 'Ε', 'ě', 'Ě', 'е', 'Е'),
      'f'   =>   array ('f', 'F', 'ф', 'Ф'),
      'g'   =>   array ('g', 'G', 'ğ', 'Ğ', 'г', 'Г'),
      'h'   =>   array ('h', 'H', 'х', 'Х'),
      'i'   =>   array ('i', 'I', 'ì', 'Ì', 'í', 'Í', 'î', 'Î', 'ï', 'Ï', 'ı', 'İ', 'Ị', 'ị', 'Ỉ', 'ỉ', 'Ĩ', 'ĩ', 'Ι', 'ι', 'и', 'И'),
      'j'   =>   array ('j', 'J', 'й', 'Й'),
      'k'   =>   array ('k', 'K', 'к', 'К', 'κ', 'Κ', 'к', 'К'),
      'l'   =>   array ('l', 'L', 'ł', 'Ł', 'л', 'Л'),
      'm'   =>   array ('m', 'M', 'м', 'М', 'Μ', 'м', 'М'),
      'n'   =>   array ('n', 'N', 'ñ', 'Ñ', 'ń', 'Ń', 'ň', 'Ň', 'н', 'Н'),
      'o'   =>   array ('o', 'O', 'ò', 'Ò', 'ó', 'Ó', 'ô', 'Ô', 'õ', 'Õ', 'ö', 'Ö', 'ø', 'Ø', 'º', 'о', 'О', 'Ọ', 'ọ', 'Ỏ', 'ỏ', 'Ộ', 'ộ', 'Ố', 'ố', 'Ỗ', 'ỗ', 'Ồ', 'ồ', 'Ổ', 'ổ', 'Ơ', 'ơ', 'Ờ', 'ờ', 'Ớ', 'ớ', 'Ợ', 'ợ', 'Ở', 'ở', 'Ỡ', 'ỡ', 'ο', 'Ο', 'о', 'О'),
      'p'   =>   array ('p', 'P', 'п', 'П'),
      'q'   =>   array ('q', 'Q'),
      'r'   =>   array ('r', 'R', 'ř', 'Ř', 'р', 'Р'),
      's'   =>   array ('s', 'S', 'ş', 'Ş', 'ś', 'Ś', 'š', 'Š', 'с', 'С'),
      'ss'   =>   array ('ß'),
      't'   =>   array ('t', 'T', 'т', 'Т', 'τ', 'Τ', 'ţ', 'Ţ', 'ť', 'Ť', 'т', 'Т'),
      'u'   =>   array ('u', 'U', 'ù', 'Ù', 'ú', 'Ú', 'û', 'Û', 'ü', 'Ü', 'Ụ', 'ụ', 'Ủ', 'ủ', 'Ũ', 'ũ', 'Ư', 'ư', 'Ừ', 'ừ', 'Ứ', 'ứ', 'Ự', 'ự', 'Ử', 'ử', 'Ữ', 'ữ', 'ů', 'Ů', 'у', 'У'),
      'v'   =>   array ('v', 'V', 'в', 'В'),
      'w'   =>   array ('w', 'W'),
      'x'   =>   array ('x', 'X', '×'),
      'y'   =>   array ('y', 'Y', 'ý', 'Ý', 'ÿ', 'Ỳ', 'ỳ', 'Ỵ', 'ỵ', 'Ỷ', 'ỷ', 'Ỹ', 'ỹ', 'ы', 'Ы'),
      'z'   =>   array ('z', 'Z', 'ż', 'Ż', 'ź', 'Ź', 'ž', 'Ž', 'Ζ', 'з', 'З'),
      'jo' => array ('ё', 'Ё'),
      'zh' => array ('ж', 'Ж'),
      'ch' => array ('ч', 'Ч'),
      'sh' => array ('ш', 'Ш'),
      'sch' => array ('щ', 'Щ'),
      'eh' => array ('э', 'Э'),
      'yu' => array ('ю', 'Ю'),
      'ya' => array ('я', 'Я'),
      '' => array ('ъ', 'Ъ', 'ь', 'Ь', '?', '«', '»', ':', '&', '+', '@', '%', '^', '№', '#'),
      '-'   =>   array ('-', ' ', '.', ',', "'", '"'),
      '_'   =>   array ('_'),
      '!'   =>   array ('!'),
      '~'   =>   array ('~'),
      '*'   =>   array ('*'),
      "\x12"   =>   array ("'", '"'),
      '('   =>   array ('(', '{', '['),
      ')'   =>   array (')', '}', ']'),

      '$'   =>   array ('$'),
      '0'   =>   array ('0'),
      '1'   =>   array ('1', '¹'),
      '2'   =>   array ('2', '²'),
      '3'   =>   array ('3', '³'),
      '4'   =>   array ('4'),
      '5'   =>   array ('5'),
      '6'   =>   array ('6'),
      '7'   =>   array ('7'),
      '8'   =>   array ('8'),
      '9'   =>   array ('9'),
   );
Spyloadedng

Online GigaWatt

  • The Smiley Guy
  • Support Specialist
  • Sophist Member
  • *
  • Posts: 1,324
  • Gender: Male
    • Macedonian electronics forum
Re: Pretty URLs
« Reply #7691 on: May 29, 2018, 08:23:50 PM »
Try this.

Code: (Subs-PrettyUrls.php) [Select]
'-' => array ('-', ' ', '.', ',', "'", '"', '`', '(', ')', '[', ']'),
'_'   =>   array ('_'),
'!'   =>   array ('!'),
'~'   =>   array ('~'),
'*'   =>   array ('*'),
"\x12"   =>   array ("'", '"'),
// '('   =>   array ('(', '{', '['),
// ')'   =>   array (')', '}', ']'),
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Offline floyde

  • Jr. Member
  • **
  • Posts: 288
Re: Pretty URLs help
« Reply #7692 on: May 29, 2018, 08:30:58 PM »

good night friends,

I installed this mod PrettyUrls1.1.6 so it is giving me this error below, can someone help me

I do not know! I use the new version 2.0.15 and gave 500 error.

Can someone help me ?
rewrite_module is enabled


Code: [Select]
Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@cxxxxxxxxxx.com.br to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

Online Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 57,080
  • Gender: Male
    • Kindred-999 on GitHub
Re: Pretty URLs
« Reply #7693 on: May 29, 2018, 08:44:18 PM »
Floyde, you have made the same post three times. Please stop.  Your issue will be addressed when someone has a chance or an idea.  Until that time, you need to wait. multi-posting is rude.
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

Offline Xpresskonami

  • Jr. Member
  • **
  • Posts: 209
  • Gender: Male
    • @spyloaded_com on Twitter
Re: Pretty URLs
« Reply #7694 on: June 10, 2018, 04:52:33 AM »
Try this.

Code: (Subs-PrettyUrls.php) [Select]
'-' => array ('-', ' ', '.', ',', "'", '"', '`', '(', ')', '[', ']'),
'_'   =>   array ('_'),
'!'   =>   array ('!'),
'~'   =>   array ('~'),
'*'   =>   array ('*'),
"\x12"   =>   array ("'", '"'),
// '('   =>   array ('(', '{', '['),
// ')'   =>   array (')', '}', ']'),


This work for Me. thanks to the Developers in the forum.. The pretty-url is now fine and friendly

Spyloadedng

Offline mattizzy

  • Semi-Newbie
  • *
  • Posts: 74
  • Gender: Male
    • mattizzy.okeke on Facebook
    • @mattizzyo on Twitter
    • Xtremeloaded
Re: Pretty URLs
« Reply #7695 on: June 13, 2018, 11:31:59 PM »
I installed this mod. It is good. I commed you for that. Please I would love to know how to customize the Default PRETTY URL.

E.g
Changing
site.com/board/topic-name
to site.com/topic_id/topic-name

It would have been better if you included a way to do this in there.

Please thanks in advance.

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 20,457
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Re: Pretty URLs
« Reply #7696 on: June 13, 2018, 11:41:52 PM »
No easy way to do that requires a lot of of changes.
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Offline mattizzy

  • Semi-Newbie
  • *
  • Posts: 74
  • Gender: Male
    • mattizzy.okeke on Facebook
    • @mattizzyo on Twitter
    • Xtremeloaded
Re: Pretty URLs
« Reply #7697 on: June 13, 2018, 11:58:27 PM »
Thank you. I don't like the fact that the board name is showing. Can I easily remove the board from site.com/board/topic to site.com/custom_text/topic

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 20,457
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Re: Pretty URLs
« Reply #7698 on: June 14, 2018, 12:10:31 AM »
Not really no.
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Offline mattizzy

  • Semi-Newbie
  • *
  • Posts: 74
  • Gender: Male
    • mattizzy.okeke on Facebook
    • @mattizzyo on Twitter
    • Xtremeloaded
Re: Pretty URLs
« Reply #7699 on: June 17, 2018, 09:54:28 AM »
No easy way to do that requires a lot of of changes.

Please can you tell me how to change them.
To
site.com/topic_Id/topic-name

I'm moving to SMF and that's how my URL IS, I DON'T WANT ANY BROKEN LINK