Σελίδα 1 από 1

phpbb 3.2 Rewrites

Δημοσιεύτηκε: Κυρ 15 Σεπ 2019, 12:12
από codesix
Καλησπέρα σε όλους! Έχω έναν ubuntu Server με apache2 και ενεργοποιημένα Rewrites. Στο virtual Host έχω αυτό

Κώδικας: Επιλογή όλων

<VirtualHost *:80>
    <Directory /var/www/html>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>
Και στο forum αυτό το htaccess

Κώδικας: Επιλογή όλων

<IfModule mod_rewrite.c>
RewriteEngine on

#
# Uncomment the statement below if URL rewriting doesn't
# work properly. If you installed phpBB in a subdirectory
# of your site, properly set the argument for the statement.
# e.g.: if your domain is test.com and you installed phpBB
# in http://www.test.com/phpBB/index.php you have to set
# the statement RewriteBase /phpBB/
#
#RewriteBase /

#
# Uncomment the statement below if you want to make use of
# HTTP authentication and it does not already work.
# This could be required if you are for example using PHP via Apache CGI.
#
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization},L]

#
# The following 3 lines will rewrite URLs passed through the front controller
# to not require app.php in the actual URL. In other words, a controller is
# by default accessed at /app.php/my/controller, but can also be accessed at
# /my/controller
#
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ app.php [QSA,L]
#
# If symbolic links are not already being followed,
# uncomment the line below.
# http://anothersysadmin.wordpress.com/2008/06/10/mod_rewrite-forbidden-403-with-apache-228/
#
Options +FollowSymLinks
</IfModule>

# With Apache 2.4 the "Order, Deny" syntax has been deprecated and moved from
# module mod_authz_host to a new module called mod_access_compat (which may be
# disabled) and a new "Require" syntax has been introduced to mod_authz_host.
# We could just conditionally provide both versions, but unfortunately Apache
# does not explicitly tell us its version if the module mod_version is not
# available. In this case, we check for the availability of module
# mod_authz_core (which should be on 2.4 or higher only) as a best guess.
<IfModule mod_version.c>
	<IfVersion < 2.4>
		<Files "config.php">
			Order Allow,Deny
			Deny from All
		</Files>
		<Files "common.php">
			Order Allow,Deny
			Deny from All
		</Files>
	</IfVersion>
	<IfVersion >= 2.4>
		<Files "config.php">
			Require all denied
		</Files>
		<Files "common.php">
			Require all denied
		</Files>
	</IfVersion>
</IfModule>
<IfModule !mod_version.c>
	<IfModule !mod_authz_core.c>
		<Files "config.php">
			Order Allow,Deny
			Deny from All
		</Files>
		<Files "common.php">
			Order Allow,Deny
			Deny from All
		</Files>
	</IfModule>
	<IfModule mod_authz_core.c>
		<Files "config.php">
			Require all denied
		</Files>
		<Files "common.php">
			Require all denied
		</Files>
	</IfModule>
</IfModule>
Παρόλα αυτά όταν πάω να κάνω οτιδήποτε στο forum ( σύνδεση/νέο θέμα/Σύνδεση στο Admin Panel) Μου βγάλει όλο το link

Κώδικας: Επιλογή όλων

index.php?sid=8e9389dff940bj81f9660e1b4n70fd94

Re: phpbb 3.2 Rewrites

Δημοσιεύτηκε: Κυρ 15 Σεπ 2019, 12:49
από tzampatzis
Αυτό μπορεί να οφείλεται στο γεγονός ότι έχεις κάποια λάθος ρύθμιση στα cookies σου.
Το sid χρησιμοποιείται για εναλλακτικό session handling, αν αποτύχει ο χειρισμός του session από τα cookies.

Εδώ μπορείς να βρείς ένα άρθρο για τη σωστή ρύθμιση των cookies.

Re: phpbb 3.2 Rewrites

Δημοσιεύτηκε: Κυρ 15 Σεπ 2019, 13:13
από codesix
Ευχαριστώ θα το κοιτάξω η αλήθεια είναι ότι δεν τρέχει κανονικά το forum. μέχρι να το στήσω μπαίνω με ip/mydomain

Re: phpbb 3.2 Rewrites

Δημοσιεύτηκε: Κυρ 15 Σεπ 2019, 21:27
από gtsoukn
Παναγιώτη, επειδή μου έβγαζε κι εμένα αυτό το sid κοίταξα το άρθρο και έκανα κάποιες αλλαγές.
Ενδεικτικά το domain ήταν localhost προφανώς επειδή το forum το έστησα τοπικά και μετά το ανέβασα, και το άλλαξα σε forum.4gps.gr
Τώρα δεν μπορώ να συνδεθώ.
Παίρνω το μήνυμα "Η υποβληθείσα μορφή ήταν άκυρη. Προσπαθήστε πάλι."
Τι κάνω;

Re: phpbb 3.2 Rewrites

Δημοσιεύτηκε: Κυρ 15 Σεπ 2019, 21:39
από tzampatzis
Άδειασε το φάκελο cache από ftp και μετά Ctrl + F5 για να αδειάσει η cache του browser και αν δεν το κάνει αυτόματα, σβήσε τα cookies του browser. Τέλος δοκίμασε να ξαναμπείς.

Αν δεν μπαίνεις πάλι, δοκίμασε μέσα από τη sql σου να τρέξεις την εντολή

Κώδικας: Επιλογή όλων

PDATE phpbb_config SET config_value = 'forum.4gps.gr' WHERE config_name = 'cookie_domain';
Χωρίς τελεία μπροστά.

Re: phpbb 3.2 Rewrites

Δημοσιεύτηκε: Κυρ 15 Σεπ 2019, 21:51
από gtsoukn
Οκ. Έγινε.
Δεν χρειάστηκε να τρέξω την εντολή.

Να υποθέσω ότι και όλα τα μέλη πρέπει να διαγράψουν τα cookies του browser;

Re: phpbb 3.2 Rewrites

Δημοσιεύτηκε: Κυρ 15 Σεπ 2019, 21:57
από tzampatzis
Κάνε μια εκκαθάριση συνόδων και θα τους πετάξει αυτόματα λογικά. Θα πάρει δηλαδή το νέο cookie.