I am using a wordpress theme which I have modified a bit, based on the "Revera" Wordpress theme.
I have used it on other sites and it has worded fine. However, I have always installed it in the root of the domain. This time I have installed it on http://www.gas-sense.co.uk/blog
It isn't generating the usual homepage layout ( see http://www.georgeedwards.co )
Just wondering if the themes are typically setup to trigger the homepage layout? and if that is defined in a particular section of the php ?
The root folder is not a problem, you probably didn't set up the site url correctly, read the docs bellow
https://codex.wordpress.org/Changing_The_Site_URL
Related
Is it possible to rename or redirect the plugins/child[] directories to change plugin names for Google or source code view?
Wordpress obviously relies on wp-content and it's children to run, but I'm curious if it's possible to rename the children of plugins using .htaccess or another means.
I've experimented with variations this:
`Redirect 301 /path/to-old-url http://www.yourdomain.com/path/to-new-url`
...but that comes back to an actual redirect header response which I can't have.
I'm hoping it can be done and still have Wordpress function and update themes and plugins normally, but I'm not that savvy using .htaccess and I've blanked my site several times trying different things.
Any pointers or help would be really appreciated. :)
EDIT: What I'm trying to do is change the visible plugin/child directory name only. Not change the directory Wordpress accesses for plugins/name - having the revised plugin/name visible is not a problem.
OK, add this in wp-config.php, and it should do what you need, replacing 'apps' with the directory you want to serve from, and moving the plugins to the same directory on the server.
define( 'WP_PLUGIN_DIR', $_SERVER['DOCUMENT_ROOT'] . '/apps' );
define( 'WP_PLUGIN_URL', 'http://' . $_SERVER['HTTP_HOST'] . '/apps' );
(Initial responses before fully understanding the question.)
Not really.
You could use this WP Hide & Security to hide the plugin path /wp-content/plugins/ and rewrite that to something else, e.g., /apps/ ...but the NAMES of the plugins would still be visible.
The only way I could think of not showing the plugin names would be to directly include them in your theme via php includes, and strip out all the css/js that the plugin adds and incorporate that into your theme.
However, that likely would break the plugin, and even if you could get it working correctly, there would be now way to update said plugin in the future....(and of course that would make your site terribly hard to support so it's not recommended at all.)
I have a blank page when accessing my local, however I can login fine into /wp_admin and change the theme. In the appearances menu, I have:
The active theme is broken. Reverting to the default theme.
How can I solve this?
Some info hopefully to help you understand. As this is a Vagrant install, in the site root, I have:
/web
/assets
In web, we have the Wordpress install. web/wp/wp_content/themes contains all default Wordpress themes i.e. twentythirteen. when set, these themes work ok.
In assets, I have the actual custom theme, which needs to remain in that folder, as Gulp regenerates the theme and /less and /js files in case of changes. This is the theme which displays as broken in the admin.
The custom theme is referenced with a file in web/app/themes.
Figured it out.
If anyone comes across this issue, update your VirtualBox to latest. Theme's symbolic link was generating back slashes to the path like ..\..\ and it should have been ../../assets/theme_name
For a project I'm working on I am trying to accomplish to match the whmcs client area to my wordpress site.
So far I've made a lot of progress but I'm stuck right now. I want to include the header of my wordpress site in whmcs.
I tried to implement the static code of my header in the header.tpl file of whmcs. It kind of works but the css conflicts with the main theme of whmcs.
The second thing I tried was to include it with php
<?php include(path/to/header.php'); ?>
Since the header.php is located in the main www directory and whmc is on a subdomain, I was advised to try this:
include($_SERVER['DOCUMENT_ROOT'].'/header.php');
Neither of those two methods worked.
The next thing I did was a new approach. I tried implementing the whmcs layout in wordpress with a plugin called advanced Iframe. It does work but it doesn't always behave as it should and I think it is an better idea to keep whmcs completely on its own subdomain (client.domain.com)
I am no coding genius, so I'm stuck at this point. Are there any workarounds for this?
Assuming the file you're wanting to include the header in is in the same directory as header.php, then you can use
<?php include(__DIR__.'/header.php'); ?>
I have found my mistake.
Since whmcs themes are .tpl, php can't be included directly and is not recommended. What I did was create a new folder in the theme directory with all the assets and a header.tpl file.
Then I included the header.tpl like this.
{include file="$template/header/header.tpl"}
The only downside is that I have to edit the menu manually when changes are made to the WordPress site
I have ci installed in root and wordpress inside wordpress directory.
I already allowed wordpress to use root by setting site url and main .htaccess to rewrite wordpress directory, but because ci is inside root i have url conflict between ci and wordpress..
You know that ci using pretty links, so when i try to run this for example:
example.com/ci_class/ci_function
It's redirects me to wordpress template with message
Not Found
This happens probably because i included wordpress wp-load.php inside index.php of codeignitier...
What i can to do?
I want to use wordpress functions inside ci, but i also want that ci url works fine...
I have a wordpress installed to a subfolder in the root of my site. So if my site is "site.com", the wordpress is in "site.com/blog".
I want to display some posts from wordpress to pages outside of the blog directory. I have read some articles telling that to use wordpress outside it's folder i just have to include or require the "wp-load.php" from wordpress to the page. Now the problem is I have tried using this method, but when I view the page in the browser, it just redirects to "wp-admin/install.php" which doesn't exists because i am at the root directory.
Change your site url from
http://www.site.com/blog/
to
http://www.site.com/
Read http://codex.wordpress.org/Changing_The_Site_URL
In database it would be found in wp_options table