Lunarpages

I have moved this discussion here, so it will be in an accurate location.

I have uploaded omeka and when I try to get into the admin part I get the following error

/home/south150/public_html/colquitt/admin/.htaccess: Invalid command 'php_value', perhaps mis-spelled or defined by a module not included in the server configuration

I have looked into my admin/htaccess file and this is a copy of it.

php_value display_errors 1
php_flag zlib.output_compression On
php_value zlib.output_compression_level 5

RewriteEngine on
RewriteRule !\.(js|ico|gif|jpg|png|css)$ index.php

The following is my root/htaccess file

<IfModule mod_php5.c>
php_value display_errors 1
php_flag zlib.output_compression On
php_flag register_globals off
php_value zlib.output_compression_level 5
</IfModule>

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d [OR]
# This ensures that Apache will not mistake the URL mysite.com/archive/ for a request for the physical directory that stores files
RewriteCond %{REQUEST_URI} .+\/archive\/
RewriteRule !\.(js|ico|gif|jpg|png|css)$ index.php

<FilesMatch "\.(php|ini)$">
Order Allow,Deny
Deny from all
</FilesMatch>

<Files index.php>
Allow from all
</Files>

# Uncomment the lines below in order to enable caching of some files via Apache (after a finished site has gone live)
<IfModule mod_expires.c>
# <FilesMatch "\.(js|css|gif|png)$">
# ExpiresActive on
# ExpiresDefault "access plus 10 day"
# </FilesMatch>
</IfModule>

I checked with lunarpages and I am using php 5.2.

Any ideas?

Do me a favor and remove the offending code from your admin/.htaccess file, but leave it in .htaccess file that is in Omeka's directory. Let me know if that works, and I'll make sure it's fixed for everyone else in the future.

Lunarpages got back to me and sent me this email.

---- TECH RESPONSE STARTS HERE ----
Hello,
The way the .htaccess and php.ini are configured as it seems to be configuring for apache as well use suPHP to parze php file, here is information on how our servers parse php.

At Lunarpages, our servers are setup to use suPHP to parse php pages as CGI instead of an Apache module. If you are running a PHP-based script on your site and are receiving a 500 and/or 404 errors on your pages, it is likely you have one or more of the following occurring:

1. The permissions on some of the folders or files are 777 or 666. If this is the case, change them to either 755 or 644 in Cpanel's File Manager (or using your local FTP client).

2. The files and/or folders are not owned by you. Certain applications having been run under php as an apache module may have files owned by the apache user of nobody. An indication that you don't own the files would be if you are unable to change their file permissions. To correct this, please provide your username or domain name, and provide the location of the folder or files that need to have your ownership.

3. Your .htaccess file has php_values or php_flags in it. This causes a 500 Internal server error when attempting to execute the script.

The php_values and php_flags will need to be removed from your .htaccess file (please make a backup of the .htaccess by copying its contents and saving it on your desktop as htaccess.txt). Take the contents removed from .htaccess and place it into a file you create called php.ini. Remember to remove the php_flag and php_value part before the directives as php.ini files do not require those in front of the values. You can always make the changes and ask us if the changed files are correct.

Because php.ini values are not shared across directories, you would need a separate php.ini file in each folder that has .htaccess or that requires the php_values or php_flags. In order to avoid doing this, you can place a line in the .htaccess file in your public_html folder to have all values in your public_html php.ini to be shared across all folder. This line would be the following:

suPHP_ConfigPath /home/username/public_html

Please let us know if you have any questions or require further assistance.
--
Thank you.
Please feel free to contact us with any concerns or questions.
Best Regards,
Mark Cale
Customer Service Representative
support@lunarpages.com
Support Forums - http://www.lunarforums.com
Telephone: 1-714-521-8150
Fax: 1-714-521-8195
---- TECH RESPONSE ENDS HERE ----

I did all this and I no longer get a 500 error.

I do get to the admin log in screen, but never get past it.

I now get the following message from my error log

PHP: Error parsing /home/south150/public_html/colquitt/admin/php.ini on line 9

This is the php.ini file

<IfModule mod_php5.c>
display_errors 1
zlib.output_compression On
register_globals off
zlib.output_compression_level 5
</IfModule>

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d [OR]
# This ensures that Apache will not mistake the URL mysite.com/archive/ for a request for the physical directory that stores files
RewriteCond %{REQUEST_URI} .+\/archive\/
RewriteRule !\.(js|ico|gif|jpg|png|css)$ index.php

<FilesMatch "\.(php|ini)$">
Order Allow,Deny
Deny from all
</FilesMatch>

<Files index.php>
Allow from all
</Files>

# Uncomment the lines below in order to enable caching of some files via Apache (after a finished site has gone live)
<IfModule mod_expires.c>
<FilesMatch "\.(js|css|gif|png)$">
ExpiresActive on
ExpiresDefault "access plus 10 day"
</FilesMatch>
</IfModule>

-----------------------------

The directions they gave seem to be pretty good, except instead of placing the entire contents of the .htaccess file into the php.ini file, it should only contain the parts that previously had 'php_value' and 'php_flag' in front of them, but also slightly modified to fall in line with PHP's INI file format. So go ahead and replace the php.ini in that folder with a file that contains the following:

display_errors = 1
zlib.output_compression = On
register_globals = off
zlib.output_compression_level = 5

Keep the rest of the code in the .htaccess file the way it was originally set up.

Also of note is that if you plan on using Omeka for a production site (as opposed to just testing it out), the 'display_errors' value should be set to 0 instead of 1 when you are done making any changes to the code.

I did as you asked. The good news is that I am not getting any error messages in my error log .

The bad news is that when I go to the admin/index.php

and enter my username and password . It sits there as if it is loading a page and then resets to a blank password page. No message,no nothing.

Any ideas?

Try going to just http://www.youromekainstall.com/admin/ and cut the 'index.php' off the url you're accessing for the admin panel. This should display a login screen that's skinned, and can receive the post-data of the login screen. This is a bug we'll have to fix -- but logging in should be a non-issue for you if you access the correct URL.

OK, I went to www.southern-history.org/admin/ and I got a

Not Found
The requested URL /admin/ was not found on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Sorry for the confusion -- it doesn't appear you have Omeka installed at southern-history.org, I just gave www.youromekainstall.com/admin/ as an example.

Type in the url you were previously typing in yesterday.. which is likely a directory following www.southern-history.org (ie: http://www.southern-history.org/omeka/admin/ .. where 'omeka' is name of the directory that you've installed Omeka) and make sure you shave the index.php off that URL.

I am so confused right now. I decided to wipe everything out and start over again. I now have everything in the southern-history.org/omeka/ directory.

My php.ini file at southern-history.org/omeka is:

display_errors = 1
zlib.output_compression = On
register_globals = off
zlib.output_compression_level = 5

My .htaccess file at southern-history.org/omeka is:

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d [OR]
# This ensures that Apache will not mistake the URL mysite.com/archive/ for a request for the physical directory that stores files
RewriteCond %{REQUEST_URI} .+\/archive\/
RewriteRule !\.(js|ico|gif|jpg|png|css)$ index.php

<FilesMatch "\.(php|ini)$">
Order Allow,Deny
Deny from all
</FilesMatch>

<Files index.php>
Allow from all
</Files>

# Uncomment the lines below in order to enable caching of some files via Apache (after a finished site has gone live)
<IfModule mod_expires.c>
# <FilesMatch "\.(js|css|gif|png)$">
# ExpiresActive on
# ExpiresDefault "access plus 10 day"
# </FilesMatch>
</IfModule>

My php.ini file at southern-history.org/omeka/admin is:

display_errors = 1
zlib.output_compression = On
register_globals = off
zlib.output_compression_level = 5

and my .htaccess file at southern-history.org/omeka /admin is:

RewriteEngine on
RewriteRule !\.(js|ico|gif|jpg|png|css)$ index.php

-----------------------------------------------------------------------

When I try to run the website is get the following

Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /home/south150/public_html/omeka/application/libraries/Omeka/Core.php on line 14

When I go to admin/index.php I get

Parse error: syntax error, unexpected T_OBJECT_OPERATOR in
/home/south150/public_html/omeka/admin/index.php on line 17

----------------------------------------------------

I know this is a woderfull program/ I just wish I could get it running.

Thanks