Jump to content

Recommended Posts

Hi,

i am new to programming in php, i was just checking the wordpress code and found out in the wordpress code they are calling the function get_header(); at the top of every page but above calling this function their is no file included file, how is it possible, how can a function work without function defination.

 

Please recommend

Regards

Ltoso

if there is no include file then the function is encoded in that page.

 

What WP page are you talking about i could have a look and see how more i could explain this as i am currently coding a function for a client.

hi,

just download latest.tar.gz from the wordpress.org and then go into wp-content/themes/header.php

 

you'll see that they don't have any file included into the php file and still they have used the get_header(); function

 

Regards

ltoso

hi,

but there is no include or require directive before the function call you can yourself download code and check it.

 

ltoso

 

Yes, the current page you are viewing is a file to be included. If it isn't defined then this is obviously so.

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.