Search Results

Search found 4341 results on 174 pages for 'zend navigation'.

Page 29/174 | < Previous Page | 25 26 27 28 29 30 31 32 33 34 35 36  | Next Page >

  • how to get last inserted id - zend

    - by Lemon
    I'm trying to get latest inserted id from a table using this code: $id = $tbl->fetchAll (array('public=1'), 'id desc'); but it's always returning "1" any ideas? update: I've just discovered toArray();, which retrieves all the data from fetchAll. The problem is, I only need the ID. My current code looks like this: $rowsetArray = $id->toArray(); $rowCount = 1; foreach ($rowsetArray as $rowArray) { foreach ($rowArray as $column => $value) { if ($column="id") {$myid[$brr] = $value;} //echo"\n$myid[$brr]"; } ++$rowCount; ++$brr; } Obviously, I've got the if ($column="id") {$myid[$brr] = $value;} thing wrong. Can anyone point me in the right direction? An aternative would be to filter ID's from fetchAll. Is that possible?

    Read the article

  • Draw text on a loaded pdf file with Zend Framework

    - by Rick de Graaf
    Hello, I'm trying to load a existing pdf file, and fill this with database information. Loading the file and everything is working, except for writing data to the loaded page. It doesn't write text to the loaded page. If I add a new page en use a foreach to apply drawing to all pages, all added pages are written, except for the loaded one. Below is the code I'm using: $pdf = Zend_Pdf::load('./documents/agreements/_root/gegevens.pdf'); // Load pdf $pdf->pages = array_reverse($pdf->pages); // reverse pages $pdf->pages[] = new Zend_Pdf_Page(Zend_Pdf_Page::SIZE_A4); // Add a page (A4) $font = Zend_Pdf_Font::fontWithName(Zend_Pdf_Font::FONT_HELVETICA); // Set font foreach($pdf->pages as $page) // Apply settings+text to every page (total of 2) { $page->setFont($font, 36); $page->setAlpha(0.25); $page->drawText('LALALALALALALA', 62, 260, 'UTF-8'); } $pdf->save('./documents/agreements/Gegevens_'.$this->school_id.'.pdf'); // Save file

    Read the article

  • Zend Framework PDF to excel type

    - by Uffo
    How can I make something like this with Zend_PDF: I have a few columns A, B, C, D, E and after them I will have some information, something like excel. A | B | C | D ss|das|dad|ds ss|das|dad|ds ss|das|dad|ds How can I create something like this with ZF_pdf? I will pull the data from DB, can you please give me an example?

    Read the article

  • Zend Framework table Relationships

    - by Uffo
    I have a table with over 4 million rows, I want to split this table in more tables, i.e one table with 50k rows. I also need to perform a search on these tables, whats the best way to do it? with JOIN, or? do you have some better ideas? Best Regards,

    Read the article

  • need advice on Zend framework Application architecture, or say approach dealing with modules

    - by simple
    Let me start with the things that I did and how am I using some things to get results I have set up modular structure as: application/ /configs /layouts /models /modules /users /profile /frontend /backend /controllers /views .... I write a plugin that does addes changes with FrontController-setModuleControllerDirectoryName() FrontController-addModuleDirectory() and It is all good I have a changed all the directories according weather admin page is requested in the url or not (it is some thing like /admin/some/some) Let's say I have a single layout for anything that is related to Profile viewing , in this case the "Profile" module. The Profile layout is divided into three parts In the layout I was pulling out the Profile/PhotoController 's index action with a action() $this->action('index', 'photo', 'profile'); Then I have faced few issues 1. Can get passed Params inside the Photo Controller when calling ( profile/profile/index); 2. found out that helper Action() is evil cause it starts another dispatching loop =) --- and now I am thinking that my approach on plugging in controllers modules into layout also evil =). anyhow how Should I deal with plugging in some controllers (another module controllers) into the layout ?

    Read the article

  • Zend Framework Router Getting /module/VALUE/controller/action

    - by cappuccino
    I've been googling around and I can't seem to find anything which explains the use of ZF router well. I've read the documentation on the site, which seems to only talk about re-routing. I am trying to make the format: /module/value/controller/action give /module/controller/action passing on value as a parameter e.g. /store/johnsmithbigsale/home/newstuff would route to /store/home/newstuff passing on johnsmithbigsale as the value to a parameter with a hidden namespace e.g. storeName. Some help would be greatful!

    Read the article

  • Zend Framework - routes - all requests to one controller except requests for existing controllers

    - by se_pavel
    How to create route that accept all requests for unexsting controllers, but leave requests for existing. This code catch all routes $route = new Zend_Controller_Router_Route_Regex('(\w+)', array('controller' = 'index', 'action' = 'index')); $router-addRoute('index', $route); how should I specify route requests like /admin/* or /feedback/* to existing adminController or feedbackController?

    Read the article

  • Zend framework helper intellisense

    - by Nicky De Maeyer
    Not so much a programming problem, but more a productivity problem. We've got quite a few custom view and action helpers in our project. Working with around 7 programmers. Now when someone, creates a helper or if one would want to use a helper, it all goes through the brokers. This means we do not get intellisense for those helpers, which can be real time consuming, having to go look in the docs or the code files. This is ofcourse true for both build in and custom helpers. Does any1 share this pain? Does any1 have a solution for this?

    Read the article

  • Problem in getting week number of sundays , in zend

    - by Linto davis
    I want to get the week number of a particular date , using Zend_Date My local is setted as English(IN) [en_IN], in Opera browser I am using the following code $date = new Zend_Date('22 Mar, 2010', null, Zend_Registry::get('Zend_Locale')); echo $date->get(Zend_Date::WEEK); //output 12, correct But if we give a sunday , it will not work correctly for example $date = new Zend_Date('21 Mar, 2010', null, Zend_Registry::get('Zend_Locale')); echo $date->get(Zend_Date::WEEK); //output 11, not correct it should output 12 What is wrong with this?

    Read the article

  • Replying to mail with attachments using Zend framework..

    - by Ali
    Hi guys I'm integrating basic email capabilities in my application and I would like to be able to incorporate a decent reply / forward email facility. I have it covered with sending my own uploaded attachments but what about in situations where I recieve a message in my inbox with attachments and wish to forward that same message along with the attachments already attached to it as well as be able to choose which of the attachments to include and which not to.

    Read the article

  • [Zend] phpUnit - assertQuery fails with

    - by Rosina Bignall
    I am having trouble with an assertQuery(). In the html I have (verified by outputting the body) <input type="text" name="LASTNAME" id="LASTNAME" value="" maxlength="25" size="20" /> So I wrote a query for it to test to make sure this element exists and that the value is empty $this->assertQuery('input#LASTNAME[value=""]', 1); PhpUnit says the assertion fails Failed asserting node DENOTED BY input#LASTNAME[value=""] EXISTS Can you give me some insight into why this assertion fails and how to write it properly? Thanks in advance!

    Read the article

  • Strategies for generating Zend Cache Keys

    - by emeraldjava
    ATM i'm manually generating a cache key based on the method name and parameters, then follow to the normal cache pattern. This is all done in the Controller and i'm calling a model class that 'extends Zend_Db_Table_Abstract'. public function indexAction() { $cache = Zend_Registry::get('cache'); $individualleaguekey = sprintf("getIndividualLeague_%d_%s",$leagueid,$division->code); if(!$leaguetable = $cache->load($individualleaguekey)) { $table = new Model_DbTable_Raceresult(); $leaguetable = $table->getIndividualLeague($leagueid,$division,$races); $cache->save($leaguetable, $individualleaguekey); } $this->view->leaguetable = $leaguetable; .... I want to avoid the duplication of parameters to the cache creation method and also to the model method, so i'm thinking of moving the caching logic away from my controller class and into model class packaged in './model/DbTable', but this seems incorrect since the DB model should only handle SQL operations. Any suggestions on how i can implement a clean patterned solution?

    Read the article

  • Dataflow in Controllers & Layouts in Zend Framework

    - by favo
    I use a basic setup which uses a layout.phtml for the HTML Layout and view scripts for the content part. I want to control some variables in the layout in my controllers, i.e. the title of my site. How can I access my layout to output variables from within the controller? Thanks for your feedback!

    Read the article

  • Zend Framework decorator subform add a class tag to DD wrapper tag

    - by Samuele
    I have this form: class Request_Form_Prova extends Zend_Form { public function init() { $this->setMethod('post'); $SubForm_Step = new Zend_Form_SubForm(); $SubForm_Step->setAttrib('class','Step'); $this->addSubform($SubForm_Step, 'Chicco'); $PrivacyCheck = $SubForm_Step->createElement('CheckBox', 'PrivacyCheck'); $PrivacyCheck->setLabel('I have read and I agre bla bla...') ->setRequired(true) ->setUncheckedValue(''); $PrivacyCheck->getDecorator('Label')->setOption('class', 'inline'); $SubForm_Step->addElement($PrivacyCheck); $SubForm_Step->addElement('submit', 'submit', array( 'ignore' => true, 'label' => 'OK', )); } } That generate this HTML: <form enctype="application/x-www-form-urlencoded" method="post" action=""> <dl class="zend_form"> <dt id="Chicco-label">&nbsp;</dt> <dd id="Chicco-element"> <fieldset id="fieldset-Chicco" class="Step"> <dl> <dt id="Chicco-PrivacyCheck-label"><label for="Chicco-PrivacyCheck" class="inline required">I have read and I agre bla bla...</label></dt> <dd id="Chicco-PrivacyCheck-element"> <input type="hidden" name="Chicco[PrivacyCheck]" value=""><input type="checkbox" name="Chicco[PrivacyCheck]" id="Chicco-PrivacyCheck" value="1"> </dd> <dt id="submit-label">&nbsp;</dt> <dd id="submit-element"> <input type="submit" name="Chicco[submit]" id="Chicco-submit" value="OK"> </dd> </dl> </fieldset> </dd> </dl> </form> How can I add a class="Test" to the <dd id="Chicco-element"> elemnt? In order to have it like that: <dd id="Chicco-element" class="Test"> I thought something like that but it don't work: $SubForm_Step->getDecorator('DdWrapper')->setOption('class', 'Test'); OR $SubForm_Step->getDecorator('DtDdWrapper')->setOption('class', 'Test'); How can I do it? And last question: How can I wrap that DD and DT element of a SubForm in another DL element? Like that: ( second line ) <dl class="zend_form"> <dl> <dt id="Chicco-label">&nbsp;</dt> <dd id="Chicco-element"> <fieldset id="fieldset-Chicco" class="Step"> <dl> .......

    Read the article

  • Zend not autoloading models

    - by Guy
    Ok, this is driving me nuts! I have a directory structure as follows: application - modules -- default --- controllers --- models ---- DbTable ---- Cachmapper.php --- views My config file looks like this [production] phpSettings.display_startup_errors = 0 phpSettings.display_errors = 0 includePaths.library = APPLICATION_PATH "/../library" bootstrap.path = APPLICATION_PATH "/Bootstrap.php" bootstrap.class = "Bootstrap" resources.frontController.moduleDirectory = APPLICATION_PATH "/modules" resources.modules[] = The application seems to work, if I navigate to localhost, it correctly goes to the index controller. But, for some reason it refuses to load any models. Fatal error: Class 'Model_Cachmapper' not found in .............................../application/modules/default/controllers/IndexController.php on line 26 Ideas? Thanks

    Read the article

< Previous Page | 25 26 27 28 29 30 31 32 33 34 35 36  | Next Page >