Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> [PHP]problem z get_header(), Wordpress
szakalmce
post
Post #1





Grupa: Zarejestrowani
Postów: 4
Pomógł: 0
Dołączył: 26.12.2012

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


Witam, dopadł mnie problem początkującego. Nie potrafię przeskoczyć tematu z wyskakującym błedem na zaladowanym szablonie w wordpress w index.php "Fatal error: Call to undefined function get_header()"

Oto zawartość pliku index.php:

  1. <?php get_header(); ?>
  2.  
  3. <?php if (ca_slider != 'None') include_once(dir.(ca_alt_slides_manager ? 'simplified-slider.php' : 'slider.php')); ?>
  4.  
  5. <?php
  6. if (ca_frontpage && ca_frontpage != __('Choose a page', 'carta') && ca_frontpage == ca_gallery_page)
  7. {
  8. include_once(TEMPLATEPATH.'/gallery.php');
  9. }
  10. else if (ca_frontpage && ca_frontpage != __('Choose a page', 'carta') && ca_frontpage == ca_projects_page)
  11. {
  12. include_once(TEMPLATEPATH.'/projects.php');
  13. }
  14. else if (ca_frontpage && ca_frontpage != __('Choose a page', 'carta') && ca_frontpage == ca_blog_page)
  15. {
  16. include_once(TEMPLATEPATH.'/blog.php');
  17. }
  18. else
  19. {
  20. ?>
  21.  
  22. <!-- home's content -->
  23. <div id="home" class="type">
  24.  
  25. <?php
  26. if (ca_frontpage) {
  27. query_posts('pagename='.ca_frontpage);
  28. while (have_posts()) : the_post(); the_content(); endwhile;
  29. wp_reset_query();
  30. }
  31. ?>
  32.  
  33. <!-- closing: content -->
  34. </div>
  35.  
  36. <?php } ?>
  37.  
  38. <?php get_footer(); ?>


Proszę o podpowiedź jak mogę ten plik uruchomić.
Go to the top of the page
+Quote Post
Xart
post
Post #2





Grupa: Zarejestrowani
Postów: 267
Pomógł: 6
Dołączył: 8.04.2013

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


Wpisując adres do niego w przeglądarce ? o.O
Go to the top of the page
+Quote Post
szakalmce
post
Post #3





Grupa: Zarejestrowani
Postów: 4
Pomógł: 0
Dołączył: 26.12.2012

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


I zgadnij co wtedy? Otrzymuje komunikat "Fatal error: Call to undefined function get_header()"

Podbijam tematu bo nie mogę znaleźć nigdzie rozwiązania
Go to the top of the page
+Quote Post
ghost1511
post
Post #4





Grupa: Zarejestrowani
Postów: 186
Pomógł: 18
Dołączył: 2.09.2010

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


Zainstalowałeś poprawnie szablon w wordpress? Dostałeś błąd, że funkcja jest niezdeklarowana. Wygląda na to, że odpalasz szablon poza WP.
Go to the top of the page
+Quote Post
szakalmce
post
Post #5





Grupa: Zarejestrowani
Postów: 4
Pomógł: 0
Dołączył: 26.12.2012

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


Zainstalowałem go przez wordpressa. Tym razem taka informacja:

http://images65.fotosik.pl/656/a37dd1ab53f1d9bc.jpg

Go to the top of the page
+Quote Post

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: 21.08.2025 - 12:49