how do you disable the site from being seen to work behind
how do you disable the site from being seen to work behind
Hello, I'm new to phpwcms... is there a way i could shut down phpwcms where i can make template & conent development changes without the public being able to view it... other than moving everything to a sub folder
also when i hit preview it takes me to the same view that the public sees...
visible for users logged on only doesn't seem to work
also when i hit preview it takes me to the same view that the public sees...
visible for users logged on only doesn't seem to work
Welcome!
You could do the following:
Place a file called index.html into your phpwcms root folder with some content like this:
Then change (or add) in apache2.conf (or whereever your site conf is living)
Restart your Apache
That's it.
Now when somebody enters http://www.yoursiteaddress.tld he gets the index.html with "Coming soon ;- )"
Give it a try
Greetings
claus
You could do the following:
Place a file called index.html into your phpwcms root folder with some content like this:
Code: Select all
<html>
<head>
<title>This page is under construction.</title>
</head>
<body background="bg.gif" bgcolor="#333366" text="#FFFFFF" link="#0066CC"
vlink="#999999" alink="#993300">
<table width=100% height=100% border=0>
<tr><td align=center valign=center>
<font face="century gothic, Arial, Helvetica">
<p><font face="Arial Black">
Coming soon ;-)
</font>
</td></tr>
</table>
</body>
</html>
Code: Select all
DirectoryIndex index.html
Options -Indexes
#no index.php! This you can enter into browser by hand...
#Later on you would like to add index.php (first item then) to let your site live
That's it.
Now when somebody enters http://www.yoursiteaddress.tld he gets the index.html with "Coming soon ;- )"
Give it a try
Greetings
claus
or just save index.html to your root directory with link to your old projekt/server:
greetz
Code: Select all
<HTML>
<HEAD>
<TITLE></TITLE>
<META http-equiv=Refresh Content="0; url=http://www.server.com/old/projekt/or/something/">
</HEAD>
</HTML>
I belive that parkley want ability to temporarily close the phpWcms front for non admin users.
Solution like special index.html file in site root will not stop visitors to browse the phpWcms pages accesed directly, by typeing the URL directly into their browser, or from search engines that index the site.
Solution like special index.html file in site root will not stop visitors to browse the phpWcms pages accesed directly, by typeing the URL directly into their browser, or from search engines that index the site.
such a feature is NOT available yet(?)
but instead USE
.htaccess to prevent robots from indexing php-files
OR grant access to certain users (prevent directory)
usual server authentication with user/pwd
OR develop your site in a sub directory. move all files and adjust --> config and settings (only once) when ready to go online --> afterwards, later
OR work --> local using
XAMPP (windows)
MAMP (mac)
to able to ftp/move your site as a whole to the "live-server"
greetz
but instead USE
.htaccess to prevent robots from indexing php-files
OR grant access to certain users (prevent directory)
usual server authentication with user/pwd
OR develop your site in a sub directory. move all files and adjust --> config and settings (only once) when ready to go online --> afterwards, later
OR work --> local using
XAMPP (windows)
MAMP (mac)
to able to ftp/move your site as a whole to the "live-server"
greetz
Of course you know, you wrote that.Jensensen wrote: i know as well,

Nothing, but this guy clearly asked for replacement for working in a sub directory(please read again first post). I believe he asked for ability to temporarily close the phpWcms front for non admin users. This feature is usual called "Down for Maintenance" and still not part of the phpWcms....not for a long time I believe. With coming user managment system this can be done very easy.Jensensen wrote:what IS to be said against working in a sub directory?
Ok..again, solution like special index.html file in site root will not stop visitors to browse the phpWcms pages accesed directly, by typeing the URL directly into their browser, or from search engines that index the site.Jensensen wrote:..or using index.html???
Re: how do you disable the site from being seen to work behi
Unless things have changed in the very latest version, if you are logged in to the backend you will be able to preview everything, including pages where you have turned visible/public 'off'. This is so you can work on them and preview the results. Ordinary site visitors however cannot see those pages. Log out to see the difference.parkley wrote:also when i hit preview it takes me to the same view that the public sees...
AFAIK that feature is not enabled as yet.visible for users logged on only doesn't seem to work
I think most Apache servers will run index.html before index.php, so as claus suggests, a simple 'We are closed for maintenance' HTML file should do.
Unless I am missing something, Peekay has given the answer that ~sounds~ correct for the question asked. Additionally, the Start and End dates for "content" can be set for some time in the future (when you anticipate to unveil your finished work) and phpWCMS will not publish it to visitors until that time arrives! 

Re: how do you disable the site from being seen to work behi
it the same result logged in or out.... when i hit preview i see what the public seePeekay wrote: Unless things have changed in the very latest version, if you are logged in to the backend you will be able to preview everything, including pages where you have turned visible/public 'off'. This is so you can work on them and preview the results. Ordinary site visitors however cannot see those pages. Log out to see the difference.

it's like i'm not even logged in, yet i'm logged in hitting the preview button as an admin

Re: how do you disable the site from being seen to work behi
You must be saying that you phpWCMS is always remembering you (logging you in automatically)...is that it ?? You'll have to clear cookies, if logging out doesn't work. Clear your browser cache, too !parkley wrote:it the same result logged in or out.... when i hit preview i see what the public seePeekay wrote: Unless things have changed in the very latest version, if you are logged in to the backend you will be able to preview everything, including pages where you have turned visible/public 'off'. This is so you can work on them and preview the results. Ordinary site visitors however cannot see those pages. Log out to see the difference.
it's like i'm not even logged in, yet i'm logged in hitting the preview button as an admin
The ONLY way you could even be ABLE to hit preview... is IF you are logged in. AND whenever you DO hit preview...You (as Admin) are ALWAYS going to see what the visitors WOULD see if you made the site visible/public -or- article start date is in range.
Mmmh
Did you set
in conf.inc.php?
Then it would be really sufficient to set every main structure link to visible only when logged in, create a user for logging in into frontend only (through an other browser) and voila. Or am I completely wrong?
On the other hand this is true (should be - what else is an admin for?)
Did you set
Code: Select all
$phpwcms['SESSION_FEinit'] = 1; // set 1 to enable sessions in frontend, 0 to disable sessions in frontend
Then it would be really sufficient to set every main structure link to visible only when logged in, create a user for logging in into frontend only (through an other browser) and voila. Or am I completely wrong?
On the other hand this is true (should be - what else is an admin for?)

and much more straightforwardYou (as Admin) are ALWAYS going to see what the visitors WOULD see if you made the site visible/public
Down for Maintenance
Here's a temporary solution, works fine on my test installation...now you can turn off the phpWCMS frontend for non admin users in conf.inc.php, just set $phpwcms['down_for_maintenance'] to 1.
-----------------------------------------------------------
1. Create html file closed.html in phpWCMS root directory
2. Open config/phpwcms/conf.inc.php and enable sessions in frontend:
3. Same file(config.inc.php), add this code under // other stuff group:
4. Open index.php and find this line: require_once (PHPWCMS_ROOT.'/config/phpwcms/conf.template_default.inc.php');
and add the following code before/above:
-----------------------------------------------------------
1. Create html file closed.html in phpWCMS root directory
2. Open config/phpwcms/conf.inc.php and enable sessions in frontend:
Code: Select all
$phpwcms['SESSION_FEinit'] = 1;
Code: Select all
$phpwcms['down_for_maintenance'] = 1; // set 1 to disable frontend for non admin users
and add the following code before/above:
Code: Select all
if($phpwcms["down_for_maintenance"] && empty($_SESSION["wcs_user_admin"])) {
headerRedirect($phpwcms['site'].$phpwcms["root"].'closed.html');
}