Frequently Asked Questions

Oct 10, 2024 - 06:21am

 [F] Frequently Asked Questions  / Appearance  /

WCTL, WCJS, or HTML Displayed Raw

Rate This FAQ
Rating: **** (based on 2 votes)

Created On: 4 Feb 2005 10:59 am
Last Edited: 18 Mar 2010 12:57 pm

Question Printer Friendly

I have placed some code into a HTML page or folder or discussion description and Web Crossing is showing the raw code rather than interpreting it.

Answer


  1. In your General Settings Control Panel, make sure that either or both (depending on what you need) of the following are checked off: "Treat all sysop headings as WCTL templates" and/or "Treat all host headings as WCTL templates". Sometimes after doing this you will need to resubmit the folder/discussion description (with no changes) to get it to start intrepreting.
  2. If you have checked "Enable the template-enabled user-group" in the Registered Users/Security Control Panel, the user(s) posting the code need to be members of the defined group.
  3. If you are using the "Change Author" extension, you probably left it on. This extension is only designed for temporary use: turn it on, change the author, then deactivate it.
  4. If this is an HTML file (web file), be sure you have the correct content-type set in the "Content-type:" field per the instructions located immediately below it. To interpret WCTL/JS, the content type has to also include an asterisk "*". You will see the field when you Edit your page from within the Web Crossing GUI.
  5. If you are seeing this phenomena at only the top level of your site, and code otherwise works as it should in subfolders, then somehow a "content type" has been set on the top level folder when there shouldn't be one. This can be from an import, or an ill behaved macro or other reasons. What you need to do is execute the code snippet below to clear the top level content type:

Example
%% macro resetCT %%

%% // 

Place this macro at the top of webx.tpl.
Save the file, and reset the cache.
Then call the macro via http://yoursite..../webx?resetCT@@
%%
     <html>
     %% setPath ("/") %%
     ContentType of top level was: %% pathContentType %%<br>
     %% setPathContentType("") %%
     Now: %% pathContentType %%
     %% setPath %% 
     <P>Done.
     </html>
%% endmacro %%