Hello There!
Just a brief summary: ToP is originally coded in C++ (Source code is available in this forum) and Lua. It uses SQL database. Most PKOsites are coded in PHP.
It's really up to you where you'll want to guide your learning path, but as a personal suggestion, start learning LUA (https://www.lua.org/docs.html). Most ingame scripts are coded in LUA (NPCs, Missions, Item Effects, Attributes, Skills, even the AI; and also, most of the releases of this forum are for those kind of scripts).
You could also learn a bit about SQL (mainly UPDATE, INSERT and basic Queries) 'cause you can find here an awesome extension called LuaSql, which allows you to play with your database from ingame events.
Once you're familiar with it's language, and you feel like you can pretty much do everything you want to in LUA (a good way to prove you're confident enough is to understand advanced pkodev extensions - such as Hooks, Serialize, AntiDupes, AI Behaviours - ), you can dive into C++ learning to making your own extensions, or edits on the source code. This is really advanced shit, it'll take you some time to get familiar with LUA first.
Use PkoDev Search Engine, Guides Section, Releases Section, Lua docs, Google and Youtube. You can do it ☺
--Edit:
Forgot to say, despite all the information you can get from the internet, the greatest way of learning is by Doing.
Install Basic Server Files, Get to make it run just for you or few friends, and start doing!
Start by making an Npc, then a mission, then an usable item, and so on. From basic to advanced, just the same as learning anything else.