Jump to content

Recommended Posts

Hi,

 

Ive been building a few sites lately and they get very busy very fast and it puts alot of strain on my server due to excesive sql queries.  Ive noticed alot of sites use folders for things that i would use index.php?id= for. e.g i have a social network and peoples profiles are shown like mysite.com/index.php?user=bob. Would it be best to have the profiles as mysite.com/bob/ instead ? I was thinking this would mean less database queries and would be better for seo.

 

Am i right in thinking this or have i got it wrong ?

 

Thanks.

 

Link to comment
https://forums.phpfreaks.com/topic/208122-create-a-folder-and-file-or-use-id/
Share on other sites

oh right ok thanks, is there any other point to it apart from making the url's look tidier ?

 

No not really. The main reason people do it is for "SEO" reasons, which only goes so far and for profile information, it really will not matter too much. Now for blog posts it is good to create these "clean" / slug URLs from the title, but again not exactly necessary.

...excessive sql queries

 

Define excessive? What kind of problems do you have with the site?

 

Have you already optimized the queries you do have?

 

Unless you identify what is causing a problem, you cannot fix it because when you randomly attempt things, they won't address the root cause of the problem.

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.