Jump to content

Recommended Posts

hello

 

I m facing some problems in php file.

 

1. how to include a php file inside another php file.

 

2.in one php file i m getting the json object values. but how to  get those json object values in another file, after including that php file.

 

Kindly suggest me.

 

Link to comment
https://forums.phpfreaks.com/topic/70872-help-me-in-php-and-javascript/
Share on other sites

Including one file inside a .php file:

<?php
include "file.php"; // if file.php does not exist, this will print a notice, and continue the script
include_once "file.php"; // if file has already been included, will not include again. Will also print a notice and continue if file.php does not exist
require "file.php"; // if file.php does not exist, this will stop the script and print a Fatal Error.
require_once "file.php"; // includes it once, and will print Fatal Error and stop the script if file does not exist
?>

 

json I have no idea about...

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.