I created a custom template (mytheme/template/catalog/navigation/left_parent_category.phtml) to display the parent categories of the current category.
<?php
echo '<div class="box base-mini">';
echo '<ol>';
$currentCat = Mage::registry('current_category');
if ( $currentCat->getParentId() == Mage::app()->getStore()->getRootCa...
I would like to use a layout for the emails I'm sending out. I'm currently usine Zend Layout for the web pages, but would like to theme my emails as well.
Here is what I've tried.
This is my function that sends the email
$layout = Zend_Layout::getMvcInstance();
$this->_view->render($template);
$html = $layout->render('emai...
I would like to know how people use Zend_Navigation, what are the best practices to employ to get the most out of it?
My company has built our last 2 major projects using Zend Framework, we have used a combination or Zend_Navigation the url view helper. Using the url view helper has caused lots over extra work when having to refactor c...
Hi,
I am trying to add a HTML multi-column table to a Zend_Form. The table would be populated by data from the database and each row should be preceded by a checkbox, as shown in the ASCII below:
+-----+-------------------------+-----------------------+--------------+
| | Column_1 | Column_2 | Column_3 ...
Using Zend_Form, how would I create form elements like this
<input type="text" name="element[1]" value=""/>
<input type="text" name="element[2]" value=""/>
...
Hi!
I have a website. It's my first website with Zend Framework but I think it's written good. Generatiom time is about 0.9s now. I'll do it something like 0.2 but leave it now. When you press any link on the website it tooks about 1,5-2s before web browser is loading page. Then it tooks 0.15s to show it. So if execution time is 0.9 wher...
I'm using Zend_Form from Zend Framework 1.10.6 to render a html form. In this form 'z', there's a subform with a field 'a'. The subform is added to the main form twice, once with the name 'x' and once as 'y'.
Below is the html rendered by the Zend_Form-object.
<form id="z" enctype="application/x-www-form-urlencoded" method="post" actio...
I would like to remove a request parameter from the URL that is displayed in the browser window. I am creating links with special parameters that I want to retrieve in the controller, but aren't necessary after they have been retrieved.
I tried doing this, but it did not work:
$params = $this->_getAllParams();
if (!empty($params['acti...
Hey
I'm trying to do this query using Zend DB select but I'm not able to do so
This is the sql query
select shopping_id,shopping_details,"friend" as type
from shopping
Notice here how I'm specifying "friend" as type and friend is not a column in the shopping table.
Now how do I do this in Zend. I have tried this but it gives me an...
Hi,
Is it possible to take advantege of MSSQL in Zend Framework? I tried run my zend server with pdo_mssql, sqlserver and odbc and failed each time.
Did you menage to use Microsoft database in your project?
Kind Regards,
...
I want to use the URL schemes in Zend Framework like /list?id=2&name=test, something like that, when I do redirection, I call this way: $this->_helper->redirector('index','list','',array('id' => 2, 'name' => 'test'));. But the URL generated will be /list/index/id/2/name/test which makes it inconsistent. How do I prepare a URL scheme like...
I would like to set the repsonse mime type to
application/xhtml+xml
How and where do I set that in Zend Framework? Thanks for your help.
...
I am about to create a menu for a project of mine, and I need to make a dynamic navigation.
In my Admin back end, I will create a form for URI entry, so that the admins can create links and define the parent of the link and their ordering in relation to other links in the parent. I will be doing this with a MySQL database. The question ...
Hello,
I'm trying to whitelabel the Zend framework, so I've created folder in application called Site.
This url: http://local.branch.test.com/site-css/1/layout.css returns a 400 Bad Request.
With the following rule:
RewriteRule ^site-css/([0-9]+)/(.*)$ ../application/site/$1/design/css/$2 [L]
Full .htaccess
RewriteEngine on
Re...
i am wondering by what method are the params of a zend view action helper passed by? get or post. is is becos i cant seem to access them via $_GET & $_POST but i can with $this->getRequest()->getParam("xxx")
then i want to check if the variable exists 1st before using it so i did
$itemsPerPage = isset($this->getRequest()->getParam("ite...
i am just reading on zend view action helpers on zend framework docs. so i created an index action
// index.phtml
...
echo $this->action(
$action = "widgetenabledoutput",
$controller = "index",
$module = null,
array(
"noLayout" => true,
"itemsPerPage" => 15
)
);
// index controller (IndexController.php)
public funct...
i am reading zend framework docs on zend view partials
If your model is an object, you may
want to have it passed as an object to
the partial script, instead of
serializing it to an array of
variables. You can do this by setting
the 'objectKey' property of the
appropriate helper:
// Tell partial to pass objects as 'mod...
I have a website built on ZF. I don't know why but is lagging as hell. Loading simple page tooks 4s. Time is going down when I disable layout. When rendering is enabled it's working normally. So I can use action views but I can't use layouts. Can it be someting bad with layout? Or I'm not setting up layout properly?
Site: http://zgarnij...
So suppose I have the url:
http://url?x=1&y=2
Then I can just get all the get parameters via PHP using the $_GET variable
so print_r($_GET) will echo all the get variables
Now suppose I'm using zend framework and i'm trying to take advantage of the /var/value/var/value feature:
so now my url is
http://url/controller/action/x/1...
i am reading up on zend navigation and was wondering whats good way to set it up.
Where do i setup up? can i do it using application.ini - but it may make application.ini too long to read. maybe using a resource method? maybe a plugin?
do i hardcode all pages? eg.
$pages = array(
array(
'label' => 'Home',
'title' => 'Home p...