Note that there are some explanatory texts on larger screens.

plurals
  1. POzend-framework problem using routes
    primarykey
    data
    text
    <p>UPDATE:</p> <p>Turns out it's not only the routing, but any instance of going 'up' a directory. </p> <p>For example <code>mysite.com/public</code> serves me the correct index.phtml file... <code>mysite.com/index/testpage</code> DOES serve me the testpage.phtml, but my directory structure is completely screwed and I lose all links to images &amp; Stylesheets etc. I've checked my .htaccess and it's exactly as recommended.</p> <p>Serious head-scratching time here... </p> <p><strong>OP:</strong> </p> <p>Hello..</p> <p>I'm using this method for catching urls and serving up the correct content</p> <pre><code>$router-&gt;addRoute( 'list', new Zend_Controller_Router_Route('/list', array('controller'=&gt;'index', 'action'=&gt; 'list')) ); </code></pre> <p>And it works really well, serves up the content from list.phtml... </p> <p>but, the moment I attempt anything 'up' a directory such as this I lose all my style sheets and other relative scripts.</p> <pre><code>$router-&gt;addRoute( 'listWithUsers', new Zend_Controller_Router_Route('/list/:users', array('controller'=&gt;'index', 'action'=&gt; 'list')) ); </code></pre> <p>It's strange because I can access the <code>users</code> variable and <code>echo</code> it to screen, it's just that I lose all scripts and stylesheets whenever a URL contains <code>/</code></p> <p>For clarity, I'm able to set actions in the <code>indexController.php</code> to catch URLS and it works, but it seems to serve it as another directory causing me to lose all relative links.</p> <p>Thanks for any help. Please advise if any specific details would help.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload