I have searced and searched for a solution for this problem. Tested many ways, I just cant get it right. So Im starting to wonder if my host has disabled any of the featuers of PHP.
The script that Im making generates code for others to put on their pages. By entering username into a form. the form uses post.
The script runs fine in itself. But having all the code for all the featuers, makes the script to large and slow. (Im providing free scripts for others to use, Im new to makeing the scripts myself though)
Here is a sample script that Im using to test.
test.php
<?
$user_name="test";
include ("http://domain.com/html/includes/newsletter.php");
?>
Here is some of the file I want to include:
newsletter.php
//Lots of html before this
<textarea name="code" cols="60" rows="10">
<form action="http://domain.com/cgi-bin/united/adcsubsc.pl" method="post">
<input type="hidden" name="destination" value="<? echo "$*user_name"; ?>">Your email:
<input type="text" size="30"
//More HTML after this, but no need to post
The * indicates the trouble spot. In stead of showing the user name, it returns null. In other words, value="$user_name" becomes value=""
I have tryed several ways for echoing, and including.
Any help is very gratefully appriciated. I have checked the documents, and searced. So its either not documented, or I havent understandet it. In which case, Im sorry for any trouble.