Derma Menu. Website Display

Hey guys. I need a little help here. I am trying to make my donations part of my clans site display in the derma panel in-game when this derma menu opens. I just need to know why its not working. From my knowledge, this should be working. But here is the code:


function GMRP.Donation()

	local DonationFrame = vgui.Create("GMRPFrame")
	DonationFrame:SetSize(700, 700) 
	DonationFrame:SetTitle("") 
	DonationFrame:SetPos( ScrW() / 2 - DonationFrame:GetWide() / 2, ScrH() / 2 - DonationFrame:GetTall() / 2 )
	DonationFrame:SetVisible( true )
	DonationFrame:SetDraggable( true )
	DonationFrame:SetBackgroundBlur(true)
	DonationFrame:ShowCloseButton(false)
	DonationFrame:AddCloseButton()
	DonationFrame:DrawList()
	DonationFrame:MakePopup() 
	DonationFrame:List_Spacing( 5 )
	DonationFrame:List_Padding( 5 )	
		
	local dnlabel = vgui.Create("HTML")
	Donation:SetPos(50,50)
	Donation:SetSize(ScrW() - 100, ScrH() - 100)
	Donation:OpenURL("http://deathslayer95.com/msgaming/index.php?action=treasury")
	dnlabel:SetFont( "GModRPFontOne" )		
	DonationFrame:List_AddItem( dnlabel )
	
end

Thanks.

Why are you calling SetFont on a HTML panel?

Also show us the code for the GMRPFrame(DFrame copy apparently).

I think this be it:


PANEL = {}

AccessorFunc( PANEL, "m_bDraggable", 		"Draggable", 		FORCE_BOOL )
AccessorFunc( PANEL, "m_bSizable", 			"Sizable", 			FORCE_BOOL )
AccessorFunc( PANEL, "m_bScreenLock", 		"ScreenLock", 		FORCE_BOOL )
AccessorFunc( PANEL, "m_bDeleteOnClose", 	"DeleteOnClose", 	FORCE_BOOL )

AccessorFunc( PANEL, "m_bBackgroundBlur", 	"BackgroundBlur", 	FORCE_BOOL )


/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:Init()


	self:SetFocusTopLevel( true )

//	self:SetCursor( "sizeall" )
	
	self.ButtonPos = 115	
	
	self.btnClose = vgui.Create( "DSysButton", self )
	self.btnClose:SetType( "close" )
	self.btnClose.DoClick = function ( button ) self:Close() end
	self.btnClose:SetDrawBorder( false )
	self.btnClose:SetDrawBackground( false )
	
	self.lblTitle = vgui.Create( "DLabel", self )
	
	self:SetDraggable( true )
	self:SetSizable( false )
	self:SetScreenLock( true )
	self:SetDeleteOnClose( true )
	self:SetTitle( "#Untitled DFrame" )
	
	// This turns off the engine drawing
	self:SetPaintBackgroundEnabled( false )
	self:SetPaintBorderEnabled( false )
	
	self:SetSize( 700, 700 )
	
	self.m_fCreateTime = SysTime()

end

/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:ShowCloseButton( bShow )

	self.btnClose:SetVisible( bShow )

end

/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:SetTitle( strTitle )

	self.lblTitle:SetText( strTitle )

end


function PANEL:DrawList()

	self.List = vgui.Create( "DPanelList", self )
	self.List:SetSize( self:GetWide() - 170, self:GetTall() - 80 )
	self.List:SetPos( 150, 40 )
	self.List:EnableVerticalScrollbar( true ) 
	
end


function PANEL:List_SetAutoSize( bool )

	if self.List != nil then
	
		self.List:SetAutoSize( bool )
		
	end	
	
end	


function PANEL:List_AddItem( item )

	if self.List != nil then
	
		self.List:AddItem( item )
		
	end	
	
end	


function PANEL:List_EnableHorizontal( bool )

	if self.List != nil then
	
		if tobool( bool ) == nil then

			self.List:EnableHorizontal( false )
			
			return
			
		end	
		
		self.List:EnableHorizontal( bool )
		
	end	
	
end


function PANEL:List_Spacing( number )

	if self.List != nil then
	
		if tonumber( number ) == nil then
		
			self.List:SetSpacing( 5 )
			
			return
			
		end	
		
		self.List:SetSpacing( number )
		
	end	
	
end


function PANEL:List_Padding( number )

	if self.List != nil then
	
		if tonumber( number ) == nil then
		
			self.List:SetPadding( 15 )
			
			return
			
		end	
		
		self.List:SetPadding( number )
		
	end	
	
end


function PANEL:AddCloseButton()

	self.CloseButton = vgui.Create( "DButton", self )
	self.CloseButton:SetSize( 120, 20 )
	self.CloseButton:SetPos( 10, 90 )
	self.CloseButton:SetText( "Close" )
	self.CloseButton.DoClick = function()
	
		self:Close()
		
	end
	
end	


function PANEL:AddButton( name, cmd )

	self.AddedButton = vgui.Create( "DButton", self )
	self.AddedButton:SetSize( 120, 20 )
	self.AddedButton:SetPos( 10, self.ButtonPos )
	self.AddedButton:SetText( name )
	self.AddedButton.DoClick = function()
	
		LocalPlayer():ConCommand( cmd )
		
	end
	
	self.ButtonPos = self.ButtonPos + 25
	
end	


function PANEL:AddFuncButton( name, func )

	self.AddedButton = vgui.Create( "DButton", self )
	self.AddedButton:SetSize( 120, 20 )
	self.AddedButton:SetPos( 10, self.ButtonPos )
	self.AddedButton:SetText( name )
	self.AddedButton.DoClick = function()
	
		func()
		
	end
	
	self.ButtonPos = self.ButtonPos + 25
	
end	
	
	
/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:Close()

	self:SetVisible( false )

	if ( self:GetDeleteOnClose() ) then
		self:Remove()
	end

end


/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:Center()

	self:InvalidateLayout( true )
	self:SetPos( ScrW()/2 - self:GetWide()/2, ScrH()/2 - self:GetTall()/2 )

end


/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:Think()

	if (!self.Dragging) then return end
	
	local x = gui.MouseX() - self.Dragging[1]
	local y = gui.MouseY() - self.Dragging[2]

	// Lock to screen bounds if screenlock is enabled
	if ( self:GetScreenLock() ) then
	
		x = math.Clamp( x, 0, ScrW() - self:GetWide() )
		y = math.Clamp( y, 0, ScrH() - self:GetTall() )
	
	end
	
	self:SetPos( x, y )
	
end


/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:Paint()

	derma.SkinHook( "Paint", "Frame", self )
	return true

end


/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:OnMousePressed()

	if ( !self:GetDraggable() ) then return end

	self.Dragging = { gui.MouseX() - self.x, gui.MouseY() - self.y }
	self:MouseCapture( true )

end


/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:OnMouseReleased()

	self.Dragging = nil
	self:MouseCapture( false )

end


/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:PerformLayout()

	derma.SkinHook( "Layout", "Frame", self )

end


/*---------------------------------------------------------

---------------------------------------------------------*/
function PANEL:IsActive()

	if ( self:HasFocus() ) then return true end
	if ( vgui.FocusedHasParent( self ) ) then return true end
	
	return false

end


derma.DefineControl( "GMRPFrame", "GMRP Frame", PANEL, "EditablePanel" )

Edit:

I forgot to remove that it was from something else. That i had on there before this. So never mind that.

Looks like a dlist included into a DFrame.

Anyway, this part is wrong(see variable names).



	local dnlabel = vgui.Create("HTML")
	Donation:SetPos(50,50)
	Donation:SetSize(ScrW() - 100, ScrH() - 100)
	Donation:OpenURL("http://deathslayer95.com/msgaming/index.php?action=treasury")
	dnlabel:SetFont( "GModRPFontOne" )		
	DonationFrame:List_AddItem( dnlabel )


Problem Solved. Wasnt that hard. Im just kind of an airhead at 5am. But, yeah thanks for the help. Helped me get back on track. All it was was the variable.