Yii Framework Forum: Help Regarding Yii And Backbone. - Yii Framework Forum

Jump to content

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

Help Regarding Yii And Backbone. Help Regarding Yii and Backbone. Rate Topic: -----

#1 User is offline   Meghraj Choudhary 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 13
  • Joined: 30-November 12

Posted 01 March 2013 - 09:59 AM

Yii is awesome, and backbone too? i want to use both in my next project. but i never want to heavily dependent on javascript, can't loose seo etc.?
So how i can make a app where i declare all url rules in one place, all same template, same models? and make its effect automatic in backbone?
so website can work without js (Not all functionality but almost every page)?

i search a lot for good php and backbone related libs and stuffs? but cat't find much?

i just want to know what do use in this kind of apps and want know your experiences and suggestions and if any good stuffs related to this?
0

#2 User is offline   jacmoe 

  • Elite Member
  • Yii
  • Group: Moderators
  • Posts: 2,601
  • Joined: 10-October 10
  • Location:Denmark

Posted 01 March 2013 - 10:28 AM

You can't use Backbone with JavaScript turned off. Sorry. :)

I mean: Backbone is JavaScript..

And the best approach is to use Yii as a REST backend for the Backbone frontend.

Which leads to a possible solution to users turning off JavaScript: you simply need to code a separate, non-REST, non-JavaScript Yii application in a different sub-domain. If you need it.

There are already a lot of high profile sites which requires JavaScript. So you shouldn't feel bad about require that your users turn it on.
"Less noise - more signal"
0

#3 User is offline   jacmoe 

  • Elite Member
  • Yii
  • Group: Moderators
  • Posts: 2,601
  • Joined: 10-October 10
  • Location:Denmark

Posted 01 March 2013 - 10:30 AM

If you need a good resource for Yii and Backbone together, read this:
http://www.yiiframew...s-applications/
"Less noise - more signal"
0

#4 User is offline   Meghraj Choudhary 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 13
  • Joined: 30-November 12

Posted 02 March 2013 - 12:55 AM

Thanks jacmoe, i want at least solution for auto genrating backbone models from yii, i will do it myself, if there is nothing stuffs like, i really don't like to reinvent wheels
0

#5 User is offline   waitforit 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 383
  • Joined: 09-February 11

Posted 02 March 2013 - 01:09 AM

sorry to jump on your thread and it may be useful for me to start a new one but..

Why?

What is the reason to use a frontend JS framework instead of views rendered by the server, either in whole or in part(ajax)? I understand at a high level how the architecture works, just looking for a use case.
0

#6 User is offline   jacmoe 

  • Elite Member
  • Yii
  • Group: Moderators
  • Posts: 2,601
  • Joined: 10-October 10
  • Location:Denmark

Posted 02 March 2013 - 04:04 PM

Go to Codeschool.com and try their free Backbone course, and become convinced that Backbone rocks if you want to create highly interactive applications in the browser. -> Codeshool - Anatomy of Backbone

If you want to do the same thing - JavaScript applications - without Backbone, and using Yii for the back-end, you will quickly end up with a total mess! And it might not even be totally JS driven.

Try it. :)
"Less noise - more signal"
0

#7 User is offline   outrage 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 313
  • Joined: 10-November 09
  • Location:Blackpool, United Kingdom

Posted 02 March 2013 - 09:56 PM

Once we get around the SEO implications of a JavaScript rendered page (touched on here), Javascript will become the king of web development. imho :)
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