*

Andrey

  • ****
  • 157 posts
Tell me how to remove the numbers at the end of the link
« on: November 20, 2018, 08:04:11 AM »
Hello,
Tell me how to remove the numbers at the end of the link, -c409276
when you choose a city
httрs://site.net/сity-c409276.
« Last Edit: November 20, 2018, 08:06:40 AM by Olime Olime »

*

MB Themes

Re: Tell me how to remove the numbers at the end of the link
« Reply #1 on: November 20, 2018, 03:38:06 PM »
@Olime
Check permalink setting in oc-admin
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Andrey

  • ****
  • 157 posts
Re: Tell me how to remove the numbers at the end of the link
« Reply #2 on: November 20, 2018, 04:55:39 PM »
 Thanks, yes it deletes the page id "-p {PAGE_ID}", but does not delete the city id
I found this code here on the forum and it suits me because I have a website for one region, but it displays cities along with id

<div class="location">
    <?php $i_count=0;
   while(osc_has_list_cities()) { ?>
   <a href="<?php echo osc_search_url(array('sCity' => osc_list_city_name()));?>"><?php echo osc_list_city_name() ; ?> <em>(<?php echo osc_list_city_items() ; ?>)</em></a>
   <?php $i_count++;
    if ($i_count==25) {
     break;
   } } ?>
</div>

How to display cities without id?
Thank you
« Last Edit: November 20, 2018, 04:57:24 PM by Olime Olime »

*

MB Themes

Re: Tell me how to remove the numbers at the end of the link
« Reply #3 on: November 20, 2018, 04:58:07 PM »
Aproach should be same, if not you need to check htaccess or core
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Andrey

  • ****
  • 157 posts
Re: Tell me how to remove the numbers at the end of the link
« Reply #4 on: November 20, 2018, 05:37:49 PM »
I have a standard .htaccess file.
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
RewriteEngine On
RewriteCond %{HTTP:X-Forwarded-Proto} !=https
RewriteRule .* https://%{SERVER_NAME}%{REQUEST_URI} [R=301,L]
</IfModule>
 Which file to search in the folder  /oc-includes/osclass/core

*

necunoscut

  • **
  • 5 posts
Re: Tell me how to remove the numbers at the end of the link
« Reply #5 on: January 09, 2023, 11:05:29 AM »
Anyone have a solution to remove id from city? I use osclass v8.02 and i also can't remove -r2684878 from categories.

*

MB Themes

Re: Tell me how to remove the numbers at the end of the link
« Reply #6 on: January 09, 2023, 01:03:29 PM »
Not doable for osclass now (or hardly achievable)
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots