Homepage lokal installiert - Links funktionieren aber nicht

Alles, was den Apache betrifft, kann hier besprochen werden.

Homepage lokal installiert - Links funktionieren aber nicht

Postby Kusselin » 11. December 2016 11:59

Hallo Zusammen, habe unsere Homepage lokal installiert als Test auf einem Raspberry Pi..sowieit funzt alles..komme mit der IP/fvl auch auf die Hauptseite.

Will ich aber jetzt einen Link z.B "Alte Herren" anklicken kommt Fehler 404 Not found .-(

Wenn ich die IP des Raspi eingebe kommt folgende Meldung von Apache:

Code: Select all
Debian Logo Apache2 Debian Default Page
It works!

This is the default welcome page used to test the correct operation of the Apache2 server after installation on Debian systems. If you can read this page, it means that the Apache HTTP server installed at this site is working properly. You should replace this file (located at /var/www/html/index.html) before continuing to operate your HTTP server.

If you are a normal user of this web site and don't know what this page is about, this probably means that the site is currently unavailable due to maintenance. If the problem persists, please contact the site's administrator.
Configuration Overview

Debian's Apache2 default configuration is different from the upstream default configuration, and split into several files optimized for interaction with Debian tools. The configuration system is fully documented in /usr/share/doc/apache2/README.Debian.gz. Refer to this for the full documentation. Documentation for the web server itself can be found by accessing the manual if the apache2-doc package was installed on this server.

The configuration layout for an Apache2 web server installation on Debian systems is as follows:

/etc/apache2/
|-- apache2.conf
|       `--  ports.conf
|-- mods-enabled
|       |-- *.load
|       `-- *.conf
|-- conf-enabled
|       `-- *.conf
|-- sites-enabled
|       `-- *.conf
         

    apache2.conf is the main configuration file. It puts the pieces together by including all remaining configuration files when starting up the web server.
    ports.conf is always included from the main configuration file. It is used to determine the listening ports for incoming connections, and this file can be customized anytime.
    Configuration files in the mods-enabled/, conf-enabled/ and sites-enabled/ directories contain particular configuration snippets which manage modules, global configuration fragments, or virtual host configurations, respectively.
    They are activated by symlinking available configuration files from their respective *-available/ counterparts. These should be managed by using our helpers a2enmod, a2dismod, a2ensite, a2dissite, and a2enconf, a2disconf . See their respective man pages for detailed information.
    The binary is called apache2. Due to the use of environment variables, in the default configuration, apache2 needs to be started/stopped with /etc/init.d/apache2 or apache2ctl. Calling /usr/bin/apache2 directly will not work with the default configuration.

Document Roots

By default, Debian does not allow access through the web browser to any file apart of those located in /var/www, public_html directories (when enabled) and /usr/share (for web applications). If your site is using a web document root located elsewhere (such as in /srv) you may need to whitelist your document root directory in /etc/apache2/apache2.conf.

The default Debian document root is /var/www/html. You can make your own virtual hosts under /var/www. This is different to previous releases which provides better security out of the box.
Reporting Problems

Please use the reportbug tool to report bugs in the Apache2 package with Debian. However, check existing bug reports before reporting a new bug.

Please report bugs specific to modules (such as PHP and others) to respective packages, not to the web server itself.


Denke das es an Documents Roots liegt aber hier komme ich nicht weiter..weil mir das Wissen fehlt.

Könnt ihr mir hier helfen bitte?

Gruss
Kusselin
 
Posts: 15
Joined: 03. August 2016 09:15
XAMPP version: 7.0.8
Operating System: Win10

Re: Homepage lokal installiert - Links funktionieren aber ni

Postby Nobbie » 11. December 2016 13:25

Kusselin wrote:Denke das es an Documents Roots liegt aber hier komme ich nicht weiter..weil mir das Wissen fehlt.


Was "liegt" an DocumentRoot (ohne s und zusammen geschrieben)?

Schau Dir die Links genauer an, die verweisen mit einiger Sicherheit auf Dateien/Pfade, die es auf Deinem Raspbi nicht gibt, vielleicht ist auch der Servername (Domainname) noch drin, das kann ich von hier aus nicht sagen, aber das ist im Prinzip die Fehlerursache. Die Software ist auf Deinem Online Rechner in der dortigen Umgebung eingepasst und diese Umgebung stimmt an diversen Stellen nicht mit der Umgebung zu Hause überein.

Mehr kann ich mangels genauerer Beschreibung nicht dazu sagen.

Im Prinzip musst Du entweder

a) die Konfiguration Deiner Seite auf Deinen Raspi anpassen - kann ich aber nichts zu sagen, weil ich nicht weiß, ob Deine Seite so etwas wie "Konfiguration" kennt (WordPress beispielsweise)

oder

b) alle Links aus Deiner Seite auf Deinen Raspi anpassen

oder

c) auf Deinem Raspi die Apacheinstallation mit allem Drum und Dran an die Installation Deines Onlineservers anpassen (gleiche Pfade einrichten, Domainnamen einrichten usw.).

Einfach nur so kann man meistens eine vorhandene Seite nicht einfach kopieren, das Verhalten und der Fehler sind symptomatisch und typisch.
Nobbie
 
Posts: 13183
Joined: 09. March 2008 13:04

Re: Homepage lokal installiert - Links funktionieren aber ni

Postby Kusselin » 11. December 2016 13:39

Hallo nobbie,

1. ja es läuft mit Wordpress
2. die pfade verweisen schon richtig. Ich komme ja mit der Ip/fvl auch auf die Hauptseite. Wenn ich dort dann mit der Maus über den link zb Alte Herren fahre (href) dann zeigt es mir auch schon das richtige an: 192.168.xxx.xx/fvl/alte-herren

In mysql also der Datenbank entsprechend die siteurl und home angepasst :http://localhost/fvl/

Was müsste noch angepasst werden?

der gesamte inhalt der homepage (wp-content, wp-admin usw.) liegt im verzeichnis /var/www/html/fvl/

Zur Info: habe die gliche Page noch lokal auf dfm läppi mit inix laufen und da funzt es einwandfrei..hier musste ich nur die siteurl und home ändern und gut is..hier kann ich auf alle links klicken und das funzt auch!

Was musst du noch wissen um das wir das Prob weiter eingrenzen können?

Was sagt mir die apache default site mit dem Abschnitt dokumentroot? Erklärs mir bitte.
Gruss

Ich komme auch in wp-admin rein..wie gesagt funzt alles bis auf die links on der Page..die funzen nicht!
Kusselin
 
Posts: 15
Joined: 03. August 2016 09:15
XAMPP version: 7.0.8
Operating System: Win10

Re: Homepage lokal installiert - Links funktionieren aber ni

Postby Nobbie » 11. December 2016 14:58

Eigentlich bist Du hier total falsch, das sind Fragen für ein WordPress Forum, bzw. es gibt sogar schon fertige Doku dazu, die allgemeine Thematik dazu lautet "Server Umzug".

Da diese Fragen aber immer wieder hier gestellt werden, weiß ich von anderen Problemen, dass es irgendwo eine Datei wp-config.php oder so gibt und da muss man den Servernamen und/oder die URL für die Homepage anpassen. Wenn das nicht reicht, weiß ich eh nicht weiter, hier ist eben kein WordPress Forum.

Kusselin wrote:Was sagt mir die apache default site mit dem Abschnitt dokumentroot? Erklärs mir bitte.


Bei aller Liebe - das ist hoffnungslos zu viel verlangt. Es gibt tonnenweise Doku und Tutorials und Videos im Internet, Google hilft Dir weiter.
Nobbie
 
Posts: 13183
Joined: 09. March 2008 13:04

Re: Homepage lokal installiert - Links funktionieren aber ni

Postby Kusselin » 11. December 2016 15:04

Hallo Nobbie,

ja schon o.k. das höre ich öfters das ich falsch bin...trotzdem danke..ich dachte halt weil bei mir ein Apache 2 läuft bin ich hier richtig und alles andere funzt ja...!

Aber ich habe jetzt nochmal in Wordpress unter Einstellungen Permalinks auf Standard gestellt und auf einmal funzen auch die Links :shock: :D

Also es kann sich alles wieder beruhigen. Soll nur für die anderen sein damit die nicht solange grübeln müssen!!

Gruss und danke nochmal!
Kusselin
 
Posts: 15
Joined: 03. August 2016 09:15
XAMPP version: 7.0.8
Operating System: Win10


Return to Apache

Who is online

Users browsing this forum: No registered users and 17 guests