Path to page folder in <img> tag?

I would like to resize a picture. According to

“As of this writing, Markdown has no syntax for specifying the dimensions of an image; if this is important to you, you can simply use regular HTML <img> tags.”

But I can not figure out how to use the relative path to the page folder for the images stored there.

When I use markdown the path to the page folder is set but how can I get this with an img tag?

I found out this:
<img src="./myPagesName/myImageName.JPG" width="40%">

But here I still have to put the page name which I would like to avoid.

Thanks for any hint !