The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Automatic application Coding help

2 posters

Go down

Automatic application Coding help Empty Automatic application Coding help

Post by msedgley October 4th 2012, 1:09 am

i use this coding on my forums for adding a application format that automatically posts the application within the forums, saves members copying and pasting the form. But an old friend did it and i am unsure of how to add new questions was wondering if someone could take a look and help out if possible please, thanks

Code:
<style type="text/css">textarea{background:#0d0d0d}</style>
<style type="text/css">
    .form {
    width: 650px;
    margin-left:auto;
    margin-right:auto;
    font:bold 15px Verdana;
    color:white;
    text-align:left;
    background-color:black;
    }
    fieldset{
    width: 500px;
    margin-left:auto;
    margin-right:auto;
    background-color:black;
    }
    legend {
    font:italic 24px Monotype arial;
    text-align:center;
    padding-left:20px;
    padding-right:20px;
    }
    .form td{margin:5px;
    padding:5px;
    text-align:right;
    font:bold 15px Verdana;
    }
    .form td+td{
    text-align:left;
    }
    .form td[colspan='2']{
    text-align:center;
    }
    .form span{
    color:red;
    }
    </style>

    <script type="text/javascript">
    function sendMessage(form){
    if(form.element_1.value == "" || form.element_2.value == "" || form.element_3.value == ""
    || form.element_6.value == "" || form.element_7.value == "" || form.element_10.value == "" )
    {
    document.getElementById("errormsg").innerHTML ="YOU MUST COMPLETE ALL FIELDS MARKED WITH AN (*) !";
    return false;
    }
    else
    {
    var firstname = form.element_1.value
    var lastname = form.element_2.value
    var age = form.element_3.value
    var email = form.element_4.value
    var location = form.element_5.value
    var ident = form.element_6.value
    var ratio = form.element_7.value
    var forum = form.element_9.value
    var benefit = form.element_10.value

    var txt_message = "About you and the Game" + '\n' + '\n'
    + "Your First Name : " + firstname + '\n'
    + "Your Last Name : " + lastname + '\n'
    + "Your age : " + age + '\n';
    if(email != "")
    txt_message += "Your Email  : " + email + '\n';
    if(location != "")
    txt_message += "Your location  : " + location + '\n';
    txt_message += "PSN iD  : " + ident + '\n'
    + "Kill/Death Ratio  : " + ratio + '\n' + '\n'
    + "About the Game and the Forum" + '\n' + '\n'
    + "Will you participate in clan activities ?  : ";
    for(var i = 0; i < form.element_8.length; i++)
    {
    if(form.element_8[i].checked == true) { txt_message += form.element_8[i].value + '\n'; }
    }
    if(forum != "")
    {txt_message += "How did you hear about us ?  : " + forum + '\n';}
    txt_message += "How will you benefit the clan ?  : " + '\n' + benefit + '\n'
    + "How active will you be on the forum and PSN ?  : ";
    for(var i = 0; i < form.element_11.length; i++)
    {
    if(form.element_11[i].checked == true) { txt_message += form.element_11[i].value; }
    }
    txt_message +=  '\n' + "Have you read the Rules and regulations of the forum ?  : ";
    for(var i = 0; i < form.element_12.length; i++)
    {
    if(form.element_12[i].checked == true) { txt_message += form.element_12[i].value + '\n'; }
    };

    form.message.value = txt_message;
    form.subject.value = "Clan Application of " + firstname ;
    return true;
    }
    }
    </script>

    <form class="form" action="/post" method="post" name="post" enctype="multipart/form-data" onSubmit="return(sendMessage(this))">
    <input type="hidden" name="lt" value="0" />
    <input type="hidden" name="mode" value="newtopic" />
    <input type="hidden" name="topictype" value="0" checked="checked" />
    <input type="hidden" name="message" value="" />
    <input type="hidden" name="f" value="44" />
    <input name="subject" type="hidden" value="" />
    <br />
    <span style="font-size:24px;color:lightgray;">Clan Application</span><br />
    Please apply for the clan by filling in and submitting the following form<br /><br />

    <fieldset><legend>About you and the Game</legend>

    <table width="100%">
    <tr valign="top">
    <td>First Name <span>*</span>
    </td>
    <td><input size="30" maxlength="30" id="element_1" name="element_1" type="text" />
    </td>
    </tr><tr valign="top">
    <td><label id="">Last Name </label><span>*</span>
    </td>
    <td><input size="30" maxlength="30" id="element_2" name="element_2" type="text" />
    </td>
    </tr><tr valign="top">
    <td>Age <span>*</span>
    </td>
    <td><input size="3" maxlength="3" id="element_3" name="element_3" type="text" />
    </td>
    </tr><tr valign="top">
    <td>Email </td>
    <td><input size="30" maxlength="100" id="element_4" name="element_4" type="text" />
    </td>
    </tr><tr valign="top">
    <td>Location </td>
    <td><select id="element_5" name="element_5">
    <option value="" selected="selected"> </option>
    <option value="Europe">Europe</option>
    <option value="North America">North America</option>
    <option value="Rest of World">Rest of World</option>
    </select></td>
    </tr><tr valign="top">
    <td>PSN ID <span>*</span></td>
    <td><input size="30" maxlength="100" id="element_6" name="element_6" type="text" />
    </td>
    </tr><tr valign="top">
    <td>Kill/Death Ratio <span>*</span></td>
    <td><input size="30" maxlength="100" id="element_7" name="element_7" type="text" />
    </td>
    </tr>
    </table>
    </fieldset><br />

    <fieldset><legend>About the Game and the Forum</legend>
    <table width="100%">
    <tr valign="top">
    <td>Will you participate in clan activities? <span>*</span>
    </td>
    <td>
    <input id="element_8_0" name="element_8" value="Yes" type="radio" /> Yes
    <input id="element_8_1" name="element_8" value="No" checked="checked" type="radio" /> No
    </td>
    </tr><tr valign="top">
    <td colspan="2">How did you hear about us? <br />
    <textarea id="element_9" name="element_9" cols="65" rows="5"></textarea>
    </td>
    </tr><tr valign="top">
    <td colspan="2">How will you benefit the clan? <span>*</span><br />
    <textarea id="element_10" name="element_10" cols="65" rows="7"></textarea>
    </td>
    </tr><tr valign="top">
    <td>How active will you be <br />on the forum and PSN? <span>*</span>
    </td>
    <td>
    <input id="element_11_0" name="element_11" value="Very Active" type="checkbox" /> Very Active <br />
    <input id="element_11_1" name="element_11" value="Average" type="checkbox" /> Average <br />
    <input id="element_11_2" name="element_11" value="Not Active" type="checkbox" /> Not Active
    </td>
    </tr><tr valign="top">
    <td>Have you read the Rules <br />and regulations of the forum?<span>*</span>
    </td>
    <td>
    <input id="element_12_0" name="element_12" value="Yes" type="radio" /> Yes
    <input id="element_12_1" name="element_12" value="No" checked="checked" type="radio" /> No
    </td>
    </tr><tr>
    <td colspan="2" align="center">
    <br><span style="color:orangered;" id="errormsg"></span><br><br>

    <input name="post" value="Apply" type="submit" />
    </td>
    </tr>
    </table>
    </fieldset><br />
    </form>


Last edited by msedgley on October 4th 2012, 1:52 am; edited 1 time in total
msedgley
msedgley
Forumember

Female Posts : 618
Reputation : 35
Language : English
Location : UK

http://www.rateoffire.com

Back to top Go down

Automatic application Coding help Empty Re: Automatic application Coding help

Post by msedgley October 4th 2012, 1:46 am

Rideem3 wrote:
Please change the title of your topic, that is related to your question/issue, so that other users will be able to find their question/issue using the search engine.
Can you post a link to where this can be found in action?

not sure what i need to rename my title to as its exactly what i need help with?

link: http://www.rateoffire.com/h8-mw3-eu-apps
msedgley
msedgley
Forumember

Female Posts : 618
Reputation : 35
Language : English
Location : UK

http://www.rateoffire.com

Back to top Go down

Automatic application Coding help Empty Re: Automatic application Coding help

Post by msedgley October 5th 2012, 3:52 am

bump
msedgley
msedgley
Forumember

Female Posts : 618
Reputation : 35
Language : English
Location : UK

http://www.rateoffire.com

Back to top Go down

Automatic application Coding help Empty Re: Automatic application Coding help

Post by msedgley October 8th 2012, 12:05 am

bump
msedgley
msedgley
Forumember

Female Posts : 618
Reputation : 35
Language : English
Location : UK

http://www.rateoffire.com

Back to top Go down

Automatic application Coding help Empty Re: Automatic application Coding help

Post by msedgley October 9th 2012, 12:07 am

ok it works but when i submit the application it doesnt show the new info in the post? just the original questions not the new ones i added
msedgley
msedgley
Forumember

Female Posts : 618
Reputation : 35
Language : English
Location : UK

http://www.rateoffire.com

Back to top Go down

Automatic application Coding help Empty Re: Automatic application Coding help

Post by msedgley October 9th 2012, 1:15 pm

Rideem3 wrote:That will require you to add more to the JavaScript itself. Wink

well i know nothing about that, hence i posted this topic for help
msedgley
msedgley
Forumember

Female Posts : 618
Reputation : 35
Language : English
Location : UK

http://www.rateoffire.com

Back to top Go down

Automatic application Coding help Empty Re: Automatic application Coding help

Post by tomtato October 10th 2012, 5:00 pm

thank you :wouhou:
avatar
tomtato
New Member

Posts : 1
Reputation : 1
Language : thailand

http://thehackgame.thai-forum.net/

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum