Support » Fixing WordPress » Apache redirect for simple URL structure

  • I installed the “Photo Gallery” plug-in, and have published a gallery from this.

    The site currently is set to the default Permalinks setting. If I try to change this setting, existing content links do not work and i receive an error page. Reverting back to the Default, everything works.

    I want to distribute a simple “http://mysite.com/gallery” URL to friends, but that points to this published page / gallery.

    So i was thinking of placing an alias / redirect on the apache web server config to point “http://mysite.com/gallery” to the exact URL of the published gallery, which is something like “http://mysite.com/?page_id=62”

    Can this be done?

Viewing 1 replies (of 1 total)
  • First, if you cannot get Permalinks to work, you need to discuss with webhost why this is happening, the most likely reasons being:

    1. File permissions (WordPress cannot create the needed file).
    2. For an Apache Server, this file is .htaccess. You can manually create one and upload it.
    3. In the situation of your server env being Windows Server, then you need to create a web.config file. You can manually create one and upload it.

    This is all covered here (but review with host):

    https://codex.wordpress.org/Using_Permalinks

    Also, the plugin most likely wants you to be using Post Name as the Permalink structure (ask plugin dev.).

    Once you have the permalinks working, your page should show when your site vistors navigate to (sample url) site.com/slug/ which in your example above would be mysite.com/gallery/ . Note: WordPress should add the trailing slash, but it is best when sharing URL’s to include it.

Viewing 1 replies (of 1 total)
  • The topic ‘Apache redirect for simple URL structure’ is closed to new replies.