Questions tagged [zend-layout]

Zend_Layout: Part of the Zend Framework that combines the ideas behind Composite view and Two Step View

There are two design patterns that Zend Framework uses to implement layouts: » Two Step View and » Composite View. Two Step View is usually associated with the » Transform View pattern; the basic idea is that your application view creates a representation that is then injected into the master view for final transformation. The Composite View pattern deals with a view made of one or more atomic, application views.

In Zend Framework, Zend_Layout combines the ideas behind these patterns. Instead of each action view script needing to include site-wide artifacts, they can simply focus on their own responsibilities.

Source

82 questions
1
vote
4 answers

Zend MVC - I echo some test debug output but it seems to be suppresed and does not show

I am developing a Zend MVC application. Sometimes I like to echo some text just for quick and dirty debugging. e.g But, when text is…
JW.
  • 4,821
  • 5
  • 43
  • 60
1
vote
3 answers

Zend Layout - A "Smart" layout selector

I currently have Zend setup to look for a layout script in each module's view/scripts/layout.phtml file (ie: /application/modules/moduleName/scripts/layout.phtml). This is by setting layout[] to nothing (blank) in the application.ini file…
Ryan
  • 17,511
  • 23
  • 63
  • 88
1
vote
1 answer

setting layout file for module inside bootstrap in zend

My zend application structure: application ->configs ->layouts ->scripts ->admin.phtml ->site.phtml ->modules ->admin(controllers, models, views) ->Bootstrap.php ->default(controller,models,views) …
rockstar
  • 1,322
  • 1
  • 20
  • 37
1
vote
2 answers

How do I pass variables to a layout in a multiple module / layout Zend Framework application?

Before I converted my Zend Framework application to a module based structure, it had a single layout and I could pass variables to it from my controller like so: // Controller action $this->view->foo = 'Something'; // Layout foo…
Kris
  • 1,094
  • 3
  • 13
  • 23
0
votes
2 answers

Passing variables to layout after bootstrapping layout resource

I had to create method in Boostrap which bootstraps Layout resource and registers some view helpers. protected function _initViewHelpers() { $this->bootstrap('layout'); $layout = $this->getResource('layout'); $view =…
Kacper Kołodziej
  • 698
  • 1
  • 9
  • 23
0
votes
1 answer

zend paginator not including CSS

i have used zend paginator in my app its working fine the way its .but when i click on any link i mean any pagination it query right info but the css is not applied there.initially when page renders all the css is applied properly but when i click…
Fawad Ghafoor
  • 6,039
  • 7
  • 41
  • 53
0
votes
1 answer

Why no Zend_Layout helper or codebehind? And best way to

I was just wondering why no code-behind or helpers were made to work with layouts? I have stuff I want to display in my layouts without having to set it up in a placeholder for every single controller. I was also wanted to know what is the best way…
Walt
  • 1,521
  • 2
  • 13
  • 29
0
votes
1 answer

Zend Framework: add data to layout for every action of controller

i am writing a web application and i need all the data returned/computed in all actions of one specific controller to return data to the layout (not the view). So after each action, a controller variable needs to be passed to the layout so the…
0
votes
2 answers

Line breaks and white lines of Zend layout.html output

As per the Zend Framework standard, I'm using Zend_Layout. zf create project demo cd demo zf enable layout That's it Here's my config: [production] phpSettings.display_startup_errors = 0 phpSettings.display_errors = 0 includePaths.library =…
Lance
  • 30
  • 4
0
votes
2 answers

Zend Framework: Is there a View Helper to display View Name in Layout Class?

As the title suggests, I'm trying to find a way of displaying the title of the View currently being displayed as part of the layout. I'm trying to do this so that the page title is dynamicly populated when a different view is selected. In…
8bitjunkie
  • 12,793
  • 9
  • 57
  • 70
0
votes
1 answer

Zend Framework 1.11 Layout classes etc

just started using Zend Framework and I'm wondering what to do with odd classes I have. I'm pretty much wondering about best practise for getting everything setup. I've just enabled layout and I have the wrapping html head, body, footer etc. In my…
0
votes
2 answers

Zend_Layout + helperClass

I am try to use helperClass in Zend_Layout options. I create a class: class Helper_Testi extends Zend_Controller_Action_Helper_Abstract{ public function init(){ echo "111111111"; $this->fff = 'hello from Helper'; } …
Eugene
  • 1,690
  • 3
  • 16
  • 30
0
votes
1 answer

css problem in action on Zend Framework

Not sure what I'm doing wrong here, but it seems that the framework is only able to find the style.css on my index actions on every controller. I'm calling it from the layout.phtml like…
biggest_rage
  • 31
  • 1
  • 1
  • 8
0
votes
2 answers

Zend Portlet Kind of a Layout

I am using Zend Framework. Want to make a portlet kind of view, which is like each div is generated by a different controller/view pair. Like the layout -
layout()->news; ?> -- calls news/recent
Nandini Bhaduri
  • 1,835
  • 4
  • 18
  • 31
0
votes
2 answers

rendering layout on the production server

My productionserver is not able to render my loginlayout. On my development system everything works fine. Here comes the error on the production website: Fatal error: Uncaught Zend\View\Exception\RuntimeException:…
pia-sophie
  • 505
  • 4
  • 21