| Server IP : 10.200.247.200 / Your IP : 216.73.217.19 Web Server : Apache System : Linux synergy-usa-sites 6.8.0-138-generic #138-Ubuntu SMP PREEMPT_DYNAMIC Fri Jul 31 22:41:49 UTC 2026 x86_64 User : jeremy ( 1001) PHP Version : 8.4.25 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /var/www/usa_sites/usagrantapplications.org/ |
Upload File : |
<?php
require_once($_SERVER['DOCUMENT_ROOT'].'/inc/php_header.php');
$categories = get_categories();
$granttype = $_GET['apptype'];
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script type="text/javascript">var _sf_startpt=(new Date()).getTime()</script>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>USA Grant Applications.org - Business Application</title>
<script type="text/javascript" charset="utf-8" src="/assets/js/jquery-1.4.2.min.js"></script>
<script type="text/javascript">
$(document).ready( function() {
$('input[name=category_id]').click( function() {
var show_class = $(this).attr('class');
var subcat_elements = $('.subcategory[class~='+show_class+']');
$('.subcategory').hide().find('input').attr('checked', ''); //hide and uncheck
if(subcat_elements.length > 0) {
$('#subcategories').show();
subcat_elements.show();
} else {
$('#subcategories').hide();
}
});
});
// Create an associative array of 'pretty name' values
var prettynames = {
category_id:"Funding Category",
cc_fname:"First Name",
cc_lname:"Last Name",
cc_addr:"Address",
cc_city:"City",
cc_state:"State",
cc_zip:"Zip",
cc_phonearea:"Phone Number Area Code",
cc_phoneprefix:"Phone Number Prefix",
cc_phoneextension:"Phone Number Ending",
cc_email:"Email Address",
app_gender:"Gender",
app_citizenship:"Citizenship",
app_age:"Your age",
app_amount_needed:"The amount needed",
app_usedescription:"Describe what you will use the money for",
app_uniqueness:"Uniqueness"
};
// Utility function that returns true if a string contains only
// whitespace characters
// Taken from "Javascript: The Definitive Guide" pg. 264
function isblank(s)
{
for (var i=0; i < s.length; i++)
{
var c = s.charAt(i);
if ((c!=' ') && (c != '\n') && (c != ''))
{
return false;
}
}
return true;
}
// Credit Card Validation Javascript
// copyright 12th May 2003, by Stephen Chapman, Felgall Pty Ltd
// You have permission to copy and use this javascript provided that
// the content of the script is not changed in any way.
function validateCreditCard(s) {
// remove non-numerics
var v = "0123456789";
var w = "";
for (i=0; i < s.length; i++) {
x = s.charAt(i);
if (v.indexOf(x,0) != -1)
w += x;
}
// validate number
j = w.length / 2;
if (j < 6.5 || j > 8 || j == 7) return false;
k = Math.floor(j);
m = Math.ceil(j) - k;
c = 0;
for (i=0; i<k; i++) {
a = w.charAt(i*2+m) * 2;
c += a > 9 ? Math.floor(a/10 + a%10) : a;
}
for (i=0; i<k+m; i++) c += w.charAt(i*2+1-m) * 1;
return (c%10 == 0);
}
function verify(f)
{
// Taken from "Javascript: The Definitive Guide" pg. 264.
// Modified heavily to suit our needs
// Loop through each element of the form and validate each item
//
// Set the parameters for each field to be valid
// If a field doesn't have any modifiers it is assumed to be
// a text field that can not be blank.
f.cc_phonearea.requiredlength = 3;
f.cc_phonearea.numeric = true;
f.cc_phoneprefix.requiredlength = 3;
f.cc_phoneprefix.numeric = true;
f.cc_phoneextension.requiredlength = 4;
f.cc_phoneextension.numeric = true;
f.cc_zip.requiredlength = 5;
f.cc_zip.numeric = true;
var msg;
var empty_fields = "";
var errors = "";
for (var i=0; i < f.length; i++)
{
var element = f.elements[i];
//document.getElementById('errorconsole').innerHTML += element.name + ":" + element.type + "<br>";
if ((element.type == 'text' || element.type == 'textarea') && (element.name != 'granttype_other'))
{
if ( (element.value == null || element.value == "") || isblank(element.value) )
{
empty_fields += "\n " + prettynames[element.name];
continue;
}
if (element.numeric)
{
var v = parseFloat(element.value);
if (isNaN(v))
{
errors +="- The field " + prettynames[element.name] + " must be a number\n";
}
}
if ( (element.requiredlength > 0) && (element.value.length != element.requiredlength) )
{
errors += "- The field " + prettynames[element.name] + " must be " + element.requiredlength + " digits long\n";
}
}
else if (element.type == 'select-one')
{
// The first option, option[0] can not be selected
if ( (element.value == null || element.value == "" || element.selectedIndex == 0) || isblank(element.value) )
{
empty_fields += "\n " + prettynames[element.name];
continue;
}
}
else if (element.type == 'radio')
{
if (!$('[name='+element.name+']:checked').val() && empty_fields.indexOf(prettynames[element.name]) == -1)
{
empty_fields += "\n " + prettynames[element.name];
continue;
}
}
}
if (!empty_fields && !errors) { return true; }
msg = "__________________________________\n\n";
msg += "The form was not submitted because of the following error(s).\n";
msg += "Please correct these error(s) and re-submit.\n";
msg += "__________________________________\n\n";
if (empty_fields)
{
msg += "- The following required field(s) are empty:" + empty_fields + "\n";
if (errors) { msg += "\n"; }
}
msg += errors;
alert(msg);
return false;
}
function tab_phone(current,next) {
var currentfield = document.getElementById(current);
var nextfield = document.getElementById(next);
if (currentfield.value.length == 3) { nextfield.focus(); }
}
</script>
<style>
<!--
body {margin:0px auto;background-color:#FFFFFF}
body table {margin:0px auto}
.header {font:bold 10pt verdana}
.gray {width:215px;background-color:#dbd7d6;text-align:center}
.white {width:485px;background-color:#ffffff;text-align:left;font:8pt verdana;padding-top:10px}
#base {list-style-type:none;text-align:center;margin:0px auto}
#base li {display:inline;padding:4px;font:7.5pt/120% verdana}
#base a:link, #base a:visited {color:#000000;text-decoration:none}
#base a:hover, #base a:active {color:#666666;text-decoration:underline}
#white {color:#fff}
.questions {width:580px;color:#000;margin-bottom:10px; padding: 8px;}
.questions input {font: 8pt verdana;display:inline;margin:1px 3px;color:#000;background-color:#f8f8f8}
.questions select {font: 8pt verdana;margin:1px 3px;color:#000;background-color:#f8f8f8}
.q {font:bold 8pt verdana;}
.a {font:normal 8pt verdana;}
.s {font:normal 7pt verdana;}
.gray img {margin:5px}
.white p {padding-left:10px}
.white img {padding:0px 0px 5px 10px;border:0px}
table span {font:bold 8pt verdana;color:#000}
ol {margin-left:40px}
.grant_category { margin-bottom:15px; width:95% }
.grant_category .txt {cursor:pointer; border-bottom:1px dotted #333333; margin-bottom:5px}
.grant_category .img {background-repeat:no-repeat; background-position:0px 2px; padding-left:50px; height:41px !important}
.grant_category .col {width:33%}
.grant_category .hrd {font-weight:bold; text-transform:uppercase; border-bottom:1px solid #333333; height:15px}
.grant_category .hrd span {font-weight:normal; text-transform:none; font-style:italic}
table#main-categories td { border-top:1px dotted #333333; padding:7px 0; }
table#main-categories td.first { border-top:none; }
.category { }
.subcategory { float:left; width:33%; }
.grant_category input { margin:0; }
.grant_category label { font-weight: normal; text-transform: uppercase; cursor: pointer; }
.grant_category p { font-size: 9px; margin-left:24px; }
-->
</style>
</head>
<body>
<table cellpadding="2" cellspacing="0" border="0" style="margin-bottom:20px" width="700">
<tr>
<td colspan="2" style="background:url(/images/logo.jpg) no-repeat;width:700px;height:63px"></td>
</tr>
<tr>
<td style="width:100px;background-color:#dbd7d6;text-align:center" valign="top"></td>
<td style="width:590px;background-color:#ffffff;text-align:left;font:8pt verdana;padding:10px 0px 0px 10px">
<p class="header">USA Grant Applications Registration Form</p>
<p><i>The information you enter below is confidential and is only made available to a USA Grant Applications
Specialist. It is used to help the USA Grant Research team to find new funding opportunities for you.</i></p>
<p class="header">Step 1 of 3: Tell us about <u>You</u> and <u>Your Funding Needs</u></p>
<form action="https://www.usagrantapplications.org/order.new.php" method="POST" name="application" target="_top" onsubmit="return verify(this);">
<table cellpadding="2" cellspacing="0" class="questions">
<tr>
<td class="q">First Name:</td>
<td class="a"><input type="text" name="cc_fname" size="20"></td>
<td class="q">Last Name:</td>
<td class="a"><input type="text" name="cc_lname" size="20"></td>
</tr>
<tr>
<td class="q">Street Address:</td>
<td class="a"><input type="text" name="cc_addr" size="20"></td>
<td class="q">City:</td>
<td class="a"><input type="text" name="cc_city" size="20"></td>
</tr>
<tr>
<td class="q">State:</td>
<td class="a">
<select name="cc_state">
<option value="0">Select one...</option>
<?php foreach($STATES as $abbr=>$name) : ?>
<option value="<?=$abbr;?>" <?= (isset($_POST['cc_state']) && $_POST['cc_state'] == $abbr) ? "selected" : null; ?>><?=$name;?></option>
<?php endforeach; ?>
</select>
</td>
<td class="q">Zip:</td>
<td class="a"><input type="text" name="cc_zip" size="10"></td>
</tr>
<tr>
<td class="q">Gender:</td>
<td class="a">
<select name="app_gender">
<option selected>Select...</option>
<option value="M">Male</option>
<option value="F">Female</option>
</select>
</td>
<td class="q">What is<br />your age?</td>
<td class="a">
<select name="app_age">
<option selected>Select...</option>
<option value="18-25">18-25</option>
<option value="26-34">26-34</option>
<option value="35-49">35-49</option>
<option value="50-65">50-65</option>
<option value="66-80">66-80</option>
<option value="80+">80 +</option>
</select>
</td>
</tr>
<tr>
<td class="q">Day Phone:</td>
<td class="a"><input type="text" id="cc_phonearea" name="cc_phonearea" size="3" maxlength="3" onkeyup="tab_phone('cc_phonearea','cc_phoneprefix');">-<input type="text" id="cc_phoneprefix" name="cc_phoneprefix" size="3" maxlength="3" onkeyup="tab_phone('cc_phoneprefix','cc_phoneextension');">-<input type="text" id="cc_phoneextension" name="cc_phoneextension" size="4" maxlength="4"></td>
<td colspan="2" class="q"> </td>
</tr>
</table>
<table cellpadding="0" cellspacing="0" class="questions">
<tr>
<td class="q">Citizenship Status:
<select name="app_citizenship">
<option selected>Select...</option>
<option value="U.S. Citizen">U.S. Citizen</option>
<option value="Resident Alien">Resident Alien</option>
<option value="Green Card Holder">Green Card Holder</option>
<option value="Permanent Resident">Permanent Resident</option>
<option value="Not Sure">Not Sure</option>
</select>
</td>
</tr>
</table>
<table cellpadding="2" cellspacing="0" class="questions">
<tr>
<td colspan="2" class="q">Choose with funding category you are interested in</td>
</tr>
<tr>
<td>
<?
if(!empty($categories['categories'])) {
?><table id="main-categories" cellpadding="2" cellspacing="0" class="grant_category"><?
$first = true;
foreach ($categories['categories'] as $id => $cat) { ?>
<tr>
<td <?= ($first) ? 'class="first"' : null; $first = false; ?>>
<input type="radio" name="category_id" id="<?=$id.'-'.$cat['slug'];?>" class="<?=$cat['slug'];?>" value="<?=$id;?>" />
<label for="<?=$id.'-'.$cat['slug'];?>" title="<?=$cat['name'];?><?=($cat['description'] != '') ? ' - '.$cat['description'] : null;?>"><?=$cat['name'];?></label>
<?=($cat['description'] != '') ? '<p>'.$cat['description'].'</p>' : null;?>
</td>
</tr>
<? }
?></table><?
}
if(!empty($categories['subcategories'])) { ?>
<table id="subcategories" class="grant_category" cellpadding="2" cellspacing="0" style="display:none;">
<tr>
<td class="hrd" >Suggested Sub-Categories <span>(Check all that apply)</span></td>
</tr>
<tr><td style="padding-top:5px;"><?
foreach ($categories['subcategories'] as $sub_id => $subcat) { ?>
<div class="subcategory <?=implode(' ', $subcat['categories']);?>">
<input id="<?=$sub_id.'-'.$subcat['slug'];?>" type="checkbox" name="subcategories[]" value="<?=$subcat['id'];?>" />
<label for="<?=$sub_id.'-'.$subcat['slug'];?>"><?=$subcat['name'];?></label>
</div>
<?
} ?>
</td>
</tr>
</table><?
} ?>
</td>
</tr>
</table>
<input type="hidden" name="granttype" value="<? echo $granttype; ?>">
<table cellpadding="1" cellspacing="0" class="questions">
<tr>
<td class="q">How much money are you going to need?
<select name="app_amount_needed">
<option selected>Select...</option>
<option value="$500-$10,000">$500 - $10,000</option>
<option value="$10,000 - $25,000">$10,000 - $25,000</option>
<option value="$25,000 - $50,000">$25,000 - $50,000</option>
<option value="$50,000 - $100,000">$50,000 - $100,000</option>
<?
if ($granttype != 'business')
{
echo "<option value=\"$100,000 or More\">\$100,000 or More</option>";
}
else
{
?>
<option value="$100,000 - $250,000">$100,000 - $250,000</option>
<option value="$250,000 - $500,000">$250,000 - $500,000</option>
<option value="$500,000 - $1,000,000">$500,000 - $1,000,000</option>
<option value="$1,000,000 +">$1,000,000 +</option>
<?
}
?>
</select>
</td>
</tr>
</table>
<table cellpadding="2" cellspacing="0" class="questions">
<tr>
<td class="q">Describe what you will use the money for:</td>
</tr>
<tr>
<td class="a"><textarea name="app_usedescription" cols="64" rows="6"></textarea></td>
</tr>
<tr>
<td class="q">What unique things would separate you from other applicants applying for this money?</td>
</tr>
<tr>
<td class="a"><textarea name="app_uniqueness" cols="64" rows="6"></textarea></td>
</tr>
</table>
<table cellpadding="2" cellspacing="0" class="questions">
<tr>
<td class="q">What Email address would you like to use for your Username for your Online Funding Application Account?</td>
</tr>
<tr>
<td class="a"><input type="text" name="cc_email" size="30"> <i>(ie. yourmail@hotmail.com)</i></td>
</tr>
<tr>
<td class="s"><i>** Your email is safe. We hate spam as much as you do!!</i></td>
</tr>
<tr>
<td class="s"><i>** Your <u>Email</u> will be <u>your username</u> for the USA Grant Applications website. Please double check it to be sure it is accurate!</i></td>
</tr>
<tr>
<td>
<input type='checkbox' checked /> Yes, I want to receive emails on New Funding Opportunities as well as New Tips!
</td>
</tr>
</table>
<center><input type="submit" value="" style="background:url(images/submit.jpg) top center no-repeat;width:144px;height:63px;border:0px;margin:20px auto;cursor:pointer"></center>
<input type="hidden" name="tc" value="<?= $tc; ?>">
<?= $trackerformparams; ?>
</form>
</td>
</tr>
<? include('footer.php');