Solved

Tcl/CMS command to tell whether I'm currently on the dev or live site?

Posted on 2002-06-11
3
207 Views
Last Modified: 2010-03-17
Can I with a Tcl command tell whether I'm on the development or the live site?

// Anders
0
Comment
Question by:Ruskin
3 Comments
 

Accepted Solution

by:
davemas earned 100 total points
ID: 7076630
Certainly you can, just use [SHOW PM_HOST] and
[SHOW PM_PORT] and this will give you the CDS host:port
information you want, and from them you can know if its the Live CDS or the development CDS .  

Another way is to declare a local
var in your delivery.tcl with the host and port of your CDS but this is not necessary as Vignette provides you the same information:

If the two CDS are on diferent machines:

on the delivery.tcl from the Live CDS :  
  SET PORT_LIVE 83
  SET HOST_LIVE 140.25.52.21  

on the delivery.tcl from the Live CDS :  
  SET PORT_DEV 81
  SET HOST_DEV 140.25.52.22  

if the two CDS are on the same machine :
  SET PORT_LIVE 83
  SET PORT_DEV 81
  SET HOST_CDS 140.25.52.21  

0
 

Author Comment

by:Ruskin
ID: 7077678
Thanks Davemas!

Regards
// Anders
0
 
LVL 2

Expert Comment

by:memerot
ID: 9069271
You probably want to put this in a library, and in that library set any variables that are box specific.  Then include that library in all the pages that reference the box name for generating links, etc.  I used to use HTTP_HOST and HTTP_SERVER_NAME mostly.
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Join & Write a Comment

Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
This video discusses moving either the default database or any database to a new volume.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now