Error 404 Page Not Found” Solution of Path Link Error – HTML/PHP/SEO web developers must see
Articles,  Blog

Error 404 Page Not Found” Solution of Path Link Error – HTML/PHP/SEO web developers must see


Hey, what up buddies. This is hell buddy. Today I make the tutorial is talking about the link URL 404 error. I get many buddies question, they asked me, what the hell is going on about the 404’s error? Because it doesn’t show them what’s exactly going on? How to figure out? So, the first thing we have to understand what is 404’s error. When you’re Googling, you will see many snippets that included URL links. -or – may be when you read the page article that would included some URL links, so once the client clicks on the link – or – may be put the URL path link into the search bar, that will send the message to the server. When the server gets the client requests, it will try to find out the page. But for some reasons, it can’t find out the page that what the client provided the path link. So the only thing can do is: the server responds the client (that you) “error 404 message”, and said, “hey, I can’t find out your page! Please check out the path link” The error is all about links! If you know the reasons that means you know the solution. The 1st common problem is: 1) Something block your server communication. Especially, if you have the (Apache) server set up on your localhost. Please check out my another tutorial to find out the solution. The 2nd is about: 2) the Path Link is Broken. So check out any mis-spelling, or any word or symbol missing that will make the link breaking. And that is no case sensitive. So don’t worry about it. The 3rd always always happen is: 3) you’re guys deleted the file. So that why you got the error because the server found the link is not existed. The 4th thing is always happens too; 4) you’re guy always misunderstood about the path location. So let me show you what’s going on mine. I wanna connect the file name is called “hey.php”. I thought it’s located at the DocumentRoot directory but not. It actually located in the folder name is called “zOne”. So that means “hey.php” set into the folder name called “zOne” and that located at the DocumentRoot directory. So the real path link(url) should be put “zOne” in front of it, “localhost/zone/hey.php” that’s the real path link and let me click it. You see, the error 404s is gone! So if “hey.php” is the source page, beside that I’ve the other file name is called “Hello.php”. You can see because they beside for each other in the same directory. I want to make the link, I want make them for linking back for each other. I just simply make the relative links like that. Please watch the search bar link changing. If I’m at “Hello.php” now, I’m just click the “hey” link to “hello”, so you see “hello” can go back to “hey”, and they just for link back each other easily. If “Hello.php” and “Hey.php” these two files they suppose beside for each other in the same folder name called “zOne”. If now I just move “Hello.php” out of the folder. And I just set it locate in the DocumentRoot directory besides “zOne”. But in the “zOne”, inside “zOne” only has “Hey.php”. Outside “zOne”, beside the “zOne” folder this is “Hello.php”. So let me refresh the page, just remind I’m still at the “Hey.php” page that in “zOne” directory. Let me test the link, you see I got error 404s again, that’s not difficult to understand because “Hello.php” not inside “zOne” this folder anymore. It changed the location that beside “zOne”, it’s one of the folder located at the root directory. So, I just friendly put one forward slash ” / ” before that. So that means it will directly link to the DocumentRoot directory. Let me save it, and… okay, let me go back “Hey.php” the source page. It has already refreshed, so let me click “Hello” link again, you see, the error 404s gone again! Now I’m at the source page “Hello.php”, let me test the “Hey” link, you see I got error 404s. You guys right here now, you’ll sense what exactly going on, because “Hey.php” is not beside “Hello.php” anymore. That’s exactly in the folder name’s called “zOne”. So I should put “zOne” before that, so that’s the real path link. Okay, let me save it, let me refresh the page … let me go back “Hello.php” this source page, and test “Hey” link; you see, and I click “Hello” link, it works for each other. So depends on which the source page is, and where the link is going to? inside the directory? – or – outside the directory? Let me copy this hard code link, the hard code link again. I do the same thing, I want “Hey.php” link to “What.php”, so this in the directory called “img”. Okay, so let me save it, refresh and go to “Hey.php”, here has the link, link to “What.php”. Now, I wanna make the link on “What.php” like jump up two levels directories to “Hello.php”. So we have to use notation dots to linking backwards. One single dot and forward slash ” ./” that means jump up current directory. Two dots forward slash that means jump one level (parent) directory. If you made it double that means you want jump up two levels directories. Make more if you wanted jump up more, so on so on… Okay, I’ve just already copied those codes, so I paste on it for saving time. By the way, let me little explain to you; in the “img” this folder, I do have “BBQ.jpg” this image. Because they just in the current (same) directory, so I can use one single dot forward slash for this link. So let me copy this, and paste below. (click copy and paste). Alright, You guys did you remember that I can skip this “./” like this, makes it simple, because did you remember, they just beside for each other in the same directory, so I can make the link much simple easier. So now, I have to jump up one level, one single level to “Hey.php”. It’s very easy, I just put 2 dots and forward slash before that. So that will jump up one level reach to “Hey.php”. If now, I have jump up backward to “Hello.php”, so I have make double dots forward slash and make the other 2 dots forward slash, that means jump up two levels directory to reach “Hello.php”. Oh, let me change this part, so I just want to make you guys easy recognize this is a different link. Let me refresh the page and test the links. So the 1st link is alright, and the 2nd link that goes to the same image. This link is jumped up one level directory backwards to “Hey.php”. And that one is jumped up two level directory backwards to “Hello.php”. Can we use the notation dots make it as jump down forwards link? Let me copy this code from “What.php” this source page, and paste on the other source page of “Hello.php”. Let me change little bit because the link going forwards, so I make it “Go”, not “back”. And then change the link name is “What”, and that would be jump down two level directories, forwards to “What.php”, and let me save it and refresh the page. I got the new link of “What”, let me click it, you see I got the error 404s again. You’ve better to understand one thing is: that’s not allow to make same name files in the same directory. However, inside the directory, it’ll be happened same name files and folders. So that why it misleads the server, where should it go? when it’s getting down, it found out many same folder and file names in the same level directory. So you get error 404 again! The solution is: make the link to be Absolute Path Link. That can be clearly to indicate the path link location. It also avoids the link breaking to get error 404s again. Let me change the link, it should be goes to “zOne”, forward slash ” / “, “img” forward slash “/ ” , “What.php”. This is the Absolute Real Path Link, and save it, and refresh the page … oh, I should go back to “Hello.php” this source page refresh again, and click the link “what” again, you see, it works! So the advantage for making the absolute path link to prevents link breaking, to get error 404s. How come? so let me show you some example. Now, I’m making the link, that will linking to my blog, and let me paste the absolute link here. It looks little complicated, right? Although it’s exactly my absolute path link, however, it does’t mean it’s a precise link! So what should I do? I should put the domain which is hosting my absolute directory .. the path link; so make the path link to be perfect URL. So let me give you another example you guys will get more understand. Now I’m making the link that will linking to my one of the domain website… ummm, let me change this. And paste the absolute link here, alright, so you can see my linking page is: “WebsiteGeotargeting.html” that located in “LovelyApple” directory; and that also hang out to my one of the domain host server. So, this is my whole (full) URL, the absolute URL, …(put
to break the link) – so let me save it … – (adjust the page size here…)- And let me refresh the page. That one is absolute path link, link to the “What.php” you know that before. The other, that will link to my blog, web page to my whole absolute path link, you see it works. Okay, the final that one will link to my domain web page, it also my whole absolute path link, let me click it, see it works too. Hope you guys to get more understand the link breaking to cause error 404s. Thanks for watching. Please subscribes Hell Buddy Channel.

Leave a Reply

Your email address will not be published. Required fields are marked *