Posts

Forget mysql password, timezone error

Forgetting my sql password   service mysql start, should be done before entering the mysql.   If i forget my password, i can enter without password like this:   Changint the file my.cnf (in my Ubuntu-system he is placed at /etc/mysql/my.cnf). In the end i added that code:   [ mysqld ]   skip-grant-tables   Then run mysql server after adding it. Before running change the permission of the file my.cnf, with chmod 0444 my.cnf    mysql  - u root   After entering into the mysql, the way to change password depends on the version of mysql server. For 8.0 or greater version this is the way, ALTER USER 'root'@'localhost' IDENTIFIED BY 'new_password';    This is the link to change password if i forget password: except for the line update, i have to use alter. https://stackoverflow.com/questions/46193743/access-denied-for-user-rootlocalhost-using-password-no-whats-wrong   After changing the password, delete the added line in my.cnf...

My Account Module Page(BOOK LIBRARY)

<!doctype html > < html lang ="en" xmlns:th ="http://www.w3.org/1000/xhtml" > < head th:replace ="common/header :: common-header" /> < body > < div th:replace ="common/header :: navbar" /> < div class ="container" > < div class ="row" style =" margin-bottom : - 100 px ; " > < div class ="col-xs-8" > < h2 class ="section-headline" >< span > Featured books </ span ></ h2 > </ div > < div class ="col-xs-4" > < img src ="/image/logo.jpeg" class ="img-responsive" /> </ div > </ div > < hr style =" position : absolute ; width : 88 %; height : 6 px ; background-color : #333 ; z-index : - 1 ; margin-top : - 80 px ; " /> s < img class ="img-responsive" src ="/image/wood.jpg" style =" margin-top : - 75 ...

Using the common part of HTML file with thymeleaf

For using the common part in HTML with Thyemleaf The way to recognized the th:fragment and use it in html. < html lang ="en" xmlns:th ="http://www.w3.org/1999/xhtml" > < head th:fragment ="common-header" ></ head > < div th:fragment ="navbar" > Disc: This is the file inside common folder with name header.html This is the link to declare thyemleaf's address for replace and use the part in another file < html lang ="en" xmlns:th ="http://www.w3.org/1000/xhtml" > <div th:replace ="common/header :: navbar" /> Disc: common is the folder and header.html is the file.

Starting The Spring MVC

Image
This is the sample MVC for Spring dated on 10 july 2020. spring-servlet.xml <? xml version ="1.0" encoding ="UTF-8" ?> < beans xmlns ="http://www.springframework.org/schema/beans" xmlns:xsi ="http://www.w3.org/2001/XMLSchema-instance" xmlns:context ="http://www.springframework.org/schema/context" xsi:schemaLocation ="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd" > < context :component-scan base-package ="com.mountech" /> </ beans > web.xml <? xml version ="1.0" encoding ="UTF-8" ?> < web-app xmlns:xsi ="http://www.w3.org/2001/XMLSchema-instance" xmlns ="http://java.sun.com/xml/ns/j2ee" xmlns:web ="http://xmlns.jcp.org/xml/ns/javaee" xsi:schemaLoca...