I handle collisions pretty easily, first i calculate the distance it traveled in the x axis only, then i check if it collides with anything not passable, like a block.
if i collides with anything, i reduce the distance it traveled in this frame and move it back to its previous position, and then i do the same for the y axis.
so for psuedocode it would look like this, actually its closer to c++ code than psudocode, but it's pretty self explanatory:
//so add the distance traveled this frame, distance = velocity * time
//save the distance traveled so i can subtract it later and move back to previous position in case of collision
float distance_Traveled = x_Velocity * delta_Time;
x_Position += distance_Traveled;
if(check for collision with any entity)
x_Position -= distance_Traveled;
then i just repeat that for the y axis, and the object will move to the last position it existed on before it had a collision. note there are some problems, for example if there is a collision before and after it moves, like the bounding box is located inside a block before it moves, and inside a block after it moves, it will move back to its previous position even if its still colliding with something. another problem is if it travels too far within a single frame, and crosses a huge gap at once and collides with something, it will move back to its original position even if the distance is enormous.
lets say the square bracket is the player, and the 0 is a wall
if its that far, and in one frame the square bracket moves inside the 0
then it wil move all the way back to its last position
and not take into account the entire gap in between.
another problem has more to do with collision detection than handling, if an entity moves from one side of a block to another in a single frame without touching it, it wont count as a collision and he will pass through the block.
no collision, so it will keep moving just fine.
anyways this simple way to handle collision works fine until it starts lagging or objects move at high velocities. also if it looks like the player is floating over a block then just make the bounding boxes of the player / block smaller than the image, that way it looks a little bit better. and one last thing, if you move one axis at a time, handling slopes will be easy because you just handle slope on the x axis and you can easily use something like y=mx + b to determien the position.
here is a final guide that you can look over to help you understand how to implement platformers, i really suggest you read it, its great.
its on gamedev.net too but my computer lags too badly to search for it so i just used the first link i found. Good luck