Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Sign In
Not a member yet? Click here to register.

Permalinks doesnt work


Print Track
I enabled all of permalinks addons (news, blog, etc).

But on site I have normal links ( ex. infusions/news/news.php?readmore=1) without alias.

Also in "Permailnk settings" I can't set ENABLE to any of settings. When I try change status to enable and press button "Save settings" i see error "There was an error while processing your request".

I dont have any errors in log.

Version 9.02

10 replies

its server issue i think ,

on permalink file there is code to check mod rewrite is enabled or not , (Get apache modules )

you have to work around this problem if you know php coding , or just modify database from 0 to 1 for enable seo :D

you will face .htaccess file creation problem which you need to open permalink php file then take the htaccess lines from it ;)


line to check mod rewrite is like that



// Check if mod_rewrite is enabled
$mod_rewrite = FALSE;
if (function_exists('apache_get_modules') && in_array('mod_rewrite', apache_get_modules())) {
   $mod_rewrite = TRUE;
} elseif (getenv('HTTP_MOD_REWRITE') == 'On') {
   $mod_rewrite = TRUE;
} elseif (isset($_SERVER['IIS_UrlRewriteModule'])) {
   $mod_rewrite = TRUE;
} elseif (isset($_SERVER['HTTP_MOD_REWRITE'])) {
   $mod_rewrite = TRUE;
}
define('MOD_REWRITE', $mod_rewrite);

if (!MOD_REWRITE) {
   addNotice('danger', "<i class='fa fa-lg fa-warning m-r-10'></i>".$locale['rewrite_disabled']);
}



the lines of htaccess is like that

      // Rewrite settings
      $htc .= "Options +SymLinksIfOwnerMatch".PHP_EOL;
      $htc .= "<IfModule mod_rewrite.c>".PHP_EOL;
      $htc .= "   # Let PHP know mod_rewrite is enabled".PHP_EOL;
      $htc .= "   <IfModule mod_env.c>".PHP_EOL;
      $htc .= "      SetEnv MOD_REWRITE On".PHP_EOL;



At final ; i hope to fix checking procedure and every one check his own server for mod rewrite
On the same server I have installed PHP Fusion version 9.00.00 and there permalinks work well.

The code which you pasted does not show any notice with rewrite_disabled, so I think that the option of rewriting enabled: D
Where can I find these settings in the database? which table is response of Permalinks?

Quote

On the same server I have installed PHP Fusion version 9.00.00 and there permalinks work well.

The code which you pasted does not show any notice with rewrite_disabled, so I think that the option of rewriting enabled: D
Where can I find these settings in the database? which table is response of Permalinks?
- by kosiorskieu


I know , if you have root access you can solve easly but making the global apache configuration > Global Configuration > Server Tokens [?] set it to minimal , it will solve the problem , the issue here is server not Fusion 9.02

this from whm /cpanel
if you have root access to ssh , i can tell you how to solve it
Yes, I have root access to cPanel. Look at my dashboard in attachment (cpanel.jpg).
I try to enable some checkboxes in PHP Selector options, I thought that this maye solve it,

s18.postimg.org/4eh9830mv/c_panel.jpg
s18.postimg.org/atga4r7cn/php_selector.jpg
After digging Farther , its because we run on PHP interface CGI ,

but when i run PHP interface apache2handler i have another error , but it reads the mod_rewrite


At final , i think there bug on that option !


you can make it run but enable this option on database and this the htaccess file you need

# Force utf-8 charset
AddDefaultCharset utf-8

# Security
ServerSignature Off

# Secure htaccess file
<Files .htaccess>
order allow,deny
deny from all
</Files>

# Protect config.php
<Files config.php>
order allow,deny
deny from all
</Files>

# Block Nasty Bots
<IfModule mod_setenvifno.c>
   SetEnvIfNoCase ^User-Agent$ .*(craftbot|download|extract|stripper|sucker|ninja|clshttp|webspider|leacher|collector|grabber|webpictures) HTTP_SAFE_BADBOT
   SetEnvIfNoCase ^User-Agent$ .*(libwww-perl|aesop_com_spiderman) HTTP_SAFE_BADBOT
   Deny from env=HTTP_SAFE_BADBOT
</IfModule>

# Disable directory listing
Options -Indexes

Options +SymLinksIfOwnerMatch
<IfModule mod_rewrite.c>
   # Let PHP know mod_rewrite is enabled
   <IfModule mod_env.c>
      SetEnv MOD_REWRITE On
   </IfModule>
   RewriteEngine On
   RewriteBase /
   # Fix Apache internal dummy connections from breaking [(site_url)] cache
   RewriteCond %{HTTP_USER_AGENT} ^.*internal\ dummy\ connection.*$ [NC]
   RewriteRule .* - [F,L]
   # Exclude /assets and /manager directories and images from rewrite rules
   RewriteRule ^(administration|themes)/*$ - [L]
   RewriteCond %{REQUEST_FILENAME} !-f
   RewriteCond %{REQUEST_FILENAME} !-d
   RewriteCond %{REQUEST_FILENAME} !-l
   RewriteCond %{REQUEST_URI} !^/(administration|config|index.php)
   RewriteRule ^(.*?)$ index.php [L]
</IfModule>
ErrorDocument 400 /error.php?code=400
ErrorDocument 401 /error.php?code=401
ErrorDocument 403 /error.php?code=403
ErrorDocument 404 /error.php?code=404
ErrorDocument 500 /error.php?code=500


i hope they fix this issue
I pasted this code in my .htaccess file and unfortunately still not working..

I have clean instalation of PHP Fusion, i didn't change anything in files, so I dont have any idea why its not working..
please visit: http://kos.kylos.pl/www/portal/infusions/blog/blog.php

I'm just disabled all of rewrites and enabled again. It gets me some errors in log now:

PDOMySQL.inc
/www/portal/administration/permalink.php?aid=7ecdedc8e3fd7b8f&disable=homepage
Line: 71

GIT: https://github.com/php-fusion/PHP-Fusion/blob/9.02/includes/classes/PHPFusion/Database/Driver/PDOMySQL.inc#L71
You are on the same server?
Yes.
no he is on another server :)
Please see the fix I did today. I wasn't able to turn on the driver. The fix had been a token problem.
author kosiorskieu
forumSEO & SEF - 9
replies11 posts
viewed2,516 times
activeLast updated on 3 years ago
You can view all discussion threads in this forum.
You cannot set up a bounty in this discussion thread.
You can start a new discussion thread in this forum.
You cannot reply in this discussion thread.
You cannot start on a poll in this forum.
You cannot upload attachments in this forum.
You can download attachments in this forum.
You cannot up or down-vote on the post in this discussion thread.
Users who participated in discussion: Falk, Chan, vecas, kosiorskieu