[wp-hackers] home.php and trying custom php
Josh Keen
josh.keen.01 at gmail.com
Tue Feb 21 07:01:12 UTC 2012
Hi there,
I think what you want to do is redirect the user to the index.php page. You
can redirect to another page with the header funtion:
<?php
header("Location: http://www.theonion.com/");
?>
This redirects to the onion.
If you're developing on your own computer the url would be something like:
<?php
header("Location:
http://loccalhost/directory_where_you_keep_your_wordpress_installtion/wordpress/index.php
");
?>
include() only make the code in the included file available in the file
that the include() appears in. It doesn't redirect you.
On Sat, Feb 18, 2012 at 6:18 PM, Sinan <sinan at sinanisler.com> wrote:
> Hello,
>
> I make home.php and put this code;
>
> <?php if(1==2){ echo "Custom Hello World"; } else {
>
> include('index.php');
>
>
> } ?>
>
> I expect index.php comes, but its not opening-running only blank page
> coming.
>
> Anyone know what code will be work in this case?
>
>
> Thanks.
>
>
> --
> Sinan İŞLER
> sinanisler.com <http://www.sinanisler.com>
> fb.com/sinanisler
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
More information about the wp-hackers
mailing list