I got this code from this site awhile back, and for the life of me cannot find it again. It was working on my former tinyportal, but after getting updated to version 1 it is giving me errors.
Here are the errors...
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/darkaft1/public_html/forums/Sources/Load.php(1735) : eval()'d code(1080) : eval()'d code on line 3
Warning: Unexpected character in input: ''' (ASCII=39) state=1 in /home/darkaft1/public_html/forums/Sources/Load.php(1735) : eval()'d code(1080) : eval()'d code on line 3
Parse error: syntax error, unexpected '/' in /home/darkaft1/public_html/forums/Sources/Load.php(1735) : eval()'d code(1080) : eval()'d code on line 3
Unfortunately I am good at editing, but lousy and the actual coding stuff.
Here is the code for the PHP article
global $sourcedir, $user_info, $context ;
require_once($sourcedir . \'/Subs.php\');
require_once($sourcedir .\'/Subs-Post.php\');
// CONFIGURATION SECTION
$intro_form = \"<br><center>Please take your time to fill out the form. This is your first impression, so make it a good one.<br>Please use your character name.</center><br>\"; // Can include html
$thanks_text = \"<br><center>Thanks ever so much for applying. We\'ll review your application and get back to you.</center><br>\"; // what is displayed after the form is submitted
// Define your fields. All of these values need to be defined, even if they are empty.
// The fields will be displayed in the order in which they are listed in the array.
// $fielddef =
// array(
// array(
// \'caption\' => \"\", // caption to be displayed on the form. Can include symbols and spaces.
// \'name\' => \"\", // a unique name for the field. No symbols or spaces
// \'type\' => \"\", // text, radio, select, checkbox, textarea, heading
// \'options\' => \"\", // for radio and select fields. List in order you wish them to appear, separated by commas; for checkboxes, it\'s the value to be saved and displayed next to the box
// \'defaultvalue\' => \"\", // the default value for the field. Can be a variable or text. Be sure to enclose text in quotation marks
// \'required\' => 0 // 0 or 1 -- use 1 if the field must be filled out. use 0 if it\'s optional; never set a checkbox to be required
// ),
// );
$fielddef =
array(
array(
\'caption\' => \"Name\",
\'name\' => \"name\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 1
),
array(
\'caption\' => \"Age\",
\'name\' => \"age\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 1
),
array(
\'caption\' => \"Availability\",
\'name\' => \"activities\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"A little about yourself\",
\'name\' => \"bio\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Computer Specs (does your computer lag? do you have connection trouble?)\",
\'name\' => \"computer\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"<br><center>Information about your character</center><br>\",
\'name\' => \"heading1\",
\'type\' => \"heading\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Class\",
\'name\' => \"class\",
\'type\' => \"select\",
\'options\' => \"Druid,Hunter,Mage,Paladin,Priest,Rogue,Shaman,Warlock,Warrior,Death Knight\",
\'defaultvalue\' => \"Druid\",
\'required\' => 1
),
array(
\'caption\' => \"Race\",
\'name\' => \"race\",
\'type\' => \"select\",
\'options\' => \"Draenei,Dwarf,Gnome,Human,Night Elf\",
\'defaultvalue\' => \"Draenei\",
\'required\' => 1
),
array(
\'caption\' => \"Alts (name/level/class/race/server)\",
\'name\' => \"alts\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"<br><center>Experience</center><br>\",
\'name\' => \"heading2\",
\'type\' => \"heading\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"<br>Pre-TBC\",
\'name\' => \"pretbc\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"TBC\",
\'name\' => \"tbc\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"WotLK\",
\'name\' => \"WotLK\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Spec\",
\'name\' => \"Spec\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Do you enjoy your main spec (you will be raiding in this spec)\",
\'name\' => \"enjoy\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Willing to respec if the guild ask you to\",
\'name\' => \"respec\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Link to your armory\",
\'name\' => \"armoury\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Do you have any resistance gear\",
\'name\' => \"resistance\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"/Played\",
\'name\' => \"played\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Profession, and any rare recipes\",
\'name\' => \"profession\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"How much gold do you have\",
\'name\' => \"gold\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"<br><center>What is your raid availability</center><br>\",
\'name\' => \"heading2\",
\'type\' => \"heading\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Monday\",
\'name\' => \"monday\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 1
),
array(
\'caption\' => \"Tuesday\",
\'name\' => \"tuesday\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 1
),
array(
\'caption\' => \"Wednesday\",
\'name\' => \"wednesday\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 1
),
array(
\'caption\' => \"Thursday\",
\'name\' => \"thursday\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 1
),
array(
\'caption\' => \"Friday\",
\'name\' => \"friday\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 1
),
array(
\'caption\' => \"Saturday\",
\'name\' => \"saturday\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 1
),
array(
\'caption\' => \"Anything planned that will effect your availability (holidays/exams etc)\",
\'name\' => \"plans\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Heroic keys\",
\'name\' => \"keys\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"What can you offer Dark Aftermath\",
\'name\' => \"offer\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"What are you looking for from Dark Aftermath\",
\'name\' => \"looking\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Member Referral\",
\'name\' => \"vouch\",
\'type\' => \"text\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Have you applied anywhere else\",
\'name\' => \"applied\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Previous guild(s) reasons for leaving\",
\'name\' => \"previous\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Can you confirm you have read, understand and agree to the guild rules?\",
\'name\' => \"rules\",
\'type\' => \"select\",
\'options\' => \"Yes,No\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
array(
\'caption\' => \"Contact Info and Further Comments\",
\'name\' => \"comment\",
\'type\' => \"textarea\",
\'options\' => \"\",
\'defaultvalue\' => \"\",
\'required\' => 0
),
);
//send the application by email?
$enable_email=false;
//email address of recruitment staff member
$email_address=\'gyza@darkaftermath.org\';
//post the application on forum?
$enable_post=true;
//board id to which the application should be posted
$board_id=4;
//END OF CONFIGURATION SECTION
$show_form= \'true\';
if (isset($_REQUEST[\'submitted\'])) { // Handle the form
//Check required fields
$errors = array(); //Initialize error array
foreach ($fielddef as $field)
if (empty($_REQUEST[$field[\'name\']]) && ($field[\'required\'] == 1)){ $errors[] = $field[\'name\']; }
//There\'s at least one field missing
if (isset($errors[0])) {
foreach ($_REQUEST as $key => $value)
$fieldvalue[$key] = $value;
}
else { // all is well
$show_form=\'false\';
if ($enable_email) { // email an application
$subject = \'Enrollment Application\';
$body = \'Enrollment application has been made by \' . $context[\'user\'][\'name\'] .
\' from IP Address \' . $user_info[\'ip\'] . \'
\';
foreach ($fielddef as $field) {
$body .= $field[\'caption\'] . \': \' . $_REQUEST[$field[\'name\']] . \'
\';
}
mail($email_address, $subject, $body,\"From: \" . $user_info[\'email\']);
}
if ($enable_post) { //create new forum post with application
$postbody = \'Enrollment application has been made by \' . $context[\'user\'][\'name\'] .\'<br />
<table>\';
foreach ($fielddef as $field) {
$postbody .= \'<tr><td>\' . $field[\'caption\'] . \'<td></td><td> \' . $_REQUEST[$field[\'name\']] . \'</td></tr>\';
}
$postbody .= \'</table>\';
$msgOptions = array(
\'id\' => 0 ,
\'subject\' => \'[Pending] Application of \' . $context[\'user\'][\'name\'],
\'body\' => $postbody ,
\'icon\' => \'xx\',
\'smileys_enabled\' => true,
\'attachments\' => array(),
);
$topicOptions = array(
\'id\' => 0 ,
\'board\' => $board_id,
\'poll\' => null,
\'lock_mode\' => null,
\'sticky_mode\' => null,
\'mark_as_read\' => true,
);
$posterOptions = array(
\'id\' => $context[\'user\'][\'id\'],
\'name\' => $context[\'user\'][\'name\'],
\'email\' => $user_info[\'email\'],
\'update_post_count\' => true,
);
createPost($msgOptions, $topicOptions, $posterOptions);
}
//Text for thank you page
echo $thanks_text;
}
}
//Looks like you want the form,
if ($show_form == \'true\') {
echo $intro_form . \"<br>\";
if (isset($errors[0])) { echo \'<div style=\"color: red;\">Please fill in all fields with a *.</div>\'; }
echo \'<form action=\"\' . $scripturl . \'?page=\' . $_GET[\'page\'] . \'\" method=\"post\">
<INPUT id=\"submitted\" name=\"submitted\" type=\"hidden\" value=\"TRUE\" />
<center><table width=\"550px\">\';
$bg = \'windowbg2\';
foreach ($fielddef as $field) {
if ($field[\'type\'] == \'text\') {
echo \'<TR class =\"\' . $bg . \'\">
<TD width = \"200px\" align=\"left\">\';
if ($field[\'required\'] == 1) { echo \'* \'; }
echo $field[\'caption\'] . \':</TD>
<TD align=\"left\"><INPUT id=\"\' . $field[\'name\'] . \'\" name=\"\' . $field[\'name\'] . \'\" type=\"text\" value =\"\' . $fieldvalue[$field[\'name\']] . \'\" /></TD>
</TR>\';
}
elseif ($field[\'type\'] == \'radio\') {
echo \'<TR class =\"\' . $bg . \'\">
<TD width = \"200px\" align=\"left\">\';
if ($field[\'required\'] == 1) { echo \'* \'; }
echo $field[\'caption\'] . \':</TD>
<TD align=\"left\">\';
$options = explode(\',\',$field[\'options\']);
foreach ($options as $option) {
echo \'<INPUT TYPE=\"RADIO\" NAME=\"\' . $field[\'name\'] . \'\" VALUE=\"\'. $option . \'\"\';
if ((isset($fieldvalue[$field[\'name\']])) && ($option == $fieldvalue[$field[\'name\']])) { echo \' CHECKED\'; }
echo \'>\' . $option . \' \';
}
echo \'</TD>
</TR>\';
}
elseif ($field[\'type\'] == \'checkbox\') {
echo \'<TR class =\"\' . $bg . \'\">
<TD width = \"200px\" align=\"left\">\';
echo $field[\'caption\'] . \':</TD>
<TD align=\"left\">\';
echo \'<INPUT TYPE=\"CHECKBOX\" NAME=\"\' . $field[\'name\'] . \'\" VALUE=\"\'. $field[\'options\'] . \'\"\';
if (isset($fieldvalue[$field[\'name\']]) && ($fieldvalue[$field[\'name\']]==$field[\'options\'])) { echo \' CHECKED\'; }
echo \'>\' . $field[\'options\'] . \'
</TR>\';
}
elseif ($field[\'type\'] == \'select\') {
echo \'<TR class =\"\' . $bg . \'\">
<TD width = \"200px\" align=\"left\">\';
if ($field[\'required\'] == 1) { echo \'* \'; }
echo $field[\'caption\'] . \':</TD>
<TD align=\"left\"><SELECT id=\"\' . $field[\'name\'] . \'\" name=\"\' . $field[\'name\'] . \'\" style=\"WIDTH: 152px\" value =\"\';
echo \'\" />\';
$options = explode(\',\',$field[\'options\']);
foreach ($options as $option) {
echo \'<OPTION value=\"\' . $option . \'\"\';
if ((isset($fieldvalue[$field[\'name\']])) && ($option == $fieldvalue[$field[\'name\']])) { echo \' selected\'; }
echo \'>\' . $option . \'</OPTION>\';
}
echo \'</SELECT></TD>
</TR>\';
}
elseif ($field[\'type\'] == \'textarea\') {
echo \'<TR class =\"\' . $bg . \'\">
<TD width = \"200px\" align=\"left\">\';
if ($field[\'required\'] == 1) { echo \'* \'; }
echo $field[\'caption\'] . \':</TD>
<TD align=\"left\"><TEXTAREA id=\"\' . $field[\'name\'] . \'\" name=\"\' . $field[\'name\'] . \'\" rows=\"4\" cols=\"40\">\';
echo $fieldvalue[$field[\'name\']];
echo \'</\' . \'TEXTAREA></TD>
</TR>\';
}
elseif ($field[\'type\'] == \'heading\') {
echo \'<TR class =\"\' . $bg . \'\">
<TD colspan=\"2\">\' .
$field[\'caption\'] .
\'</TD></TR>\';
}
if ($bg == \'windowbg2\') { $bg = \'windowbg\'; }
else { $bg = \'windowbg2\'; }
}
echo \'
<TR class =\"\' . $bg . \'\">
<TD colspan=\"2\" align=\"center\">
<INPUT type=\"submit\" value=\"Submit\">
<INPUT type=\"reset\" value=\"Reset\"></TD>
</TR></TABLE></center></form>\';
}
Hoping somebody can understand what is going on. I dont have a up and running site right now that this works on but you can get the error message by going to
http://www.darkaftermathguild.com/forums/index.php?page=4
Find the original code and paste it in again.
Quote from: JPDeni on April 14, 2009, 02:03:11 AMFind the original code and paste it in again.
Or you could just use Custom Form (http://custom.simplemachines.org/mods/index.php?mod=1279) :
o) It works great for us (http://www.cocacolaguild.com/) if you want to check it out.
I cannot find the "original" author's code. This code was working on Tinyportal 0.98. Since upgrading to the Tinyportal 1 Beta 3 I get the errors.
I have been looking for the original code post to see if there are any replies that would help me, but I cannot find it in any search I do. Searched on this site, and on google with no luck. Was hoping someone would know about some changes to the Login.php file that might of been made, and see where in my code the conflict is.
I already fixed one of the errors.
$email_address=\'gyza@darkaftermath.org\';
needed to be changed to
$email_address='gyza@darkaftermath.org';
I would probably remove all the escapes (\) from the quotes, that is going to cause you trouble.. The only time you should escape a quote, is if it's inside another quote (eg: $foo = 'bar\'s'; instead of $foo = \'bar\'s\';)
It's more than likely the original poster of the code, or the forums it was posted to was overcompensating when sanitising the quoted code for the query which saved the original post.
That might not be all that's wrong, but it's the most obvious thing that needs fixing =)
Well I dont really understand the 'why', but I do understand how to remove those. I am not overly code literate, but I can edit it up like a mad man! ;D
I will try that and see what happens.
Without understanding the language and the rules, I wish you well my friend ;o)..
Some things you might want to look out for: $x = \'a\' . \'b\'; should come out as $x = 'a' . 'b'; in most cases. (There could be exceptions where the author did intend $x = 'a\' . \'b'; though this is unlikely.) when two variables are separated by a '.' it's effectively saying "put these together" so 'a' . 'b' would be 'ab'.
Good luck :o)
I know it isnt necessarily the perfect way, but I typically will change only 1 or 2 items. Refresh everything and see if it is working. If it isnt I change them back, and move on. Good ole process of elimination...
Quote from: Azphat12 on April 14, 2009, 03:20:10 AM
I know it isnt necessarily the perfect way, but I typically will change only 1 or 2 items. Refresh everything and see if it is working. If it isnt I change them back, and move on. Good ole process of elimination...
You will need to change them all, I believe.
I would expect that
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/darkaft1/public_html/forums/Sources/Load.php(1735) : eval()'d code(1080) : eval()'d code on line 3Would read:
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/darkaft1/public_html/forums/Sources/Load.php(1735) : eval()'d code(1080) : eval()'d code on line 4If you were to change the first require line to "require_once($sourcedir . '/Subs.php');" and reload it.
You will need to change them all, until you no longer see any "Unexpected character in input: '\'".
Then either your form will be working, or we'll have something more meaningful to work with.
The reason for the problem is a glitch in the editor.
You can edit all the quoted lines to remove the \ characters or you can find the original code (probably the "Join us! form" topic in the Block code snippets board) and repaste it in.
That "Join Us" is very close to the one I use. But not the original. I think he did the same thing I have done and modified it for his preference. As I can see his version does not have all the //rule on how to this, and //rule on how to do that. That was in the original and I left it in.
Regardless it gives me a good base to use to examine mine with. Thank you very much.
I hadn't looked closely at your code. I wrote the original! :2funny:
I can look for it if you need me to, but it is sorta cool for you to be looking at it. You can learn a whole lot that way. That's how I learned how to code.
Below is the one I am currently running. Note this has not been tested with the latest TP.
global $user_info;
//*******************CONFIGURATION SECTION*********************
//--Individual Class Need Rating--//
//Place the need for each class to the right of the equals sign.
//0 = closed
//1 = low
//2 = med
//3 = high
//4 = open (just in case people still like the open/closed wording)
$deathknight_need = 4;
$druid_need = 4;
$hunter_need = 4;
$mage_need = 0;
$paladin_need = 4;
$priest_need = 0;
$rogue_need = 4;
$shaman_need = 4;
$warlock_need = 0;
$warrior_need = 4;
//--Quantity needed of each spec!--//
//To the right of the = sign, type the # you need of that spec!
//Here you can be much more specific than simply "High," "Medium," or "Low."
//Deathknight
$needed_deathknight = 1;
//Druid
$feral_druid = 1;
$resto_druid = 1;
$balance_druid = 1;
//Hunter
$needed_hunter = 1;
//Mage
$needed_mage = 0;
$arcane_mage = 0;
$fire_mage = 0;
$frost_mage = 0;
//Paladin
$holy_paladin = 1;
$prot_paladin = 1;
$ret_paladin = 0;
//Priest
$holy_priest = 0;
$shad_priest = 0;
//Rogue
$needed_rogue = 1;
//Shaman
$resto_sham = 1;
$enhance_sham = 1;
$elemental_sham = 1;
//Warlock
$needed_warlock = 0;
//Warrior
$prot_war = 1;
$arms_war = 0;
$fury_war = 0;
//--COLORS--//
/*
$closed_color = 'red';
$low_color = 'green';
$medium_color = 'orange';
$high_color = 'red';
$open_color = 'green';
*/
//--LOCALIZATION--//
//LANGUAGE VARIABLES FOR EACH SPEC
$deathknight_spec = 'Needed:';
$feral_spec = 'Feral:';
$resto_spec = 'Restoration:';
$balance_spec = 'Boomkin:';
$hunter_spec = 'Needed:';
$mage_spec = 'Needed:';
$arcane_spec = 'Arcane:';
$fire_spec = 'Fire:';
$frost_spec = 'Frost:';
$holy_spec = 'Holy:';
$shadow_spec = 'Shadow:';
$prot_spec = 'Protection:';
$ret_spec = 'Retribution:';
$rogue_spec = 'Needed:';
$enhance_spec = 'Enhancement:';
$elemental_spec = 'Elemental:';
$warlock_spec = 'Needed:';
$arms_spec = 'Arms:';
$fury_spec = 'Fury:';
//************************END CONFIG****************************
//*************************FUNCTIONS****************************
function printClassStatus($className)
{
switch($className)
{
case 0: return '<font color="red">Closed</font>';
case 1: return '<font color="green">Low</font>';
case 2: return '<font color="orange">Medium</font>';
case 3: return '<font color="red">High</font>';
case 4: return '<font color="green">Open</font>';
}
}
function displayTT($class="",$specName1="",$spec1="",$specName2="",$spec2="",$specName3="",$spec3="",$specName4="",$spec4="")
{
return '
<script type="text/javascript" src="./wz_tooltip/wz_tooltip.js"></script>
<a href="javascript:void(0);" onmouseover="Tip(\'<table width=100%><tr><td><font color=black>' . $specName1 . '</font></td><td><font color=black>' . $spec1 . '</font></td></tr><tr><td><font color=black>' . $specName2 . '</font></td><td><font color=black>' . $spec2 . '</font></td></tr><tr><td><font color=black>' . $specName3 . '</font></td><td><font color=black>' . $spec3 . '</font></td></tr><tr><td><font color=black>' . $specName4 . '</font></td><td><font color=black>' . $spec4 . '</font></td></tr></table>\')" onmouseout="UnTip()">' . printClassStatus($class) . '</a>';
}
//**********************END FUNCTIONS****************************
echo'
<center>Hover over the recruitment level for spec details</center>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Deathknight.gif" />Death Knight</font></td>
<td valign="bottom"><strong>' . displayTT($deathknight_need,$deathknight_spec,$needed_deathknight) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Druid.gif" />Druid</font></td>
<td valign="bottom"><strong>' . displayTT($druid_need,$resto_spec,$resto_druid,$feral_spec,$feral_druid,$balance_spec,$balance_druid) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Hunter.gif" />Hunter</td>
<td valign="bottom"><strong>' . displayTT($hunter_need,$hunter_spec,$needed_hunter) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Mage.gif" />Mage</td>
<td valign="bottom"><strong>' . displayTT($mage_need,$mage_spec,$needed_mage,$arcane_spec,$arcane_mage,$fire_spec,$fire_mage,$frost_spec,$frost_mage) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Paladin.gif" />Paladin</td>
<td valign="bottom"><strong>' . displayTT($paladin_need,$holy_spec,$holy_paladin,$prot_spec,$prot_paladin,$ret_spec,$ret_paladin) . '</a></strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Priest.gif" />Priest</td>
<td valign="bottom"><strong>' . displayTT($priest_need,$holy_spec,$holy_priest,$shadow_spec,$shad_priest) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Rogue.gif" />Rogue</td>
<td valign="bottom"><strong>' . displayTT($rogue_need,$rogue_spec,$needed_rogue) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Shaman.gif" />Shaman</td>
<td valign="bottom"><strong>' . displayTT($shaman_need,$resto_spec,$resto_sham,$elemental_spec,$elemental_sham,$enhance_spec,$enhance_sham) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Warlock.gif" />Warlock</td>
<td valign="bottom"><strong>' . displayTT($warlock_need,$warlock_spec,$needed_warlock) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td width="70%" class="tbcphp"><img alt="" src="images/IconSmall_Warrior.gif" />Warrior</td>
<td valign="bottom"><strong>' . displayTT($warrior_need,$prot_spec,$prot_war,$arms_spec,$arms_war,$fury_spec,$fury_war) . '</strong></td>
<td width="10%"> </td>
</tr>
</tbody>
</table>
<table width="100%" height="8">
<tbody>
<tr>
<td class="tbcphp"><center>Recruitment is currently open to select classes.</center>
</td>
</tr>
<tr>';
if($user_info['is_guest'])
{
echo'
<td class="tbcphp">
<div align="center">Please <a href="/smf/index.php?action=register">Register</a> before applying.<br />
</div>
</td>';
}
else
{
echo'
<td>
<div align="center">Apply in our <a href="/smf/index.php?board=2.0" alt="Recruiting">Recruiting</a> forum.<br />
</div>
</td>';
}
echo'
</tr>
</tbody>
</table>
</font>
';
Well for the time being I decided to take the lesser of two evils. I took the "Join Us" code since it was working, and just added in several of the elements I wanted for the game we play.
It looks very similar, and in all reality taking out several of the \ or whatnot makes it somewhat easier for me to read anyway.
I am actually doing something a little different with this. I am technically not using Tinyportal to view anything. I have eqdkp+ for my main portal, which has a built in gui interface recruitment block. You hit "Apply" and it is linked to the app in Tinyportal which all the panels are hidden. It posts it to the forum, and redirects to the thank you page. And this hopefully will be done all in the eqdkp+ iframe.
Just got the page done last night, am going to start working on the iframe setup tonight.
EQDKP as portal its a bit messy and not that practical :P
I think it looks ok...
www.darkaftermathguild.com
The frontpage will be removed here shortly, is temporary.