Archive for myfreeforum.org Before posting please check the "stickies" in the support forums.
Please ask questions in real English and not "txt". You will get a better response.
Please do not ask support questions via PMs.
 


       myfreeforum.org Forum Index -> Web page/template Editing
Glenwing

CSS for Dropdown Menus

PLEASE ENTER THE FOLLOWING>>>>


Enter your myff forum url here, if the issue is on a particular part of the forum, then give a link to where the problem actually is. Do not enter your own domain name it must be the actual myff link :
www.academyofcombat.myfastforum.org

If you are asking a template related question, what is the name of the template:
myfs_academyofcombat2

Please indicate keywords you have searched on:
dropdown, css dropdown, css dropdown menu

Now ask your question in clear English without "txt" speak>>>>
Basically I just need to know the css for creating a dropdown menu and specifying what the options are... I am creating several new fields in the edit profile page (profile_add_body.tpl), and I can't use the automatic creation in the Profile Fields section of the Admin Panel because I created a whole new section for my new fields, and the automatic creation would create them in one of the other sections.

<input type="???"

EDIT: Also it seems that the fields I created where I custom added their input fields to the page are not being saved to the user's profile.  Is there a way to fix this or do I have to use the automatic stuff in the Admin Panel?
myff admin

this is complex, If you have manually added stuff correctly it would be saved, you can compare what is automatically added and what is manually added to see if it is functionally identical. But that's the rub really, you need to understand enough to see what is right and what is not.
I'm bothered by you asking about css and dropdowns, css is about how things look is has no effect on making things work.
Glenwing

*Facepalm* I totally meant HTML... Now that I fix that google can probably give me the answer.  I'm still trying to sort out the not-saving thing.  The problem I'm having with comparing the automatic creation to the manual one is that the automaticly made fields are invisible in the tpl file so I can't see how they are coded.  

In a nutshell I've created new fields in the profile fields section of the admin panel, but I'm trying to manually add the input fields in the edit profile page.  I'm not adept enough to know HTML by heart yet, so far what I've done basically consists of copy-pasting the existing fields and changing the macro names and other values (width, maxlength, etc.) to make it the way I want.  For example, I find something like
Code:
   <tr>
     <td class="row1"><span class="gen">{L_INTERESTS}:</span></td>
     <td class="row2">
      <input type="text" class="post"style="width: 200px"  name="interests" size="35" maxlength="150" value="{INTERESTS}" />
     </td>
   </tr>

And use it to make
Code:
   <tr>
     <td class="row1"><span class="gen">{L_GENDER}:</span></td>
     <td class="row2">
      <input type="text" class="post"style="width: 50px"  name="weight" size="12" maxlength="10" value="{GENDER}" />
   </tr>

where GENDER is the name of the profile field I created.
The only thing I think there might be a problem with is the macro since the rest just defines the properties of the input box.
myff admin

The thing I would do is make the fields automatically created, go to the profile page and then do a "View Source" in the browser, that will show you what ended up being created and so you can then copy that into the template and turn off automatic.
Glenwing

Ok, that did help, I fixed the problem of the values not saving to the user profile, but I'm still having a slight problem with the dropdown menu.

The source code gave me this:
Code:

<select class="post" name="GENDER" ><option value="Male" selected >Male<option value="Male" >Male</Option><option value="Female" >Female</Option><option value="--" >--</Option></select>


But in the source code, the dropdown is coded as having male selected, which is what I have selected in my profile.  However if I change it to female and go back to the page again, male will be selected.  I'm not sure how to set whatever the value actually is as the default selected value.  I've tried a few separate things but the closest I've come is adding
Code:
<option value="{GENDER}" selected >{GENDER}</option>

But that adds a double of whatever the selected value is.
editor

Maybe we are looking at this the wrong way, what you want is automatic creation, but where you want it. Perhaps we can give you a macro for that.
Glenwing

That would be excellent.
myff admin

Ok,

If you have a field that is not automatic, then if that field was called CaSeMaTTERS then:

{FIELD_CaSeMaTTERS}

should now be available as a macro.
Glenwing

Wow!  Thanks admin =)

       myfreeforum.org Forum Index -> Web page/template Editing
Page 1 of 1
Create your own free forum | Buy a domain to use with your forum