Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Openshift Redirection error #2398

Closed
niklasp opened this issue Jun 17, 2015 · 9 comments
Closed

Openshift Redirection error #2398

niklasp opened this issue Jun 17, 2015 · 9 comments

Comments

@niklasp
Copy link

niklasp commented Jun 17, 2015

With a theme using Redux as their theme options framework I get a lot of filepath errors

example:
The theme looks for

https://00y8x-y8x.rhcloud.com/wp-content/var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/options/inc/fields/ace_editor/vendor/ace.js

where it should look for

https://00y8x-y8x.rhcloud.com/wp-content/themes/atelier/includes/options/inc/fields/ace_editor/vendor/ace.js

more from the firebug log:

GET 
https://00y8x-y8x.rhcloud.com/wp-content/var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/options/inc/fields/ace_editor/vendor/ace.js [HTTP/1.1 404 Not Found 812ms]
GET 
https://00y8x-y8x.rhcloud.com/wp-content//var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/options/inc/fields/ace_editor/field_ace_editor.min.js [HTTP/1.1 301 Moved Permanently 262ms]
GET 
https://00y8x-y8x.rhcloud.com/wp-content/var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/options/inc/fields/ace_editor/field_ace_editor.min.js [HTTP/1.1 404 Not Found 809ms]
GET 
https://00y8x-y8x.rhcloud.com/wp-content//var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/options/inc/fields/sorter/field_sorter.min.js [HTTP/1.1 301 Moved Permanently 257ms]
GET 
https://00y8x-y8x.rhcloud.com/wp-content/var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/options/inc/fields/sorter/field_sorter.min.js [HTTP/1.1 404 Not Found 795ms]
GET 
https://00y8x-y8x.rhcloud.com/wp-content//var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/options/inc/fields/typography/field_typography.min.js [HTTP/1.1 301 Moved Permanently 258ms]
GET 
https://00y8x-y8x.rhcloud.com/wp-content/var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/options/inc/fields/typography/field_typography.min.js [HTTP/1.1 404 Not Found 796ms]
GET 
https://00y8x-y8x.rhcloud.com/var/lib/openshift/557ea272e0b8cd814900012d/app-root/data/themes/atelier/includes/option-extensions/extensions/super_search/super_search/field_

The theme authors directed me here. Any advice would be cool. Can it be an openshift .htaccess error?

wp-config.php

<?php
/*
|--------------------------------------------------------------------------
| WordPress Configuration
|--------------------------------------------------------------------------
|
| This file has been configured for use with OpenShift.
|
| To learn more about managing WordPress on Openshift, see:
| https://developers.openshift.com/en/php-wordpress.html
|
*/

/*
|--------------------------------------------------------------------------
| OpenShift Recommended Add-on: SendGrid
|--------------------------------------------------------------------------
|
| By default, WordPress uses PHP's mail function to send emails. We
| strongly recommend using SendGrid to ensure messages are delivered to
| both you and your users.
|
| To learn more installing SendGrid, see:
| https://developers.openshift.com/en/marketplace-sendgrid.html#php-wordpress
|
*/

/**
 * Code provided for users following SendGrid instructions linked above.
 */
//define('SENDGRID_USERNAME', getenv('SENDGRID_USERNAME'));
//define('SENDGRID_PASSWORD', getenv('SENDGRID_PASSWORD'));
//define('SENDGRID_SEND_METHOD', 'api');

/*
|--------------------------------------------------------------------------
| WordPress Database Table Prefix
|--------------------------------------------------------------------------
|
| You can have multiple installations in one database if you give each a unique
| prefix. Only numbers, letters, and underscores please!
|
*/

$table_prefix  = 'wp_';

/*
|--------------------------------------------------------------------------
| WordPress Administration Panel
|--------------------------------------------------------------------------
|
| Determine whether the administration panel should be viewed over SSL. We
| prefer to be secure by default.
|
*/

define('FORCE_SSL_ADMIN', true);

/*
|--------------------------------------------------------------------------
| WordPress Debugging Mode - MODIFICATION NOT RECOMMENDED (see below)
|--------------------------------------------------------------------------
| 
| Set OpenShift's APPLICATION_ENV environment variable in order to enable 
| detailed PHP and WordPress error messaging during development.
|
| Set the variable, then restart your app. Using the `rhc` client:
|
|   $ rhc env set APPLICATION_ENV=development -a <app-name>
|   $ rhc app restart -a <app-name>
|
| Set the variable to 'production' and restart your app to deactivate error 
| reporting.
|
| For more information about the APPLICATION_ENV variable, see:
| https://developers.openshift.com/en/php-getting-started.html#development-mode
|
| WARNING: We strongly advise you NOT to run your application in this mode 
|          in production.
|
*/

define('WP_DEBUG', getenv('APPLICATION_ENV') == 'development' ? true : false);

/*
|--------------------------------------------------------------------------
| MySQL Settings - DO NOT MODIFY
|--------------------------------------------------------------------------
|
| WordPress will automatically connect to your OpenShift MySQL database
| by making use of OpenShift environment variables configured below.
|
| For more information on using environment variables on OpenShift, see:
| https://developers.openshift.com/en/managing-environment-variables.html
|
*/

define('DB_NAME', getenv('OPENSHIFT_APP_NAME'));
define('DB_USER', getenv('OPENSHIFT_MYSQL_DB_USERNAME'));
define('DB_PASSWORD', getenv('OPENSHIFT_MYSQL_DB_PASSWORD'));
define('DB_HOST', getenv('OPENSHIFT_MYSQL_DB_HOST') . ':' . getenv('OPENSHIFT_MYSQL_DB_PORT'));
define('DB_CHARSET', 'utf8');
define('DB_COLLATE', '');

/*
|--------------------------------------------------------------------------
| Authentication Unique Keys and Salts - DO NOT MODIFY
|--------------------------------------------------------------------------
|
| Keys and Salts are automatically configured below.
|
*/

require_once(getenv('OPENSHIFT_REPO_DIR') . '.openshift/openshift.inc');

/*
|--------------------------------------------------------------------------
| That's all, stop editing! Happy blogging.
|--------------------------------------------------------------------------
*/

// absolute path to the WordPress directory
if ( !defined('ABSPATH') )
  define('ABSPATH', dirname(__FILE__) . '/');

// tell WordPress where the plugins directory really is
if ( !defined('WP_PLUGIN_DIR') && is_link(ABSPATH . '/wp-content/plugins') )
  define('WP_PLUGIN_DIR', realpath(ABSPATH . '/wp-content/plugins'));

// sets up WordPress vars and included files
require_once(ABSPATH . 'wp-settings.php');

.htaccess

RewriteEngine on 

# Uncomment the following lines to force HTTPS
#RewriteCond %{HTTP:X-Forwarded-Proto} !https 
#RewriteRule .* https://%{HTTP_HOST}%{REQUEST_URI} [R,L]

# WordPress Defaults
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
@dovy
Copy link
Member

dovy commented Jun 17, 2015

This means you're using a symbolic link instead of having the files in the proper directory. PHP can't detect when you're using a symbolic link or not. ;)

@kprovance
Copy link
Member

Closing due to lack of reply.

@elijahpaul
Copy link

@niklasp Did you manage to resolve this? I'm experiencing the exact same issue.

@niklasp
Copy link
Author

niklasp commented Dec 4, 2015

i did. i had to install the redux framework manually as a plugin. though i think that it was not a problem of the used version but something else that i did not further elaborate when it worked..

@elijahpaul
Copy link

@niklasp Thanks for the update. Based on that, I'll have another crack at fixing this.

@gustavorps
Copy link

@elijahpaul good to hear that. Can you share your crack to OpenShit?

@ghost
Copy link

ghost commented Apr 24, 2016

I'm having the same issue. Did anyone have a way to fix this? I attempted the direct install of the plugin but it didn't help.

@dovy
Copy link
Member

dovy commented Apr 25, 2016

Please open a new ticket. What is open shift?

@lalber
Copy link

lalber commented Aug 2, 2016

@niklasp @gustavorps @vivalasmecca Please check #3054 (comment) to see if the workaround works in your scenario. It's in another issue because it was using another theme. Again, this is just a hint.

@reduxframework reduxframework locked and limited conversation to collaborators Aug 2, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants