Git Product home page Git Product logo

Comments (9)

stephenajulu avatar stephenajulu commented on September 6, 2024 2

Here is my implementation. It's brutal but works.

{{ define "main"}}
<div class="spacer"><br>&nbsp;<br>&nbsp;<br>&nbsp;<br>&nbsp;<br></div>
      <div>
        <h2 style="text-align:center;">Oops, Page Not Found!</h2>
<center><img src="images/404.svg" alt="404" width="404px" align="center" style="align:center;text-align:center;"></center>
<br>
        <h2 style="text-align:center;">
            <a href="{{ "/" | relURL }}">Go Back Home</a>
        </h2>
      </div>
{{ end }}

The image is from Undraw Illustrations, change it as you wish otherwise go to their website undraw.co and download it. I'll work on a better one later. Works on mobile too!

image

image

from portio-hugo.

AntoineSoetewey avatar AntoineSoetewey commented on September 6, 2024 1

Many thanks!

from portio-hugo.

juhair-cupcake avatar juhair-cupcake commented on September 6, 2024

Because 404 page not found.
I mean, we don't have any design for 404 page. That's why It's blank.

from portio-hugo.

AntoineSoetewey avatar AntoineSoetewey commented on September 6, 2024

ok I see, but is it possible to have at least the navbar, a text saying "404 page not found" and the footer?

from portio-hugo.

juhair-cupcake avatar juhair-cupcake commented on September 6, 2024

Yes, you can do that by

{{ define "main" }}
"404 page not found"
{{ end }}

from portio-hugo.

AntoineSoetewey avatar AntoineSoetewey commented on September 6, 2024

thanks.

It's better, but the text is not appearing as on the other pages:

Screenshot 2021-08-18 at 16 32 14

Any idea on how to improve it? sorry my knowledge in coding is quite basic.

from portio-hugo.

juhair-cupcake avatar juhair-cupcake commented on September 6, 2024

It's better, but the text is not appearing as on the other pages:

You need add some css and little bit of Html.

{{ define "main" }}
<section>
  <div class="container">
    <div class="row">
      <div class="col-12 text-center">
        <h1>
          404 page not found
        </h1>
      </div>
    </div>
  </div>
</section>
{{ end }}

Try this.

from portio-hugo.

AntoineSoetewey avatar AntoineSoetewey commented on September 6, 2024

a little bit better :

Screenshot 2021-08-18 at 19 13 43

But the title is above the navbar

from portio-hugo.

juhair-cupcake avatar juhair-cupcake commented on September 6, 2024

I'm really sorry mate,
I can't help you here, you have to learn some CSS SCSS and little bit of HTML.
Try,

{{ define "main" }}
<section>
  <div class="container">
    <div class="row">
      <div class="col-12 text-center">
        <h1 style="margin: 100px, 0px;">
          404 page not found
        </h1>
      </div>
    </div>
  </div>
</section>
{{ end }}

This code may break on mobile.

from portio-hugo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.