Neuigkeiten
  • Die modified eCommerce Shopsoftware ist kostenlos, aber nicht umsonst.
    Spenden
  • Damit wir die modified eCommerce Shopsoftware auch zukünftig kostenlos anbieten können:
    Spenden
  • Thema: Probleme Suchmaschinenfreundliche URLs und verlinkung

    kklein87

    • Neu im Forum
    • Beiträge: 4
    Gute Tag,

    ich habe schon etliche foren einträge gelesen aber ich bin wohl zu blöde es zu verstehen...

    1. besitze ich 2 domains. die Hauptdomain ist verbunden mit dem FTP auf dem mein shop liegt die andere soll dort hinführen. Ich habe somit die domain www.abc.de weitergeleitet auf www.xyz.de/shop leider wird mir dann in der URL anzeige auch www.xyz.de/shop angezeigt. Wie kann man es ändern das mir. www.abc.de in der URL Leiste angezeigt wird?

    2. sobald ich die Suchmaschinenfreundliche URLs aktiviere komme ich nur noch auf die Startseite bei alle anderen seiten sagt er mir das die Seite nicht gefunden wird.

    ich weiss das ich wohl was in der .htaccess ändern muss aber ich verstehe nicht was ich da machen soll.
    Von _.htaccess auf .htaccess habe ich bereits geändert.

    Hier mal der auszug aus .htaccess

    Laut Provider läuft das mod_rewrite auch fehlerfrei.

    Ich bitte um eure Hilfe.

    ##-- $Id: _.htaccess 10934 2017-08-31 12:11:28Z Tomcraft $

    ##-- Default charset
    #AddDefaultCharset UTF-8
    AddDefaultCharset ISO-8859-15

    ##-- Disable the server signature
    ServerSignature Off

    ##-- Turn off ETags in HTTP-header (use both directives)
    <IfModule mod_headers.c>
      Header unset ETag
      RequestHeader unset Proxy
    </IfModule>
    FileETag None

    ##-- When caching of gzipped JS and CSS files is used, enable this setting
    <IfModule mod_headers.c>
      Header set Vary Accept-Encoding
    </IfModule>

    ##-- when using Provider 1&1 set the following lines to activate PHP5
    #AddType x-mapp-php5 .php
    #AddHandler x-mapp-php5 .php

    ##-- Add Mime Types
    <IfModule mod_mime.c>
      AddType application/font-woff2 .woff2
    </IfModule>

    # Disable directory browsing (disabled by default as this causes problems on some servers because they don't allow AllowOverride Directive for Options)
    #Options -Indexes

    ##-- Enable the compression for any type of content
    <IfModule mod_deflate.c>
      <FilesMatch "\\.(js|css|html|htm|php|xml|jpg|jpeg|png|gif|svg|woff|woff2|ttf|otf|eot)$">
        SetOutputFilter DEFLATE
      </FilesMatch>
    </IfModule>

    ##-- Customization of HTTP request and response headers
    <IfModule mod_headers.c>
      <FilesMatch "\\.(ico|jpe?g|png|gif|swf|flv|svg)$">
        Header set Cache-Control "max-age=2592000, public"
      </FilesMatch>
      <FilesMatch "\\.(css|woff|woff2|ttf|otf|eot)$">
        Header set Cache-Control "max-age=604800, public"
      </FilesMatch>
      <FilesMatch "\\.(js)$">
        Header set Cache-Control "max-age=604800, private"
      </FilesMatch>
      <FilesMatch "\\.(xml|txt)$">
        Header set Cache-Control "max-age=604800, public, must-revalidate"
      </FilesMatch>
      <FilesMatch "\\.(html|htm|php)$">
        Header set Cache-Control "max-age=1, private, must-revalidate"
      </FilesMatch>
    </IfModule>

    ##-- Generation of Expires and Cache-Control HTTP headers
    <IfModule mod_expires.c>
      ExpiresActive On
      ExpiresDefault "access plus 1 seconds"
      ExpiresByType image/gif "access plus 2592000 seconds"
      ExpiresByType image/jpg "access plus 2592000 seconds"
      ExpiresByType image/jpeg "access plus 2592000 seconds"
      ExpiresByType image/png "access plus 2592000 seconds"
      ExpiresByType image/svg+xml "access plus 2592000 seconds"
      ExpiresByType text/html "access plus 1 seconds"
      ExpiresByType text/css "access plus 604800 seconds"
      ExpiresByType text/javascript "access plus 604800 seconds"
      ExpiresByType application/x-javascript "access plus 604800 seconds"
      ExpiresByType application/javascript "access plus 604800 seconds"
      ExpiresByType text/x-component "access plus 604800 seconds"
      ExpiresByType font/truetype "access plus 604800 seconds"
      ExpiresByType font/opentype "access plus 604800 seconds"
      ExpiresByType application/x-font-ttf "access plus 604800 seconds"
      ExpiresByType application/x-font-woff "access plus 604800 seconds"
      ExpiresByType application/font-woff "access plus 604800 seconds"
      ExpiresByType application/vnd.ms-fontobject "access plus 604800 seconds"
      ExpiresByType image/x-icon "access plus 604800 seconds"

      <IfModule mod_headers.c>
        Header append Cache-Control "public"
      </IfModule>
    </IfModule>

    ##-- Configure php_flags if necessary
    ##-- BEGIN - use IfModule clause if PHP runs in CGI mode, otherwise just uncomment the lines with php_flag...
    #<IfModule mod_php.c>

      ##-- Warn when arguments are passed by reference at function call time (from PHP5 allow_call_time_pass_reference is deprecated)
      #php_flag allow_call_time_pass_reference on

      ##-- Disable transparent sid support PHP-default is off (XTC Session only on first visit)
      #php_flag session.use_trans_sid off

      ##-- set suhosin flags because of errors with attributes (for webhosters with suhosin hardening patch enabled)
      #php_value suhosin.post.max_array_depth 0
      #php_value suhosin.post.max_array_index_length 0
      #php_value suhosin.post.max_vars 0
      #php_value suhosin.request.max_array_depth 0
      #php_value suhosin.request.max_array_index_length 0
      #php_value suhosin.request.max_vars 0

      ##-- set suhosin flags to have unencrypted session data, affecting "whos_online" & "shopping cart" (for webhosters with suhosin hardening patch enabled)patch enabled
      #php_value suhosin.session.encrypt Off
      #php_value suhosin.session.cryptkey ''

    ##-- END - use IfModule clause if PHP runs in CGI mode, otherwise just uncomment the lines with php_flag...
    #</IfModule>

    ##-- Redirect error pages to Sitemap
    ##-- set the correct Path to ErrorDocument
    ErrorDocument 400 /sitemap.html?error=400
    ErrorDocument 401 /sitemap.html?error=401
    ErrorDocument 402 /sitemap.html?error=402
    ErrorDocument 403 /sitemap.html?error=403
    ErrorDocument 404 /sitemap.html?error=404
    ErrorDocument 500 /sitemap.html?error=500

    ##-----------------------------------------
    ##- SEO Shopstat Modul (Hartmut Koenig)
    ##-----------------------------------------
    <IfModule mod_rewrite.c>
      ##-- Initialize and enable rewrite engine
      ##-- Documentation http://httpd.apache.org/docs/misc/rewriteguide.html
      RewriteEngine On

      ##-- EXAMPLE: If your shop is located at "http://www.yourdomain.com/shop",
      ##-- set the following line like e.g.: RewriteBase /shop/
      RewriteBase /

      ##-- disallow access to dotfiles (.htaccess, .svn, .git, etc.)
      #RedirectMatch 403 /\.

      ##-- Use canonical URLs
      ##-- Use SSL-Proxy
      ##-- HostEurope
      #RewriteCond %{HTTP:X-Forwarded-Server} !^ssl\.webpack\.de$ [NC]
      ##-- 1und1
      #RewriteCond %{HTTP:X-Forwarded-Server} !^ssl\.kundenserver\.de$ [NC]
      ##-- domainFACTORY
      #RewriteCond %{HTTP:X-Forwarded-Server} !^sslsites\.de$ [NC]
      ##-- All-Inkl
      #RewriteCond %{HTTP:X-Forwarded-Server} !^ssl-account\.com$ [NC]
      ##-- Strato
      #RewriteCond %{HTTP:X-Forwarded-Server} !^www\.ssl-id\.de$ [NC]

      ##-- redirect to http www-domain, when www is missing and no subdomain given and not using an ssl-proxy
      #RewriteCond %{HTTP_HOST} !^www\. [NC]
      #RewriteCond %{HTTP_HOST} !\.(.*)\. [NC]
      #RewriteCond %{HTTP_HOST} !^localhost [NC]
      #RewriteRule ^ http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

      ##-- redirect to https www-domain, when www is missing and no subdomain given and not using an ssl-proxy
      #RewriteCond %{HTTP_HOST} !^www\. [NC]
      #RewriteCond %{HTTP_HOST} !\.(.*)\. [NC]
      #RewriteCond %{HTTP_HOST} !^localhost [NC]
      #RewriteRule ^ https://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
      #RewriteCond %{SERVER_PORT} !^443$
      #RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

      ##-- redirect to https non-www-domain, when no subdomain given and not using an ssl-proxy
      #RewriteCond %{SERVER_PORT} !^443$ [OR]
      #RewriteCond %{HTTP_HOST} ^www\. [NC]
      #RewriteCond %{HTTP_HOST} ^(?:www\.)?(.+)$ [NC]
      #RewriteRule ^ https://%1%{REQUEST_URI} [R=301,L]

      ##-- Sitemap
      RewriteRule ^sitemap(.*)\.html$ shop_content.php?coID=8 [QSA,L]

      ##----------------------------------------------------------------------------------
      ##-- When working with SEO-Urls you can decide, whether to use a colon ":" or a dash "-" symbol
      ##-- (Windows Servers might have problems with colon as delimiter!)
      ##-- Change the delimiter symbol (SEO_SEPARATOR) also in file "/includes/extra/seo_url_mod/seo_url_shopstat.php"
      ##-- or create a new file "/includes/extra/configure/seo_separator.php"
      ##-- with the following content: <?php define(&#39;SEO_SEPARATOR&#39;,&#39;-&#39;); ?>
      ##----------------------------------------------------------------------------------

      ##-- Use colon delimiter ":" for SEO-URLS (default setting)
      ##-- Categories (:::)
      RewriteRule :::([_0-9]+):([_0-9]+)\.html$ index.php?cPath=$1&page=$2 [QSA,L]
      RewriteRule :::([_0-9]+)\.html$ index.php?cPath=$1 [QSA,L]

      ##-- Products (::)
      RewriteRule ::(.+)\.html$ product_info.php?products_id=$1 [QSA,L]

      ##-- Content (:_:)
      RewriteRule :_:([0-9]+)\.html$ shop_content.php?coID=$1 [QSA,L]

      ##-- Manufacturers (:.:)
      RewriteRule :\.:([_0-9]+):([_0-9]+)\.html$ index.php?manufacturers_id=$1&page=$2 [QSA,L]
      RewriteRule :\.:([0-9]+)\.html$ index.php?manufacturers_id=$1 [QSA,L]

      ##-- Use dash delimiter "-" for SEO-URLS (alternative setting i.e. for windows servers)
      ##-- Categories (---)
      RewriteRule ---([_0-9]+)-([_0-9]+)\.html$ index.php?cPath=$1&page=$2 [QSA,L]
      RewriteRule ---([_0-9]+)\.html$ index.php?cPath=$1 [QSA,L]

      ##-- Products (--)
      RewriteRule --(.+)\.html$ product_info.php?products_id=$1 [QSA,L]

      ##-- Content (-_-)
      RewriteRule -_-([0-9]+)\.html$ shop_content.php?coID=$1 [QSA,L]

      ##-- Manufacturers (-.-)
      RewriteRule -\.-([_0-9]+)-([_0-9]+)\.html$ index.php?manufacturers_id=$1&page=$2 [QSA,L]
      RewriteRule -\.-([0-9]+)\.html$ index.php?manufacturers_id=$1 [QSA,L]
    </IfModule>


    Linkback: https://www.modified-shop.org/forum/index.php?topic=40433.0

    hpzeller

    • Experte
    • Beiträge: 4.129
    • Geschlecht:
    Re: Probleme Suchmaschinenfreundliche URLs und verlinkung
    Antwort #1 am: 13. September 2019, 14:38:54
    Wenn dein Shop im Verzeichnis shop liegt, dann musst du in der .htaccess die Zeile

    Code: PHP  [Auswählen]
    RewriteBase /

    in

    Code: PHP  [Auswählen]
    RewriteBase /shop/

    ändern.

    Gruss
    Hanspeter

    kklein87

    • Neu im Forum
    • Beiträge: 4
    Re: Probleme Suchmaschinenfreundliche URLs und verlinkung
    Antwort #2 am: 13. September 2019, 16:53:35
    Ok, werde ich später mal testen. Aber wie sieht das mit der Domain Weiterleitung aus? Was muss ich da ändern?

    hpzeller

    • Experte
    • Beiträge: 4.129
    • Geschlecht:
    Re: Probleme Suchmaschinenfreundliche URLs und verlinkung
    Antwort #3 am: 13. September 2019, 23:55:19
    Wenn man von einer Domain auf eine andere weiterleitet, dann steht halt nach der Weiterleitung in der Adresszeile des Browsers nun mal der Domainname auf die weitergeleitet wurde, die internen Shoplinks können ja auch nur auf eine, in deinem Fall die weitergeleitete Domain zeigen.

    Gruss
    Hanspeter
    20 Antworten
    9808 Aufrufe
    10. November 2012, 11:14:00 von zarskey
    8 Antworten
    4972 Aufrufe
    31. August 2012, 11:19:44 von Alfred
               
    anything