collapse

* Simple Portal Archived Forum

This is an Archive Forum.

The content in this forum may be out-of-date or have been superseded by newer information, and links in forum pages to other sites may not work.
This forum contains archives for future reference.

Visit our thread at Simple Machines Forum for current support.

SMF 2.1 users: EhPortal is a ported version of Simple Portal specifically designed for the SMF 2.1 branch.
Please visit web-develop.ca to download EhPortal and for its support.

* User Info

 
 
Welcome, Guest. Please login or register.

* Who's Online

  • Dot Guests: 502
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.

* Shoutbox

Refresh History
  • Shoutbox is not for support!
  • {OCS}MasterSeal: Yup, Still adore SP
    April 21, 2019, 07:08:06 PM
  • {OCS}MasterSeal: STILL love SP :)
    November 24, 2018, 05:05:50 AM
  • ♦ Ninja ZX-10RR ♦: <3 aegersz
    September 13, 2018, 03:36:09 PM
  • aegersz: I STILL <3 LOVE SimplePortal
    September 13, 2018, 07:11:39 AM
  • aegersz: o LOVE you guys - Simple Portal rocks !
    May 09, 2018, 05:18:59 AM
  • Chen Zhen: our apologies for the site being down.. please read server issues topic
    March 22, 2018, 05:32:38 AM
  • {OCS}MasterSeal: LOL PLEASE forget I just posted that. I found the answer in my own dang post back in 2015. lol sorry!
    July 04, 2017, 10:47:55 PM
  • {OCS}MasterSeal: I know this SB isnt' for support, but I just have a general question. Who would I contact to find out where SP stores its block info? Is it DB driven or files? I searched the site but came up with nothing. probably my fault any insight is appreciated.
    July 04, 2017, 10:43:36 PM
  • ♦ Ninja ZX-10RR ♦: Excuse me but what does Simpleportal have to deal with that?
    February 05, 2017, 08:21:14 PM
  • WhiteEagle: of course IMHO that site appears to be dead :(
    February 04, 2017, 01:08:05 PM
  • WhiteEagle: If I can get that, then I'll use it for that site...
    February 04, 2017, 01:07:35 PM
  • WhiteEagle: decided to not use SMF for any projects, unless I can get a copy of the premium version of the fanfiction archive plugin
    February 04, 2017, 01:06:54 PM
  • expertdecisions: cloudflare
    January 28, 2017, 08:01:47 AM
  • aegersz: SM release 2.0.13 !
    January 12, 2017, 06:00:13 AM
  • raffo: Tks Emanuele, even if I didn't understand the fix :D
    November 07, 2016, 02:01:20 AM
  • emanuele: [link]
    November 01, 2016, 12:43:50 PM
  • emanuele: raffo: the English support board is a good place. ;)
    November 01, 2016, 12:43:38 PM
  • raffo: Where can I find the fix for the shoutbox?
    November 01, 2016, 05:06:09 AM
  • {OCS}MasterSeal: To the SP team, I make a point to come here and thank you as much as possible for your work.  so again, THANK YOU!
    October 28, 2016, 10:38:05 AM
  • emanuele: That's indeed funny, the limit is present only in the patch and not the full install.
    October 22, 2016, 06:14:58 PM

* Recent Posts

Adding Forums Button to Nav bar by jirapon
[August 01, 2019, 09:07:12 AM]


Re: Board Icons by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 04:03:41 PM]


MOVED: Czech translation???? by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 03:04:51 PM]


Board Icons by jirapon
[July 30, 2019, 07:28:44 AM]


Re: Thankyou Simpleportal, by ♦ Ninja ZX-10RR ♦
[July 29, 2019, 09:41:29 AM]

NEED HELP? If you're looking for support with Simple Portal, look no further than the Support Board!

Author Topic: Can't we use hyphen(-) in Page ID?  (Read 8516 times)

0 Members and 1 Guest are viewing this topic.

Offline srinib

  • Semi Newbie
  • *
  • Posts: 18
    • SchoolGram
  • SMF Version: 2.0.2
  • SP Version: 2.3.5
Can't we use hyphen(-) in Page ID?
« on: April 03, 2013, 03:35:10 AM »
I am having problem with the "Page ID".
I want to name Page ID = Good-Key-Words. But if won't take that way.

We get a message saying,
Quote
Sorry, there are invalid characters in the page ID. Page ID's can only contain letters, numbers and underscores.

I know we can substitute underscores for that.
But i read in an SEO book that search engines just ignore the pages with underscores . They don't mean this link won't be indexed. But it says the key words are not considered.

This is what it says,
Bad practice: don't use underscores
http://www.MyDomain.com/index.php?page=Good_Key_Words


Good practice: use hyphen(-)
http://www.MyDomain.com/index.php?page=Good-Key-Words


So, is there something we can do to accomodate hyphen(-) also?

Offline andy

  • On Leave
  • *
  • Posts: 861
  • Gender: Male
    • Outdoor Club Japan (OCJ) アウトドア・クラブ・ジャパン
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
  • Elkarte Version: None
Re: Can't we use hyphen(-) in Page ID?
« Reply #1 on: April 03, 2013, 01:26:47 PM »
Yes '_' works fine ...

I havent test hyphen.


I do not think it makes any difference than using hyphen. On SMF there is a lot of debate about keywords and SEO but most senior people there agree that for search engines the most important thing is the 'content'. This is what they use for indexing. Sites have lots of fake keywords to attract people but smart search engines use the content - that will keep their users happy if they return correct search results.

I would not worry about it - my pages come up fine on search results.
Everyone is a volunteer here so please try and make a small donation to keep the Simple Portal website running


Offline srinib

  • Semi Newbie
  • *
  • Posts: 18
    • SchoolGram
  • SMF Version: 2.0.2
  • SP Version: 2.3.5
Re: Can't we use hyphen(-) in Page ID?
« Reply #2 on: April 04, 2013, 03:25:28 PM »
You are right. For search engines, content is the king. But apart from that there are many other factors which contribute to the lift. And the naming of these pages is one of them.

igirisjin, I think you know better than me about these stuff. I see your site has a good PR.  ;) Your site looks great.

Offline srinib

  • Semi Newbie
  • *
  • Posts: 18
    • SchoolGram
  • SMF Version: 2.0.2
  • SP Version: 2.3.5
Re: Can't we use hyphen(-) in Page ID?
« Reply #3 on: April 05, 2013, 02:44:42 AM »
Any idea where this Page ID information is stored(i mean in which table)?

Offline andy

  • On Leave
  • *
  • Posts: 861
  • Gender: Male
    • Outdoor Club Japan (OCJ) アウトドア・クラブ・ジャパン
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
  • Elkarte Version: None
Re: Can't we use hyphen(-) in Page ID?
« Reply #4 on: April 05, 2013, 04:19:01 PM »
Quote
Any idea where this Page ID information is stored(i mean in which table)?
I dont know, but one easy way to find it is maybe to give a page a unique name (not number), save and then download your database and search it for that unique name.
Everyone is a volunteer here so please try and make a small donation to keep the Simple Portal website running


Offline srinib

  • Semi Newbie
  • *
  • Posts: 18
    • SchoolGram
  • SMF Version: 2.0.2
  • SP Version: 2.3.5
Re: Can't we use hyphen(-) in Page ID?
« Reply #5 on: April 07, 2013, 01:46:52 AM »
Can Simple Portal Team please consider this "hyphen(-) in Page ID" in their next version? It is really important to me and i guess it will be helpfull for others too.

Offline andy

  • On Leave
  • *
  • Posts: 861
  • Gender: Male
    • Outdoor Club Japan (OCJ) アウトドア・クラブ・ジャパン
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
  • Elkarte Version: None
Re: Can't we use hyphen(-) in Page ID?
« Reply #6 on: April 08, 2013, 02:30:43 AM »
You can make a feature request for that.

http://simpleportal.net/index.php?board=9.0



Everyone is a volunteer here so please try and make a small donation to keep the Simple Portal website running


Offline ccbtimewiz

  • Hero Member
  • *****
  • Posts: 2185
  • Gender: Male
  • $("div.content:dd").hide();
  • SMF Version: None
  • SP Version: None
  • Elkarte Version: None
  • EhPortal Version: None
Re: Can't we use hyphen(-) in Page ID?
« Reply #7 on: June 10, 2013, 11:43:03 PM »
The hyphen is failing because it makes a check inside a file go false and triggers a fatal_lang_error

It's located in PortalAdminPages.php here:

Code: [Select]
if (preg_match('~[^A-Za-z0-9_]+~', $_POST['namespace']) != 0)
fatal_lang_error('sp_error_page_namespace_invalid_chars', false);

A solution would be to completely remove the check entirely like so:

Code: [Select]
if (empty($_POST['namespace']))
fatal_lang_error('sp_error_page_namespace_invalid_chars', false);

This will allow you to post any character you want (besides blank). Of course this can create serious problems, just make sure you know what you're doing by removing this.

Alternatively if you want to keep the restriction and just include a hyphen in the allowed characters, perhaps edit the statement like so:

Code: [Select]
if (preg_match('~[^A-Za-z0-9_\-]+~', $_POST['namespace']) != 0)
fatal_lang_error('sp_error_page_namespace_invalid_chars', false);

However removing the check entirely will give you vast more opportunity to play with what you want...
« Last Edit: June 11, 2013, 07:30:05 PM by Bullet »

Offline FroschLee

  • Just Registered
  • Posts: 1
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Can't we use hyphen(-) in Page ID?
« Reply #8 on: October 08, 2015, 09:33:13 AM »
The hyphen is failing because it makes a check inside a file go false and triggers a fatal_lang_error

It's located in PortalAdminPages.php here:

Code: [Select]
if (preg_match('~[^A-Za-z0-9_]+~', $_POST['namespace']) != 0)
fatal_lang_error('sp_error_page_namespace_invalid_chars', false);

A solution would be to completely remove the check entirely like so:

Code: [Select]
if (empty($_POST['namespace']))
fatal_lang_error('sp_error_page_namespace_invalid_chars', false);

This will allow you to post any character you want (besides blank). Of course this can create serious problems, just make sure you know what you're doing by removing this.

Alternatively if you want to keep the restriction and just include a hyphen in the allowed characters, perhaps edit the statement like so:

Code: [Select]
if (preg_match('~[^A-Za-z0-9_\-]+~', $_POST['namespace']) != 0)
fatal_lang_error('sp_error_page_namespace_invalid_chars', false);

However removing the check entirely will give you vast more opportunity to play with what you want...

İ try this and working fine.

Code: [Select]
if (preg_match('~[^A-Za-z0-9_/\-]+~', $_POST['namespace']) != 0)
fatal_lang_error('sp_error_page_namespace_invalid_chars', false);

my page id is looking like = > deneme/deneme
But if i open prettyurls this is not working. How can i fix it for work with prettyurl?

Offline ♦ Ninja ZX-10RR ♦

  • Spammer Hammer
  • Support
  • *
  • Posts: 1193
  • Gender: Male
  • Sniper Legends
    • Virtual Interactive Games Entertainment™
  • SMF Version: 2.0.13
  • SP Version: 2.3.6
  • Elkarte Version: 1.0.6
Re: Can't we use hyphen(-) in Page ID?
« Reply #9 on: October 08, 2015, 07:28:39 PM »
FroschLee,

Hi and welcome to SimplePortal!
Unfortunately PrettyUrls is very well known to be the cause of random and odd issues, without even really boosting the SEO - ref: http://www.simplemachines.org/community/index.php?topic=427913.0
So your best option is to try asking the mod author, since it's not a SimplePortal problem.

Regards
Have you tried SimplePortal Documentation before asking? ;)
F.A.Q.  English Support  |  Blocks Support
Fancy Feature idea ?!  |  Blocks Requests
Themes & Graphics

? My job! ?No PMs for support unless it's a paid request. Thank you! :)#OpIsis