CodeCharge Studio

Configuring Publishing Settings

When you publish a page or an entire project, CodeCharge Studio first generates the programming code to the same folder where your project is stored, then it copies the generated files to the web server. The Publishing settings allow you to specify the folder where CodeCharge Studio should output the generated files during the publishing process. You can generate the web application files locally to your hard drive or network, or to external web servers via FTP/SFTP/SSH.

CodeCharge Studio supports publishing to different servers. This allows the developers to publish their applications to different local or remote servers, e.g. first publish the project to a test server (or location) and after the tests complete, switch the publishing server to the deployment one.

Active server

Defines the server for which the settings are to be changed. There can be more than one publishing server defined within a project. It is also possible to read server's setting from an existing CCS project file.

Publishing Files Locally

You can publish the generated files to a local or network web server by selecting the Location "Local/Network" and then configuring the parameters.

Parameter Description
Server Path The file system path where the generated files should be published. In case you use the IIS web server, the server path is usually c:\Inetpub\wwwroot\(project name). If you use Apache, locate the DocumentRoot variable in your configuration file, httpd.conf, and set it to the desired web folder (e.g., c:/web) then set the Server Path in CodeCharge Studio to the same folder. You can also specify a network path here, such as \\network computer\web\My Project.
Server URL This is the web address corresponding to the Server Path. This URL will be used to view the page in Live Page mode. By default, local web servers can be accessed using the URL http://localhost, therefore the Server URL for your project should be http://localhost/MyProject.

You can also use the IP address of your computer, such as http://68.100.100.100/MyProject or the domain name, like http://mydomain.com/MyProject.

The Server URL parameter is also used in the generated programs, for example to redirect users with insufficient privileges to the Login page.

Publishing Files By FTP

You can publish the generated files to a remote Web server by setting Location property to "FTP" and then configuring the following FTP parameters:
Parameter Description
Server The location of your FTP server which can be identified by the domain name or IP address, for example ftp://codecharge.com or ftp://123.123.123.123 etc.
Path/Folder This is the relative folder on your FTP server where the published files should be placed. This path can start with a "/" if your FTP server logs you in at the root folder or if you are aware that the path should start at the FTP server's root.
Login The username to be used to login to the FTP server.
Password The password corresponding to the user login name used to login to the FTP server.
Live site URL This is the web address corresponding to the Server Path. This URL will be used to view the page in Live Page mode. By default, local web servers can be accessed using the URL: http://localhost, therefore the Server URL for your project should be <http://localhost/MyProject>. You can also use the IP address of your computer, such as http://68.100.100.100/MyProject or the domain name, like http://mydomain.com/My Project.
Secure connection (SFTP / SSH) When this option is checked CodeCharge Studio will utilize the SSH protocol rather than standard FTP to publish files to remote location. You can also specify the port number by adding it to the server name after a colon, for example "myserver.com:22".
Passive mode Defines if CCS should connect to the server using the passive mode which is useful when the developer's machine is behind a firewall and can't access the server directly.

The Server URL parameter is also used in the generated programs, for example to redirect users with insufficient privileges to the Login page.

Specifying the Files to Publish

In addition to specifying the local or remote/FTP publishing settings, you can also indicate which types of files you want to publish to the Web server.

Parameter Description
Project Files (code, template and database files) This is the default and recommended option for publishing. It copies to the web server all file types that are commonly used by web applications. For example in case of PHP, these files are: .php (PHP programs), .html (templates), .js (JavaScript), .gif and .jpg (images), and .css (cascading style sheets). And if you store your MS Access database (.mdb) in the project folder, it will be copied to the web server as well. This is also the fastest publishing option.
All files with extensions This option can be used to publish files with specified extensions, for example if you utilize custom file extensions in your project and want to publish them. Note: this publishing option works slower than the publishing Project Files option since CodeCharge Studio needs to search the project folder for all specified file extensions.
All files excluding extensions This option can be used to publish all files, but exclude files with specific extensions. For example to avoid copying MS Access databases to the server each time the project is published. Note: this publishing option works slower than the publishing Project Files option since CodeCharge Studio needs to search the project folder for all specified file extensions.

See also


On-line, printable versions and updates