Lua code works on local, but not dedicated server.

I downloaded a mp3 lua code on garyrysmod.org and then extracted it to my autorun/client folder in my local files. I typed mp3 in the console and it worked. So I placed the .lua file into my client folder in my dedicated server. I typed mp3 into the console, but nothing happened. The suggestion didn’t even pop up when I typed it. Here’s the code:


function Playermenu()

    DermaPanel1 = vgui.Create( "DFrame" )
    DermaPanel1:SetPos( 50,25 )
    DermaPanel1:SetSize( 300, 450 )
    DermaPanel1:SetTitle( "GMOD MP3 Player" )
    DermaPanel1:SetVisible( true )
    DermaPanel1:SetDraggable( true )
    DermaPanel1:ShowCloseButton( true )
    DermaPanel1:MakePopup()


    local DermaListView = vgui.Create("DListView")  
    DermaListView:SetParent(DermaPanel1)  
    DermaListView:SetPos(12.5, 37.5)  
    DermaListView:SetSize(275, 362.5)  
    DermaListView:SetMultiSelect(false)  
    DermaListView:AddColumn("Name") // Add column     


    local list = file.Find("sound/songs/*.mp3", true)  
    for k,v in pairs(list) do
        DermaListView:AddLine(v)
    end


    local name
    function DermaListView:OnRowSelected( LineID, Line )  
        name = Line:GetColumnText( 1 )
    end


    local DermaButton = vgui.Create( "DButton", DermaPanel1 )    
    DermaButton:SetText( "Play" )  
    DermaButton:SetPos( 12.5, 412.5 )  
    DermaButton:SetSize( 100, 25 )  
    DermaButton.DoClick = function()
        surface.PlaySound( "ui/buttonclick.wav" )
        RunConsoleCommand( "play", "songs/"..name )
    end


    local DermaButton = vgui.Create( "DButton", DermaPanel1 )    
    DermaButton:SetText( "Stop" )  
    DermaButton:SetPos( 187.5, 412.5 )  
    DermaButton:SetSize( 100, 25 )  
    DermaButton.DoClick = function()
        surface.PlaySound( "ui/buttonclick.wav" )
        RunConsoleCommand( "stopsounds" )
    end


end


concommand.Add("mp3", Playermenu)

any help is appreciated.

You must first let everyone download the script, it isn’t done automatically.
Make a file inside autorun/server and insert
[lua]
AddCSLuaFile(“autorun/client/<filename>.lua”)
[/lua]

This is clientsided code so you have to AddCSLuaFile it.
It will download it to the client’s PC for your server and then it will be useable.

Say for example the filename of what you downloaded is mp3.lua, you would do this.
[lua]
AddCSLuaFile(“autorun/client/mp3.lua”)
[/lua]

Thank you for helping me out with this problem. So how would I let them download the files in the sound folder?

resource.AddFile(“sound/file.mp3”)