Protected page shows only code

All WYSIWYG Web Builder support issues that are not covered in the forums below.
Forum rules
IMPORTANT NOTE!!

DO YOU HAVE A QUESTION OR PROBLEM AND WANT QUICK HELP?
THEN PLEASE SHARE A "DEMO" PROJECT.



PLEASE READ THE FORUM RULES BEFORE YOU POST:
http://www.wysiwygwebbuilder.com/forum/viewtopic.php?f=12&t=1901

MUST READ:
http://www.wysiwygwebbuilder.com/getting_started.html
WYSIWYG Web Builder FAQ
Post Reply
rogerr
 
 
Posts: 58
Joined: Fri Feb 02, 2018 2:43 am

Protected page shows only code

Post by rogerr »

I have made a page with My Crud extension that is password protected by the "Single Page Protect"
It only shows code after the login instead of the page. Without the protection, the page works
correctly,

Roger
User avatar
BaconFries
 
 
Posts: 5800
Joined: Thu Aug 16, 2007 7:32 pm

Re: Protected page shows only code

Post by BaconFries »

Have you set the page extension to .php? Also note if trying to view locally then it is not possible due to you must publish to a server that supports php.
rogerr
 
 
Posts: 58
Joined: Fri Feb 02, 2018 2:43 am

Re: Protected page shows only code

Post by rogerr »

The page has .php extension. If I take off the protected page lock, it works correctly.

Roger
User avatar
Pablo
 
Posts: 23029
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: Protected page shows only code

Post by Pablo »

Single page protect cannot be used to protect a page with PHP code.
But you can use the other login tools to the protect the page.
rogerr
 
 
Posts: 58
Joined: Fri Feb 02, 2018 2:43 am

Re: Protected page shows only code

Post by rogerr »

Thanks Pablo,

I thought it might be a conflict with the php and single page protect. I
just used the Apache directory security which accomplished what I needed.
mcruss
 
 
Posts: 38
Joined: Wed Dec 22, 2010 2:20 pm
Location: Texas
Contact:

Re: Protected page shows only code

Post by mcruss »

I realize this is an old post but I'm having the same problem. I don't understand the response to the original poster: It seems it says "use extension php for the page and then "you can't use 'Single Page Protect' for a page with PHP code". Seems to conflict but I must be missing something.

2nd part of the issue: I switched from PHP to Javascript protection but it still shows the PHP code. I looked at the files on the host and the php file is apparently overriding the html extension. Do I need to delete the file with php extension to get Javascript to work?
User avatar
Pablo
 
Posts: 23029
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: Protected page shows only code

Post by Pablo »

To be able to help you, I need a demo project so I can see all your settings.

Notes:
- the page must be published to a web server with PHP support
- the extension of the page must be PHP
- the page may not contain PHP code (like a form script for example), because the contents of the file will be sent to the browser "AS IS"
mcruss
 
 
Posts: 38
Joined: Wed Dec 22, 2010 2:20 pm
Location: Texas
Contact:

Re: Protected page shows only code

Post by mcruss »

OK, I did a 'demo' page and it works fine so all the settings are correct. I suspect the issue is with the files on the host. I've experimented with other file extensions (asp and html) and these files are still out there on the host. Should I delete these? I just re-published the page with PHP extension and the php and css files are current there. One clue is that I changed the Intro Message on the login before re-publishing and the old message still shows up in the code.
User avatar
Pablo
 
Posts: 23029
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: Protected page shows only code

Post by Pablo »

To be able to help you, I need to see what you have done.
However, in general when the PHP code is shown in the browser then there is an issue on the server side.
mcruss
 
 
Posts: 38
Joined: Wed Dec 22, 2010 2:20 pm
Location: Texas
Contact:

Re: Protected page shows only code

Post by mcruss »

Thanks for your offered assistance but I'm sure now that the problem lies with either the server or files on my PC. I'm sure I can make it work now.
However, this is the demo page. As you can see, all is working fine here (php extension.)

http://www.championsruncondos.com/demo.php

Russ
Post Reply