SunRa

Introduction

What is SunRa?

SunRa is a server-side webscripting language. It's especially suitable for writing larger applications. SunRa's functionality is basically that of PHP:

In fact, SunRa code is converted (compiled) to PHP code. This means no additional software needs to be installed on the server, any PHP 5.3 server will do.

So why use SunRa? In addition to functionality inherited directly from PHP, SunRa has a lot of useful features:

These features prevent many run-time errors, while your code becomes simpler and cleaner. The generated code is optimized and inlined resulting in a performance boost.

Hello World!

The classical Hello World script in SunRa is quite simple. Simply make a file called hello.sr containing one statement:

print 'Hello world!'

Now we can compile the file: $ python sunra-c.py hello.sr. The resulting file hello.php looks like this:

<?php
print 'Hello world!';