Forum     

Go Back   Digit Technology Discussion Forum > Software > Programming
Register FAQ Calendar Mark Forums Read

Programming The destination for developers - C, C++, Java, Python and the lot


Reply
 
LinkBack Thread Tools Display Modes
Old 06-02-2011, 06:43 PM   #1 (permalink)
Right Off the Assembly Line
 
Join Date: Feb 2005
Posts: 23
Red face How to write php variable as string


I want to create one folder using php codebehind, say 'newfolder' and also want to create a file called 'index.php' which should contain the code I specified below.

<?php
$curdir = basename(dirname(__FILE__));
require_once '../template/index.php';
?>

But the problem is when I create the file index.php using php code, it writes as follows.

<?php
= basename(dirname(__FILE__));
require_once '../template/index.php';
?>

the variable gets eliminated.
Please help me solve this problem.
ganesh_dabhade is offline   Reply With Quote
Advertisements. Register and be a member of the community to get rid of them.
Advertisement

Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


 
Latest Threads
- by Charan
- by Charan

Advertisement




All times are GMT +5.5. The time now is 03:25 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.

Search Engine Optimization by vBSEO 3.3.2