Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
I am trying to see if a global variable exists and if it doesn't I want to create one.
the code i have used on my test page is:Code: Select all
hello world
<?php
if (empty($_REQUEST['VendorTxCode'] == true)
{
$ThisVendorTxcode = $today.(rand(0,32000)*rand(0,32000));
print "new ".$ThisVendorTxCode;
}
else
{
$ThisVendorTxcode = $_REQUEST['VendorTxCode'];
print $ThisVendorTxCode;
}
?>Thanks in anticipation
Nuts
Weirdan | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]