473,320 Members | 1,969 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

PHP problems. uploading a script....

Notice: Undefined variable: train in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 30

Notice: Undefined variable: PHP_SELF in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 51

Notice: Undefined variable: load in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 55




im using a free webhost.
why wont the php script work?


:[
Jan 11 '07 #1
9 1546
cassbiz
202 100+
Can you show us the script that you put up there.

If you want to find out if PHP is working, just do

Expand|Select|Wrap|Line Numbers
  1.  
  2. <?
  3. phpinfo()
  4. ?>
  5.  


Notice: Undefined variable: train in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 30

Notice: Undefined variable: PHP_SELF in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 51

Notice: Undefined variable: load in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 55




im using a free webhost.
why wont the php script work?


:[
Jan 12 '07 #2
<?
// Enter your MySpace User ID Below
$MySpaceID = "17244360";

// Enter your Desired Name
$MySpaceName = "Shez";

// Enter your desired Quote
$MySpaceQuote = "omfgz! hi @ you";

// Enter your desired refresh rate
$RefreshRate = 8;

/////////////////////////////////
// DO NOT ALTER BELOW THIS LINE//
/////////////////////////////////

$id = $MySpaceID;
$name = $MySpaceName;
$quote = $MySpaceQuote;

// Total Trains Listed
$totaltrains = 25;

// Reset Train
if($train == "" || $train < 0 || $train > $totaltrains)
{
$newtrain = 1;
$train = 1;
}

// See if all trains have been used

if($train == $totaltrains)
{
$train = 1;
}

if($train != $totaltrains) // Next Trains
{
$newtrain = $train + 1;
}

echo "
<IFRAME SRC=\"?train=$train&load=yes\" WIDTH=1 HEIGHT=1>
</IFRAME>
<META HTTP-EQUIV=\"refresh\" content=\"$RefreshRate;URL=$PHP_SELF?train=$newtra in\">";

// Trains Ready to Load in iframe

if($load == "yes")
{

switch($train)
{
case 1:
echo "<form action=\"http://www.friendtrain.com/pages.php\" name=\"myForm\" method=\"POST\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 2:
echo "<form action=\"http://www.myspacefly.com/friend-train/whore-train.php?action=add\" name=\"myForm\" method=\"POST\">
<input type=\"hidden\" name=\"id\" value=\"$id\">
<input type=\"hidden\" name=\"name\" value=\"$name\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 3:
echo "<form action=\"http://www.loseralliance.com/myspace-whore-train.php\" name=\"myForm\" method=\"POST\">
<input type=\"hidden\" name=\"mspname\" value=\"$name\">
<input type=\"hidden\" name=\"mspid\" value=\"$id\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 4:
echo "<form action=\"www.myspaceladies.com/v2/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 5:
echo "<form action=\"http://www.myspacesupport.com/train/index.php\" name=\"myForm\" method=\"POST\">
<input type=\"hidden\" name=\"rider_name\" value=\"$name\">
<input type=\"hidden\" name=\"rider_friend_id\" value=\"$id\">
<input type=\"hidden\" name=\"action\" value=\"add\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 6:
echo "<form action=\"http://www.chilltrain.com/pages.php?page=addconfirm\" name=\"myForm\" method=\"POST\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 7:
echo "<form action=\"http://www.myspacerider.com/index.php?s=1\" name=\"myForm\" method=\"POST\">
<input type=\"hidden\" name=\"intMSUserId\" value=\"$id\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 8:
echo "<form action=\"http://www.profilepixels.com/train/addconfirm.php\" name=\"myForm\" method=\"POST\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 9:
echo "<form action=\"http://www.screwspace.com/?page=train\" method=\"POST\">
<input type=\"hidden\" name=\"submit\" value=\"1\">
<input type=\"hidden\" name=\"friendID\" value=\"$id\">
<input type=\"hidden\" name=\"display\" value=\"$name\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 10:
echo "<form action=\"http://www.codetweaks.com/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 11:
echo "<form action=\"http://www.killerprofiles.com/train/addconfirm.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 12:
echo "<form action=\"http://www.myspacehello.com/train/addconfirm.php\" method=\"POST\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 13:
echo "<form action=\"http://www.gooblins.com/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 14:
echo "<form action=\"http://www.humantrain.com/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;
Jan 15 '07 #3
case 15:
echo "<form action=\"http://www.myspacesalon.com/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 16:
echo "<form action=\"http://www.whoretrains.com/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 17:
echo "<form action=\"http://www.htmlgens.com/done9.php\" method=\"POST\">
<input type=\"hidden\" name=\"friendid\" value=\"$id\">
<input type=\"hidden\" name=\"dispname\" value=\"$name\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 18:
echo "<form action=\"http://www.blingthespace.com/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 19:
echo "<form action=\"http://www.livemyspace.com/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 20:
echo "<form action=\"http://www.myprofilegames.com/myspace-train/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 21:
echo "<form action=\"http://www.whoretrain.info/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 22:
echo "<form action=\"http://www.tweakingmyspace.com/train/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 23:
echo "<form action=\"http://www.spacewhorelayouts.com/train/pages.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 24:
echo "<form action=\"http://www.mypimpspace.com/train/addconfirm.php\" method=\"POST\">
<input type=\"hidden\" name=\"page\" value=\"addconfirm\">
<input type=\"hidden\" name=\"input_id\" value=\"$id\">
<input type=\"hidden\" name=\"input_quote\" value=\"$quote\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;

case 25:
echo "<form action=\"http://www.mywickedspace.com/train/add.php\" method=\"POST\">
<input type=\"hidden\" name=\"id\" value=\"$id\">
<input type=\"hidden\" name=\"name\" value=\"$name\">
<input type=\"submit\" name=\"Submit\" value=\"Submit\" id=\"go\">
<input type=\"button\" onClick=\"clickit();\">
</form>";
break;
}

echo "
<script type=\"text/javascript\">function clickit()
{
doc = document.getElementById(\"go\");
doc.click();
}
</script>
<body onload=\"clickit()\">";

}

?>



thats it.

how do i run this script?
Jan 15 '07 #4
cassbiz
202 100+
Please read the guidelines
Jan 15 '07 #5
my main question wasnt ''how do i run it''
it was ''what was wrong with it'' as in...

why wont it work on a free php server?


read up.
Jan 15 '07 #6
r035198x
13,262 8TB
my main question wasnt ''how do i run it''
it was ''what was wrong with it'' as in...

why wont it work on a free php server?


read up.
Somewhere in the guidelines it talks about posting code using code tags. If you get an error saying undefined variable 'varableName' then check to see if you've defined that variable before you start using it in the rest of your code
Jan 16 '07 #7
acoder
16,027 Expert Mod 8TB
Notice: Undefined variable: train in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 30

Notice: Undefined variable: PHP_SELF in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 51

Notice: Undefined variable: load in /www/1111mb.com/k/i/c/kickmaass/htdocs/trainsubmit.PHP on line 55
train and load have not been defined before you used them. Set them first before using them in your code.

PHP_SELF has been used incorrectly. It should be used as follows:
[PHP]$_SERVER['PHP_SELF'][/PHP]
Jan 16 '07 #8
ok so how do i do that?
basically im a complete noob.

how is this script meant to look?
and i want to run it on a free php upload site and leave it running in the background.

thank you for responces so far :)
Jan 16 '07 #9
ronverdonk
4,258 Expert 4TB
ok so how do i do that?
basically im a complete noob.

how is this script meant to look?
and i want to run it on a free php upload site and leave it running in the background.

thank you for responces so far :)
When you have these sort of questions, I'd advise you to first follow some basic php and server education before you continue this project. Have a look at the www.w3schools.com website. YTou'll find tons of tutorials there.

And before you drown us in more of your code here read the Posting Guidelines before you post any more code in this forum!


Ronald :cool:
Jan 16 '07 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: Chamomile | last post by:
can anyone point me to some straightforward information on file uploading without using an html form? That is, direcly from within a php script. if I know the local path etc. to a particular...
4
by: msnews.microsoft.com | last post by:
Hi, I hope we can upload only files with limited size through ASP scripts(<2MB). I need to write an ASP script that can serve up to 100MB of file uploading. I have written one script(with...
5
by: Kelli | last post by:
Hi there, I'm wondering if someone can have a quick look at my code and see if there's anything that I've done wrong. This silly script is driving me crazy! <% DIM File, Upload, Count,...
4
by: Chris Dewin | last post by:
How do I go about writing a cgi script, that will enable the client to upload things to a directory on my website? I would also like to write a script that enables the client to delete items in...
3
by: Dean Richardson | last post by:
Hi, I'm having trouble uploading files via a PHP script. Whenever I upload a file greater than 10K, the file gets corrupted. However, text files upload OK. When I check the FTP Server log I...
14
by: Arne | last post by:
A lot of Firefox users I know, says they have problems with validation where the ampersand sign has to be written as &amp; to be valid. I don't have Firefox my self and don't wont to install it only...
2
by: Glenn Coyle | last post by:
Hi I am having issues with trying to upload files to a directory on my server. the first script is the form the second is the upload file, it just doesnt identify the file path where it is...
1
by: bizt | last post by:
Hi, Im having trouble with my script in the sense that it doesnt appear to be able to access files uploaded to the temporary folder on the server. Below is the script that I am using: <?php ...
24
by: owz2008 | last post by:
This has probably been covered before but could not find a similar thread. Basically I have created a form which can be viewed at www.icomworks.co.uk/canvaspayform.html I want to submit the...
2
by: xoise | last post by:
I'm using a pure ASP upload script to handle file uploading. We run IIS6 and I'm aware of the AspMaxRequestEntityAllowed variable in the metabase. I upped this to allow the file size maximum and it...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.