Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [Symfony] problem z routingiem
harvesterix
post
Post #1





Grupa: Zarejestrowani
Postów: 74
Pomógł: 0
Dołączył: 17.09.2009

Ostrzeżenie: (0%)
-----


Mam problem z wywołaniem stronki na localhoscie, plik routingu:

  1. # default rules
  2. homepage:
  3. url: /
  4. param: { module: main, action: index }
  5.  
  6. #default_index:
  7. # url: /:module
  8. # param: { action: index }
  9.  
  10. #default:
  11. # url: /:module/:action/*


po zakomentowaniu domyslnych sciezek, i wpisaniu w przegladarce stronka.localhost/frontend_dev.php wywala mi 500 internal server error z nastepujaca informacja: Unable to find a matching route to generate url for params "array ( 'action' => 'show', 'module' => 'main', 'id' => '1',)".

Skad ten blad przeciez nie wpisalem zadnej nazwy modulu (ok domyslnie main), ale skad akcja show i jakies id (IMG:style_emoticons/default/questionmark.gif)
Dodam ze po odkomentowaniu domyslnych sciezek(default_index i default) wszystko jest ok

Ten post edytował harvesterix 20.10.2009, 11:29:14
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
harvesterix
post
Post #2





Grupa: Zarejestrowani
Postów: 74
Pomógł: 0
Dołączył: 17.09.2009

Ostrzeżenie: (0%)
-----


po drobnych poprawkach w frontend_dev błąd wygląda tak: Unable to find a matching route to generate url for params "array ( 'action' => 'show', 'module' => 'main')

plik frontend_dev wyglada tak:
  1. if (!in_array(@$_SERVER['REMOTE_ADDR'], array('127.0.0.1')))
  2. {
  3. die('You are not allowed to access this file. Check '.basename(__FILE__).' for more information.');
  4. }
  5.  
  6. require_once(dirname(__FILE__).'/../config/ProjectConfiguration.class.php');
  7.  
  8. $configuration = ProjectConfiguration::getApplicationConfiguration('frontend', 'dev', true);
  9. sfContext::createInstance($configuration)->dispatch();

Podejrzewam ze ten blad wynika z jakichs ustawien wirtualnego hosta (IMG:style_emoticons/default/dry.gif)
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 12.10.2025 - 06:26