Yii Framework Forum: [Extension] Razor View Renderer - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

[Extension] Razor View Renderer The view templates renderer of razor syntax Rate Topic: -----

#1 User is offline   Krab 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 3
  • Joined: 11-August 10

Posted 11 August 2010 - 07:48 AM

Hello,
I want to present my RazorViewRenderer extension.
This is port of ASP.NET 4.0 "Razor" view engine.

Razor does not require you to explicitly close the code-block.

Compact, Expressive, and Fluid: Razor minimizes the number of characters and keystrokes required in a file, and enables a fast, fluid coding workflow. Unlike most template syntaxes, you do not need to interrupt your coding to explicitly denote server blocks within your HTML. The parser is smart enough to infer this from your code. This enables a really compact and expressive syntax which is clean, fast and fun to type.

Easy to Learn: Razor is easy to learn and enables you to quickly be productive with a minimum of concepts. You use all your existing language and HTML skills.

All source code could be found at code.google.com under MIT License.
Also see example syntax and configuration at wiki page Getting Started here

Hello world template:
<h1>Hello world sample with Razor</h1>

<p>
   Hello @$name, Today is: @date("Y-m-d")
</p>

<div>
    <a href="@Yii::app()->params['baseUrl']/login">Login</a>
</div>


Thank you.
0

#2 User is offline   willowdan 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 26
  • Joined: 03-September 10

Posted 10 September 2010 - 12:02 AM

Trying it now in while learning Yii ...

Cheers!
0

#3 User is offline   M.C. 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 3
  • Joined: 02-January 11

Posted 04 January 2011 - 04:00 PM

I get an error: "Property "CWebApplication.viewRenderer" is read only."
How do I fix this?
0

#4 User is offline   Mazlan 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 1
  • Joined: 09-March 11

Posted 09 March 2011 - 09:58 AM

Great :) I come from asp.net mvc 3, just want to use Yii. I don't know it can extend the view renderer, Yii-Razor are possible. It should have built into the official core. Lets make it popular and someone may develop highlighter for Eclipse/Aptana/NetBean?. I am very tired with smarty like template.

Based on this wiki, I think maybe you miss the server side comment @* *@.
0

#5 User is offline   Jonatha 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 2
  • Joined: 20-March 12

Posted 20 March 2012 - 12:02 PM

Hello, guys I'm new to the framework, is I'm trying to use this extension more without success, someone could teach me how to use, until the use of the facility?
0

#6 User is offline   fouss 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 385
  • Joined: 05-October 10
  • Location:Bamako Mali

Posted 21 November 2013 - 02:59 AM

It's seems not working anymore.
Posted Image
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users