PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Wednesday, May 18, 2022

[FIXED] How to use partial to access application's scripts?

 May 18, 2022     partial, php, zend-framework     No comments   

Issue

I know to access scripts from another module, you just pass the module name as second argument, but I can't find how to access scripts from application/views folder.

I tried as follow, but didn't work :

echo $this->partial('myscript.phtml', 'application', $this);
echo $this->partial('myscript.phtml', '', $this);

But none worked.


Solution

Try this:

echo $this->partial('myscript.phtml', 'default', $this);

The main application is commonly reffered to as the 'default' module.



Answered By - Joel Lord
Answer Checked By - Robin (PHPFixing Admin)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing