Previous Thread
Next Thread
Print Thread
Hop To
#223314 02/27/2009 2:14 PM
Joined: Feb 2009
Posts: 53
journeyman
journeyman
Joined: Feb 2009
Posts: 53
I want to change the customfield 1 input from text to radiobutton.
Gender select: male (m) or female (f)

But it doesn't work. The server get works and works .... no answere anymore!

editbasic.inc.php
start row: 351
Code
 
	// Handle Custom fields 1 - 5 :)
	for ($i = 1; $i <= 5; $i++) {
		$key = 'CUSTOM_FIELD_' . $i;
		$x = ${$key};
		if ($config[$key]) {

			if ($i=1)
				{
				$markiertM = "";
				$markiertF = "";
				if ($x == "m") {$markiertM = "checked=\"checked\"";}
				if ($x == "f") {$markiertF = "checked=\"checked\"";}

				${$key} = "					
				<label for=\"{$key}\">{$config[$key]}</label>
				<br />
				{$ubbt_lang['MALE']} <input type=\"radio\" name=\"{$key}\" id=\"GENDER_M\" value=\"m\" {$markiertM} class=\"form-radio\" /><br />
				{$ubbt_lang['FEMALE']} <input type=\"radio\" name=\"{$key}\" id=\"GENDER_F\" value=\"f\" {$markiertF} class=\"form-radio\" /><br /><br />
				";

				}
			else {
	
				${$key} = "
					<label for=\"{$key}\">{$config[$key]}</label>
					<br />
					<input type=\"text\" name=\"{$key}\" id=\"{$key}\" value=\"{$x}\" class=\"form-input\" /><br /><br />
				";
			      }

		} else {
			${$key} = "
				<input type=\"hidden\" name=\"{$key}\" id=\"{$key}\" value=\"{$x}\" class=\"form-input\" />
			";
		}
	}


UBB since 2003 - Version v7.5.2 - http://www.tiernetzwerk.de
Chrome 2.0
Joined: Mar 2008
Posts: 327
Enthusiast
Enthusiast
Joined: Mar 2008
Posts: 327
Your code worked for me.

Joined: Feb 2009
Posts: 53
journeyman
journeyman
Joined: Feb 2009
Posts: 53
open MyProfile .... ubbthreads.php/ubb/editbasic
Error 500 - Internal server error

Why?????

Rick ??

Last edited by Stephan; 02/28/2009 1:34 AM.

UBB since 2003 - Version v7.5.2 - http://www.tiernetzwerk.de
Chrome 2.0
Joined: Jun 2006
Posts: 16,367
Likes: 126
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,367
Likes: 126
Moved this to the General 7.x forum; as mod's aren't officially supported there isn't really a place for this topic, but Feedback/Sugguestions isn't really the proper place...


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2009
Posts: 53
journeyman
journeyman
Joined: Feb 2009
Posts: 53
sorry and thx!

is there a answere what I'm doing wrong?


UBB since 2003 - Version v7.5.2 - http://www.tiernetzwerk.de
Chrome 2.0
Joined: Feb 2009
Posts: 53
journeyman
journeyman
Joined: Feb 2009
Posts: 53
is it a UBB THEAD problem?

SERVERERROR 500

Thank you
Stephan


UBB since 2003 - Version v7.5.2 - http://www.tiernetzwerk.de
Chrome 2.0
Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
Does it give you a 500 error with the stock script in place? If not, then it's probably a syntax error somewhere with the modification.


Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
Profile avatar storage settings
by SenecaFlyer - 12/05/2024 1:24 PM
Not allowing attachment over 2m
by ehill - 12/03/2024 3:16 PM
New Admin Here
by SenecaFlyer - 12/02/2024 4:14 PM
Who's Online Now
2 members (Ruben, SenecaFlyer), 929 guests, and 67 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Stones
Stones
by isaac, August 19
Powered by UBB.threads™ PHP Forum Software 8.0.1
(Snapshot build 20240918)