Jump to content

[SOLVED] some php echoing help


fellixombc

Recommended Posts

basically i want it to echo, what i put, in a php or html document.

 

like would this work?

<?php
$left_side.php
echo "$left_side.php";
</php>

i think that code won't work because $ means variable and it thinks left_side.php ( a document ) is a variable

 

i want it to echo text from another document

 

Link to comment
Share on other sites

Well in that case, he didn't answer your question.  Read up on include in the php manual.

yeah i noticed when it didn't work.

do you have any idea?

 

Just what he said ;) You need to use the include function.

 

include('left_side.php');

 

There's more in the PHP manual about other things you might find useful.

Link to comment
Share on other sites

Well in that case, he didn't answer your question.  Read up on include in the php manual.

yeah i noticed when it didn't work.

do you have any idea?

 

Just what he said ;) You need to use the include function.

 

include('left_side.php');

 

There's more in the PHP manual about other things you might find useful.

thank you so much!!! solved btw

Link to comment
Share on other sites

Dear,

 

 

For any file like this

 

$file.php

 

echo '$file.php ';    can't echo as $file.php is vaiable but it cant assign  any value

 

For this better to use functiones like include("filename"); or require("filename");in any page.

 

But how could it echo the stuff that is in that file, so for this

 

we have echo in the file itself as whatever we include.

 

Like in filename.php

we echo anything as by echo"stuff";

   

Link to comment
Share on other sites

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.